Examples of STPriorModel


Examples of opennlp.ccg.parse.supertagger.ml.STPriorModel

  }

  @Override
  public void loadPriorModel(File priorModelFile, File vocabFile) {
    try {
      priorModel = new STPriorModel(priorModelFile.getAbsolutePath(), vocabFile.getAbsolutePath());
    } catch (IOException e) {
      System.err.println("Unable to load prior model or vocab file");
      e.printStackTrace();
    }
  }
View Full Code Here

Examples of opennlp.ccg.parse.supertagger.ml.STPriorModel

        assert (priorModS == null || (firstKS != null & lastKS != null)) : "need to specify first and last 'K' value when not using prior model.";
       
        // seqMod probably shouldn't be null. warn if in verbose mode.
        if(seqModS == null && verbose) { System.err.println("Warning: empty sequence model. Performance will suffer."); }
       
        STPriorModel priorM = null;
        if(priorModS != null && priorVocabS != null) {
            try { priorM = new STPriorModel(priorModS, priorVocabS); }
            catch (IOException ex) {
                Logger.getLogger(WordAndPOSDictionaryLabellingStrategy.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
        STFex fex = new STFex(priorM);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.