Tianxiaomo / pytorch-YOLOv4

PyTorch ,ONNX and TensorRT implementation of YOLOv4
Apache License 2.0
4.48k stars 1.49k forks source link

different loss functions for loss_xy and loss_wh #71

Open love2learn-7179 opened 4 years ago

love2learn-7179 commented 4 years ago

May I ask why you use F.binary_cross_entropy for loss_xy while you use F.mse_loss for loss_wh? And, (1) why did you divide by 2 for loss_wh? (you didn't divide by 2 for loss_xy) (2) I thought that yolov4 uses CIoU loss for bbox regression (x, y, w, h), no?

Thank you for your help.

Sooryakiran commented 2 years ago

Hi. Same doubt here. Please let me know if you have any extra information regarding the same.