facebookresearch / detr

End-to-End Object Detection with Transformers
Apache License 2.0
13.08k stars 2.37k forks source link

Why different criteria for loss calculation and Hungarian matching #590

Open MLDeS opened 1 year ago

MLDeS commented 1 year ago

Thanks for the wonderful work!

I have a question regarding the different criteria for the loss calculation in DETR and for the Hungarian matching. For e.g., for calculating the label cost, in the Hungarian matcher, 1 - proba[target class] is used while for the label loss, NLL is used. Is there a reason for doing this? I am interested to know this because, is there any numerical stability issue if, for e.g., the same/different criteria are used for loss calculation and Hungarian matching?