Package org.tribuo.sequence
Interface SequenceEvaluator<T extends Output<T>,E extends SequenceEvaluation<T>>
- Type Parameters:
T
- The output type.E
- The evaluation type.
- All Known Implementing Classes:
AbstractSequenceEvaluator
,LabelSequenceEvaluator
public interface SequenceEvaluator<T extends Output<T>,E extends SequenceEvaluation<T>>
An evaluation factory which produces immutable
SequenceEvaluation
s of a given SequenceDataset
using the given SequenceModel
.-
Method Summary
Modifier and TypeMethodDescriptionevaluate
(SequenceModel<T> model, List<List<Prediction<T>>> predictions, DataProvenance dataProvenance) Evaluates the supplied model and predictions by aggregating the appropriate statistics.evaluate
(SequenceModel<T> model, SequenceDataset<T> dataset) Evaluates the dataset using the supplied model, returning an immutable evaluation.evaluate
(SequenceModel<T> model, SequenceDataSource<T> datasource) Evaluates the datasource using the supplied model, returning an immutable evaluation.
-
Method Details
-
evaluate
Evaluates the dataset using the supplied model, returning an immutable evaluation.- Parameters:
model
- The model to use.dataset
- The dataset to evaluate.- Returns:
- An evaluation.
-
evaluate
Evaluates the datasource using the supplied model, returning an immutable evaluation.- Parameters:
model
- The model to use.datasource
- The datasource to evaluate.- Returns:
- An evaluation.
-
evaluate
E evaluate(SequenceModel<T> model, List<List<Prediction<T>>> predictions, DataProvenance dataProvenance) Evaluates the supplied model and predictions by aggregating the appropriate statistics.Warning, this method cannot validate that the predictions were returned by the model in question.
- Parameters:
model
- The model to use.predictions
- The predictions to use.dataProvenance
- The provenance of the test data.- Returns:
- An evaluation of the predictions.
-