ifzhang / FairMOT

[IJCV-2021] FairMOT: On the Fairness of Detection and Re-Identification in Multi-Object Tracking
MIT License
4.02k stars 932 forks source link

why is there a need to seperate detection loss and id loss in such a complex way? #213

Closed faruknane closed 4 years ago

faruknane commented 4 years ago

Hi @ifzhang and the people in this community, I try to add one more head to fairmot. I have successfully added it to the model and prepare the data loader according to my new dataset. However, in loss function there is something below that confuses me.

image

I can't understand the reason behind separating the loss into two parts (detection and id) in such a complex way. You could have just multiplied id_loss and det_loss with "constant" coefficient factors to adjust the training to care more about one loss and less about the other one. You made s_det and s_id trainable parameters as coefficients for det_loss and id_loss. Why are those trainable? What you did is also similar to regularization, adding parameters to loss. Is it to prevent s_det and s_id from converging to zero?

ifzhang commented 4 years ago

I follow the multi-task learning uncertainly loss paper that can balance multiple loss: https://arxiv.org/abs/1705.07115

faruknane commented 4 years ago

@ifzhang Thank you for your quick reply. I'll try to read the paper. image