Package edu.stanford.nlp.util

Examples of edu.stanford.nlp.util.MutableInteger.intValue()


  public void printLattice(DFSA tagLattice, List<CoreLabel> doc, PrintWriter out) {
    CoreLabel[] docArray = doc.toArray(new CoreLabel[doc.size()]);
    // Create answer lattice:
    MutableInteger nodeId = new MutableInteger(0);
    DFSA answerLattice = new DFSA(null);
    DFSAState aInitState = new DFSAState(nodeId.intValue(),answerLattice);
    answerLattice.setInitialState(aInitState);
    Map<DFSAState,DFSAState> stateLinks = new HashMap<DFSAState,DFSAState>();
    // Convert binary lattice into word lattice:
    tagLatticeToAnswerLattice
    (tagLattice.initialState(), aInitState, new StringBuilder(""), nodeId, 0, 0.0, stateLinks, answerLattice, docArray);
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.