Skip to content

Fix HOTA overall aggregation#209

Merged
cheind merged 1 commit into
cheind:developfrom
mikel-brostrom:agent/fix-hota-overall-aggregation
Jul 10, 2026
Merged

Fix HOTA overall aggregation#209
cheind merged 1 commit into
cheind:developfrom
mikel-brostrom:agent/fix-hota-overall-aggregation

Conversation

@mikel-brostrom

@mikel-brostrom mikel-brostrom commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

Fixes the OVERALL aggregation for HOTA-family metrics so py-motmetrics combines sequences the same way TrackEval does.

The previous merge functions averaged per-sequence deta_alpha, assa_alpha, and hota_alpha directly. TrackEval instead sums detection counts for DetA, weights association accuracy by true positives/detections, and recomputes HOTA = sqrt(DetA * AssA) from those aggregate values.

This PR updates deta_alpha_m, assa_alpha_m, and hota_alpha_m, and adds combined-sequence TUD fixture regression coverage.

It also moves the optional xmltodict import into load_detrac_xml, so MOT-only tests do not require the DETRAC XML dependency at import time.

Hopefully this fix the HOTA issues once and for all 😄

Validation

  • uv run pytest motmetrics/tests/test_metrics.py::test_hota -q

I also checked the py-motmetrics bundled TUD fixtures against BoxMOT’s bundled TrackEval implementation; combined and per-sequence HOTA, DetA, and AssA matched exactly.

@mikel-brostrom mikel-brostrom marked this pull request as ready for review July 10, 2026 09:06
@cheind cheind merged commit 2ea1012 into cheind:develop Jul 10, 2026
0 of 3 checks passed
@cheind

cheind commented Jul 10, 2026

Copy link
Copy Markdown
Owner

thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants