average_interval_width¶
- probly.metrics.average_interval_width = <flextype.singledispatch.Flexdispatch object>¶
Compute the mean width of per-class probability intervals.
A geometric companion to
efficiency()for credal sets that expose a meaningful per-class interval (probability-intervals, distance-based, and Dirichlet-level-set credal sets). Smaller is better. Defined as the mean ofupper - lowerover both samples and classes.- Parameters:
y_pred – An envelope-based credal set with
lower()/upper()methods.- Returns:
The mean per-class interval width as a float.
- Raises:
NotImplementedError – If no implementation is registered for the type of
y_pred.