How do I include more than one classifiers when using Stanford named entity recogniser?

本秂侑毒 提交于 2019-11-30 16:08:33

问题


I run following command to start ner server

java -mx1000m -cp stanford-ner.jar edu.stanford.nlp.ie.NERServer -loadClassifier ner-model.ser.gz -port 8081 - outputFormat inlineXML

In here, I have used classifier(ner-model.ser.gz) manually created by me. I want to use default classifier english.muc.7class.distsim.crf.ser.gz(It is given by them) along with the one created by me

I tried following command:

java -mx1000m -cp stanford-ner.jar edu.stanford.nlp.ie.NERServer -loadClassifier classifiers/english.muc.7class.distsim.crf.ser.gz ner-model.ser.gz -port 8081 -outputFormat inlineXML

But it did not work. Please Help since i am new to this.


回答1:


Unfortunately, at present the NERServer code only supports loading one classifier, so there is no solution here without writing code. It would not be a big change to allow NERServer to load multiple classifiers, as Stanford CoreNLP does. Someone who knows Java could do it, or we might do it in some future release, but no particular schedule for that.




回答2:


Can you try adding , in between two archive files

java -mx1000m -cp stanford-ner.jar edu.stanford.nlp.ie.NERServer -loadClassifier classifiers/english.muc.7class.distsim.crf.ser.gz,ner-model.ser.gz -port 8081 -outputFormat inlineXML


来源:https://stackoverflow.com/questions/15746695/how-do-i-include-more-than-one-classifiers-when-using-stanford-named-entity-reco

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!