supervision/tests/dataset
Copilot 38be1be4b2
Fix lossy COCO round-trip: preserve `area` and `iscrowd` in `as_coco` (#2185)
* fix: preserve area and iscrowd from detection data in COCO export
* fix: use np.asarray().item() to satisfy mypy in iscrowd/area extraction
* test: shorten test name to fix ruff E501 line-length violation
* test: verify data["area"] overrides bbox area when mask is present
* test: stricter iscrowd type check (bool subclass fix)
* test: stricter iscrowd type check in preserves_iscrowd_from_data
* test: stricter iscrowd type check in iscrowd_is_int_when_mask_provided
* fix: prefer data["iscrowd"] over geometry when mask is present

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: Borda <6035284+Borda@users.noreply.github.com>
Co-authored-by: Claude Code <noreply@anthropic.com>
2026-03-30 20:17:42 +02:00
..
formats Fix lossy COCO round-trip: preserve `area` and `iscrowd` in `as_coco` (#2185) 2026-03-30 20:17:42 +02:00
__init__.py refactor: reorganize project structure and update module imports (#2112) 2026-02-03 15:24:47 +01:00
test_core.py fix: populate class_name in DetectionDataset annotations (#2156) 2026-02-25 19:37:59 +01:00
test_utils.py Add `match` arguments to all `pytest.raises` for more precise error validation in tests (#2145) 2026-02-10 21:22:55 +09:00