Class EvaluationErrorPrinter<T>
java.lang.Object
opennlp.tools.cmdline.EvaluationErrorPrinter<T>
- All Implemented Interfaces:
EvaluationMonitor<T>
- Direct Known Subclasses:
ChunkEvaluationErrorListener, DetokenEvaluationErrorListener, DoccatEvaluationErrorListener, LanguageDetectorEvaluationErrorListener, LemmaEvaluationErrorListener, NameEvaluationErrorListener, POSEvaluationErrorListener, SentenceEvaluationErrorListener, TokenEvaluationErrorListener
@Internal
public abstract class EvaluationErrorPrinter<T>
extends Object
implements EvaluationMonitor<T>
Note: Do not use this class, internal use only!
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedEvaluationErrorPrinter(OutputStream outputStream) protectedEvaluationErrorPrinter(PrintStream printStream) -
Method Summary
Modifier and TypeMethodDescriptionvoidcorrectlyClassified(T reference, T prediction) private voidfindErrors(Span[] references, Span[] predictions, List<Span> falseNegatives, List<Span> falsePositives) Outputs falseNegatives and falsePositives spans from the references and predictions list.abstract voidmisclassified(T reference, T prediction) private StringAuxiliary method to print spansprotected voidprintError(String[] references, String[] predictions, T referenceSample, T predictedSample, String[] sentenceTokens) protected voidprintError(String id, Span[] references, Span[] predictions, T referenceSample, T predictedSample, String[] sentenceTokens) protected voidprintError(Span[] references, Span[] predictions, T referenceSample, T predictedSample, String sentence) protected voidprintError(Span[] references, Span[] predictions, T referenceSample, T predictedSample, String[] sentenceTokens) protected voidprintError(T referenceSample, T predictedSample) private voidAuxiliary method to print tag errorsprivate voidAuxiliary method to print span errorsprivate voidAuxiliary method to print span errorsprivate <S> voidprintSamples(S referenceSample, S predictedSample) Auxiliary method to print expected and predicted samples.
-
Field Details
-
printStream
-
-
Constructor Details
-
EvaluationErrorPrinter
-
EvaluationErrorPrinter
-
-
Method Details
-
printError
-
printError
-
printError
-
printError
-
printError
-
printErrors
-
printErrors
-
printErrors
-
print
-
printSamples
-
findErrors
-
correctlyClassified
- Specified by:
correctlyClassifiedin interfaceEvaluationMonitor<T>
-
misclassified
- Specified by:
misclassifiedin interfaceEvaluationMonitor<T>
-