Java 使用stanford naturalli.OpenIE时的IndexOutOfBoundsException
我正在使用coreNLP中的Java 使用stanford naturalli.OpenIE时的IndexOutOfBoundsException,java,stanford-nlp,Java,Stanford Nlp,我正在使用coreNLP中的naturalli.OpenIE模块。使用组合选项-triple时,我得到一个IndexOutOfBoundsException。所有名称均为true和格式混响。请告诉我如何修理它。这是我的命令行: java -mx2g -cp "/almac/ignacio/corenlp/*" edu.stanford.nlp.naturalli.OpenIE -filelist $HOME/list -triple.all_nominals true -format rever
naturalli.OpenIE
模块。使用组合选项-triple时,我得到一个IndexOutOfBoundsException。所有名称均为true
和格式混响
。请告诉我如何修理它。这是我的命令行:
java -mx2g -cp "/almac/ignacio/corenlp/*" edu.stanford.nlp.naturalli.OpenIE -filelist $HOME/list -triple.all_nominals true -format reverb > trip
其中输入是逐行的句子文件。如果我以不同的方式使用上述选项,例如(-triple.all-nominals false,-format reverb)
或(-triple.all-nominals true,-format ollie)
,则不会出现这种情况
这是我的输入文件:
the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription
Thus , NanR and NagC appear to activate fimB expression independently .
Thus MarA is able to repress the rob promoter after the preformed open complex clears the promoter .
However , in vitro experiments show IHF to repress ompC transcription from two of its three promoters .
These results show that constitutive and inducible expression of the chromosomal MarA was able to upregulate nfnB expression in contrast with the lack of activation mediated by constitutive expression of the chromosomal SoxS and Rob proteins .
The Rob homologs MarA and SoxS can activate transcription of a broad range of genes in vivo ( reviewed in references 2 and 14 ) , including sodA , fumC , micF , zwf , and inaA , suggesting broadly overlapping activities of these three regulators .
It thus seems likely that the ability of IHF alone to activate fimB expression is enhanced in the D3 mutant background
In conclusion , MelR and CRP bind to the melAB promoter co - operatively to adjacent sites in order to activate transcription in a co - dependent manner
这是我在日志中多次得到的输出
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator tokenize
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator ssplit
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator pos
Reading POS tagger model from edu/stanford/nlp/models/pos-tagger/english-left3words/english-left3words-distsim.tagger ... done [1.1 sec].
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator lemma
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator depparse
Loading depparse model file: edu/stanford/nlp/models/parser/nndep/english_UD.gz ...
PreComputed 100000, Elapsed Time: 2.424 (s)
Initializing dependency parser done [6.8 sec].
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator natlog
[main] INFO edu.stanford.nlp.pipeline.StanfordCoreNLP - Adding annotator openie
Loading clause searcher from edu/stanford/nlp/models/naturalli/clauseSearcherModel.ser.gz...done [0.210 seconds]
Processing file: /almac/ignacio/rie_gce/karla_tests
All files have been queued; awaiting termination...
/almac/ignacio/rie_gce/karla_tests 0 ability show IHF 1 2 9 10 10 11 1.000 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . ability show ihf
/almac/ignacio/rie_gce/karla_tests 0 NanR activate NagC 17 18 22 23 19 20 1.000 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . nanr activate nagc
/almac/ignacio/rie_gce/karla_tests 0 IHF repress ompC transcription 10 11 12 13 13 15 0.620 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . ihf repress ompc transcription
/almac/ignacio/rie_gce/karla_tests 0 NanR activate independently NagC 17 18 22 26 19 20 1.000 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . nanr activate independently nagc
/almac/ignacio/rie_gce/karla_tests 0 NanR activate fimB expression 17 18 22 23 23 25 1.000 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . nanr activate fimb expression
/almac/ignacio/rie_gce/karla_tests 0 NanR activate independently fimB expression 17 18 22 26 23 251.000 the ability of IHF alone to activate fimB expression show IHF to repress ompC transcription Thus , NanR and NagC appear to activate fimB expression independently . DT NN IN NN RB TO VB NN NN VBP NN TO VB NN NN RB , NN CC NN VBP TO VB NN NN RB . nanr activate independently fimb expression
java.lang.IndexOutOfBoundsException: Index: 0, Size: 0
at java.util.ArrayList.rangeCheck(ArrayList.java:653)
at java.util.ArrayList.get(ArrayList.java:429)
at edu.stanford.nlp.ie.util.RelationTriple.toReverbString(RelationTriple.java:373)
at edu.stanford.nlp.naturalli.OpenIE.tripleToString(OpenIE.java:604)
at edu.stanford.nlp.naturalli.OpenIE.processDocument(OpenIE.java:638)
at edu.stanford.nlp.naturalli.OpenIE.lambda$main$12(OpenIE.java:760)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
DONE processing files. 1 exceptions encountered.
我使用的是stanford-corenlp-3.6.0.jar
非常感谢。请发布完整的堆栈跟踪,以便我可以看到IndexOutOfBoundsException发生的位置。您使用的是什么版本的CoreNLP?另外,您是否可以发布失败的文件(或者最好是文件的子集)?提取器似乎生成了一个格式错误的三元组,但是如果没有示例,很难进行调试。您好。。。这个问题有没有可能的线索?谢谢,这个问题在git repo的最新版本代码中得到了解决。