Detection Metrics
detection_metricsScore detections against ground truth and show the working. PREMIUM (license).
Greedy matching at the IoU threshold, highest-confidence prediction first, each ground-truth box matched at most once - the standard protocol. Reports per-class precision, recall and F1, and average precision by the all-points interpolation used by Pascal VOC 2010 onward. Typical input {"predictions": [{"box": [0,0,10,10], "label": "cat", "score": 0.9}], "ground_truth": [{"box": [1,1,11,11], "label": "cat"}]} returns {"overall": {"tp": 1, "fp": 0, "fn": 0, "precision": 1.0, "recall": 1.0, "f1": 1.0}, "per_class": {...}, "mAP": 1.0}.
Use to compare two models on the same held-out set. Not for cleaning up a single model's overlapping output first - run nms before this. Errors: on invalid, missing, or malformed input this tool never raises a protocol error — it returns {"error": ""} (for example {"error": "ground_truth must contain at least one box"}). Every call is read-only and idempotent, so after correcting the input it is always safe to retry.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| box_format | No | "voc", "coco" or "yolo". Default "voc". | voc |
| image_width | No | Pixel width; required for yolo boxes. | |
| predictions | Yes | Predicted boxes, each {"box": [...], "label": ..., "score": ...}. Score defaults to 1.0 when omitted. | |
| ground_truth | Yes | True boxes, each {"box": [...], "label": ...}. | |
| image_height | No | Pixel height; required for yolo boxes. | |
| iou_threshold | No | Overlap at which a prediction counts as a match. Default 0.5, the usual reporting threshold. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||