Segmentation
Intersection over union
Implemented
segmentation.iouDefinition
Ratio of the intersection to the union of predicted and ground-truth masks (Jaccard index).
Formula
IoU = |A ∩ B| / |A ∪ B|
Range: [0, 1]
Inputs and outputs
- y_true: ground-truth mask (H×W or N×H×W)
- y_pred: predicted mask with the same shape
Returns: float or per-class array
Assumptions
No assumptions beyond valid, aligned inputs of the documented types.
Limitations
No metric-specific limitations are documented yet. Interpret the value alongside the task, data, and other metrics.
Python API
import evalsuite as es
es.iou(y_true, y_pred, average=None) # per class; absent classes are NaNReferences
- Jaccard, P. (1912). The distribution of the flora in the alpine zone. New Phytologist, 11(2), 37–50.