JonathonLuiten / TrackEval

HOTA (and other) evaluation metrics for Multi-Object Tracking (MOT).
MIT License
965 stars 239 forks source link

bug in intersection_over_area calculation #42

Open AvanDavad opened 3 years ago

AvanDavad commented 3 years ago

Hi, I found a bug here: https://github.com/JonathonLuiten/TrackEval/blob/d86fa9e62d2f3a1bdbbff4b2f3e92e8becd94cbf/trackeval/datasets/_base_dataset.py#L273

if bboxes1 and bboxes2 both have whole numbers, then ioas will have np.int dtype, and so at the end all values will be zeros (or 1 if a particular box is 100% inside the other box)

To fix this, let's do this: ioas = np.zeros_like(intersection).astype(np.float) OR (maybe) convert bboxes1 and bboxes2 to float at the very beginning.

AvanDavad commented 3 years ago

so to be more precise, this occurs when the dtype of both bboxes1 and bboxes2 are int