All Downloads are FREE. Search and download functionalities are using the official Maven repository.

cc.mallet.fst.ShallowTransducerTrainer Maven / Gradle / Ivy

Go to download

MALLET is a Java-based package for statistical natural language processing, document classification, clustering, topic modeling, information extraction, and other machine learning applications to text.

The newest version!
package cc.mallet.fst;

import cc.mallet.types.InstanceList;

/**
 * Wraps around an already trained Transducer model. 

* * Use this class to pass to the *Evaluator.evaluateInstanceList when we * don't have access to the *Trainer that was used to train the Transducer model. * * @author Gaurav Chandalia * @deprecated Use NoopTransducerTrainer instead */ public class ShallowTransducerTrainer extends TransducerTrainer { protected Transducer transducer; public ShallowTransducerTrainer(Transducer transducer) { this.transducer = transducer; } public int getIteration() { return 0; } public Transducer getTransducer() { return transducer; } public boolean isFinishedTraining() { return false; } public boolean train(InstanceList trainingSet, int numIterations) { throw new IllegalStateException("Cannot use this class for training"); } }





© 2015 - 2025 Weber Informatics LLC | Privacy Policy