lilanxiao / Rotated_IoU

Differentiable IoU of rotated bounding boxes using Pytorch
MIT License
416 stars 64 forks source link

Batch computation for IoU Loss #50

Open Steven-m2ai opened 2 years ago

Steven-m2ai commented 2 years ago

Hello,

Thank you for your work. I have a question regarding the demo / the functionality of the cal_giou and cal_giou_3d functions.

It looks like from the demo the inputs must be the same size. that is, [Batch, Number of boxes, 7] for the 3D case. However, if we have say 2 ground truth boxes in an image, and our model predicts 100 bounding boxes [B, 100,7], is there a way to compute the IoU between each of the boxes to the 2 ground truth boxes? [B,100,7] and [B,2,7] comparison.

--> meaning every predicted box from the 100 is compared to each of the 2 ground truth boxes. thus for any batch, there are 200 comparisons made

Thanks for your time

CloudRider-pixel commented 1 year ago

Hi @Steven-m2ai , Did you manage to do that?

jbohnslav commented 3 months ago

I'm also interested in the case where the number of boxes do not match.

mburges-cvl commented 1 month ago

I would also be interested in that case :)