seg_dice_jaccard — SEGMENTATION score op

• Data kinds: labels2d × labels2d → table

• Call: import fullseye as fs; fs.ledger.seg_dice_jaccard(labels_pred, labels_true, *, background: 'int' = 0, per_label: 'bool' = False) -> 'Dict[str, object]' (to call the implementation directly, import segeval; segeval.seg_dice_jaccard(labels_pred, labels_true, *, background: 'int' = 0, per_label: 'bool' = False) -> 'Dict[str, object]'; from the registry, opssegmentation.get("seg_dice_jaccard"))

Usage

Dice and Jaccard — once over the mask (union of non-background pixels), or per true label against its max-overlap partner (seg_dice_jaccard).

Mask: intersection = number of pixels that are non-background in both, size_pred / size_true, union. Jaccard J = ∩/∪, Dice D = 2∩/(|P|+|T|). If both are empty, 1 (it correctly said there is nothing). Identity D = 2J/(1+J) (gate). per_label=True adds labels (non-background true labels), per_dice / per_jaccard (0 if there is no partner), mean_dice / mean_jaccard.

Detailed usage guide

• halcon_segmentation family guide

Background guides (the physics and conventions behind this op)

• segmentation_scoring_and_worlds — Scoring segmentations and synthetic worlds with ground truth — which metric is blind to which failure

References (sample data, literature)

• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).

• Operator provenance and references — the sources of the research/methods this op family came from.

• The canonical algorithm (author, year) and its uses are named in the family usage guide above.

Runnable examples (verified samples that actually call this op)

• poc_active_contours — py -3.11 examples/poc_active_contours.py

• poc_am_thermal_to_ct — py -3.11 examples/poc_am_thermal_to_ct.py

• poc_graph_hierarchy_segmentation — py -3.11 examples/poc_graph_hierarchy_segmentation.py

• poc_segmentation_gauntlet — py -3.11 examples/poc_segmentation_gauntlet.py

Ops the type connects to (they accept table as input)

class_ndim_norm

Same category (score)

seg_confusion_table · seg_boundary_f · seg_hausdorff · seg_mean_surface_distance · seg_under_over_segmentation · seg_object_counts_match · seg_score_card


*Provenance: segeval.py — SEGMENTATION operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.