sgrvinod / a-PyTorch-Tutorial-to-Object-Detection

SSD: Single Shot MultiBox Detector | a PyTorch Tutorial to Object Detection
MIT License
3.05k stars 719 forks source link

cxcy_to_gcxgcy function return nan values #54

Open anesh-ml opened 4 years ago

anesh-ml commented 4 years ago

I traced back where the nan is coming from the loss function. It leads to cxcy_to_gcxgcy function. Division is causing nan value it seems. please provide any solution for this.

Tathagatd96 commented 4 years ago

I am facing the same issue. @Eloneinstein , did u find any solution?

failable commented 4 years ago

@Eloneinstein @Tathagatd96 Have you fixed this issue?

TommyHuang821 commented 3 years ago

In my observation, it may happen when mis-order for bbox. BBOX usually places with order [left-top(x),left-top(y), right-down(x), right-down(y)], but nan will occur with [right-down(x), right-down(y), left-top(x),left-top(y)].

m-evdokimov commented 3 years ago

@TommyHuang821 that was my problem, thanks!

destr4ct commented 2 years ago

In my observation, it may happen when mis-order for bbox. BBOX usually places with order [left-top(x),left-top(y), right-down(x), right-down(y)], but nan will occur with [right-down(x), right-down(y), left-top(x),left-top(y)].

@TommyHuang821 that was my problem, thanks! Same!

JYeonKim commented 2 years ago

@destr4ct Hi! I have the same problem. How did you solve it? I'd really appreciate it if you told me. thank you!