py-faster-rcnn
py-faster-rcnn copied to clipboard
I found gpu_nms and cpu_nms gave different results
The first figure is from gpu_nms. I found the first and the second bbox overlap above 90% (The nms IoU threshold is 50%)
@rbgirshick could you help me? Why the result of gpu_nms seems wrong?
can you show the difference between gpu_nms and cpu_nms result?
I can get equal GPU/CPU result by your example.
import numpy as np
from nms import nms, gpu_nms
dets = np.array([[1.54879288e+02, 5.63751030e+01, 2.00795334e+02, 1.76900604e+02, 9.13123965e-01],
[1.54429581e+02, 5.55528603e+01, 2.00706253e+02, 1.78303726e+02, 9.10487592e-01],
[8.22127075e+01, 6.74252090e+01, 1.21588181e+02, 1.85179321e+02, 8.45470846e-01],
[8.26999969e+01, 6.73755112e+01, 1.21075806e+02, 1.85062042e+02, 8.18630576e-01],
[1.52734726e+02, 5.55439453e+01, 1.99126022e+02, 1.76959335e+02, 5.77099562e-01],
[2.87755089e+01, 6.29712677e+01, 9.89483795e+01, 2.14977646e+02, 4.13117468e-01],
[4.41039162e+01, 6.47515717e+01, 9.48828735e+01, 2.05074326e+02, 2.21668169e-01],
[2.20986038e+02, 5.58766098e+01, 2.48486771e+02, 1.75349884e+02, 1.01995334e-01]],
dtype=np.float32)
print nms(dets, thresh=0.3)
print gpu_nms(dets, thresh=0.3, device_id=0)
the output is: [0, 2, 5, 7] [0, 2, 5, 7] @ahwangyuwei
@ahwangyuwei Hi, I'm facing the same problem, have u solve it yet? Could u plz share your solution here?