def get_feats(self, spans):
TDL_feature_generator = compile_entity_feature_generator()
for i,s in enumerate(spans):
xmltree = corenlp_to_xmltree(get_as_dict(s.context))
sidxs = range(s.get_word_start(), s.get_word_end() + 1)
// Add DDLIB entity features
for f in get_ddlib_feats(s, sidxs):
After Change
def get_feats(self, spans):
TDL_feature_generator = compile_entity_feature_generator()
for i,s in enumerate(spans):
sent = get_as_dict(s.context)
xmltree = corenlp_to_xmltree(sent)
sidxs = range(s.get_word_start(), s.get_word_end() + 1)
// Add DDLIB entity features