ifzhang / ByteTrack

[ECCV 2022] ByteTrack: Multi-Object Tracking by Associating Every Detection Box
MIT License
4.69k stars 891 forks source link

fix FP16 bug of track_id annotation, ReID related #184

Closed HanGuangXin closed 2 years ago

HanGuangXin commented 2 years ago

When training with FP16, annotations of bbox and track_id named as targets will be set to torch.float16 from torch.float32.

But actually, track_id annotations will lose their precision during this procedure, resulting wrong labels for ReID module.

tensor FP16

So with the wrong labels, ReID module can not be trained normally, getting extreme low mAP and top-k ranking in person search benchmarks.

search wrong label

After fixing this bug, we can get normal results.

search correct label

bdpk123 commented 2 weeks ago

Do you mean that we'd better train with torch.float32?