-1
我正在使用Stanford CoreNLP的折叠依赖关系。我得到使用dependencies.getEdgeSet()时找不到符号错误
我越来越
能不能找到符号。符号:方法getEdgeSet()
错误,同时输入以下代码:
Set<SemanticGraphEdge> edge_set1 = dependencies.getEdgeSet();
没有其他发现错误。我已经导入
edu.stanford.nlp.semgraph.SemanticGraphEdge;
为什么会发生这种情况?
将'dependencies'声明添加到您的文章+ dependencies'类型的'import'行中。 –
'SemanticGraph dependencies = sentence.get(CollapsedDependenciesAnnotation.class); Set edge_set1 = dependencies.getEdgeSet();'@engineer –
user5789094
'import edu.stanford.nlp.semgraph.SemanticGraphCoreAnnotations.CollapsedDependenciesAnnotation;' – user5789094