ClassificationEvaluator#
- class capymoa.evaluation.ClassificationEvaluator[source]#
Bases:
object
Wrapper for the Classification Performance Evaluator from MOA. By default, it uses the BasicClassificationPerformanceEvaluator
- __init__(
- schema: Schema = None,
- window_size=None,
- allow_abstaining=True,
- moa_evaluator=None,
- update(y_target_index: int, y_pred_index: int | None)[source]#
Update the evaluator with the ground-truth and the prediction.
- Parameters:
y_target_index – The ground-truth class index. This is NOT the actual class value, but the index of the class value in the schema.
y_pred_index – The predicted class index. If the classifier abstains from making a prediction, this value can be None.
- Raises:
ValueError – If the values are not valid indexes in the schema.