public class Evaluate extends AbstractEvaluate
NF| Constructor and Description |
|---|
Evaluate(SentimentModel model) |
| Modifier and Type | Method and Description |
|---|---|
static void |
main(String[] args)
Expected arguments are
-model model -treebank treebank
For example
java edu.stanford.nlp.sentiment.Evaluate
edu/stanford/nlp/models/sentiment/sentiment.ser.gz
/u/nlp/data/sentiment/trees/dev.txt
Other arguments are available, for example -numClasses. |
void |
populatePredictedLabels(List<Tree> trees)
Sets the predicted sentiment label for all trees given.
|
approxAccuracy, approxCombinedAccuracy, countLengthAccuracy, countRoot, countTree, eval, eval, exactNodeAccuracy, exactRootAccuracy, lengthAccuracies, printConfusionMatrix, printLengthAccuracies, printSummary, resetpublic Evaluate(SentimentModel model)
public void populatePredictedLabels(List<Tree> trees)
AbstractEvaluateRNNCoreAnnotations.PredictedClass annotation
for all nodes in all trees.populatePredictedLabels in class AbstractEvaluatetrees - List of Trees to be annotatedpublic static void main(String[] args)
-model model -treebank treebank
java edu.stanford.nlp.sentiment.Evaluate
edu/stanford/nlp/models/sentiment/sentiment.ser.gz
/u/nlp/data/sentiment/trees/dev.txt
Other arguments are available, for example -numClasses.
See RNNOptions.java, RNNTestOptions.java and RNNTrainOptions.java for
more arguments.
The configuration is usually derived from the RNN model file, which is
not available here as the predictions are external. It is the caller's
responsibility to provide a configuration matching the settings of
the external predictor. Flags of interest include
-equivalenceClasses .