ConfusionMatrix#
- class openstef_beam.metrics.ConfusionMatrix(true_positives, true_negatives, false_positives, false_negatives, effective_true_positives, ineffective_true_positives)[source]#
Bases:
NamedTupleConfusion matrix components for peak detection in energy forecasting.
This class represents the results of classifying energy load peaks versus non-peaks, with additional effectiveness metrics to account for the direction and magnitude of prediction errors.
- Variables:
true_positives – Boolean array indicating correctly predicted peaks.
true_negatives – Boolean array indicating correctly predicted non-peaks.
false_positives – Boolean array indicating incorrectly predicted peaks.
false_negatives – Boolean array indicating missed peaks.
effective_true_positives – Boolean array indicating true positives that are effective (peak correctly predicted with appropriate magnitude/direction).
ineffective_true_positives – Boolean array indicating true positives that are ineffective (peak correctly predicted but with wrong magnitude/direction).
Note
All arrays have shape (num_samples,) and correspond to the same time points in the original forecast evaluation.
-
true_positives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 0
-
true_negatives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 1
-
false_positives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 2
-
false_negatives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 3
-
effective_true_positives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 4
-
ineffective_true_positives:
ndarray[tuple[Any,...],dtype[bool]]# Alias for field number 5