-
Notifications
You must be signed in to change notification settings - Fork 21.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Non Maximum Suppression #5404
Non Maximum Suppression #5404
Conversation
@soumith in that thread you mentioned that this would be an addition until we get ATen extensions, which are in master now. Do we want to start adding C++ code to vision? |
@pytorchbot test this please |
I think the place for NMS is in |
I agree, the place for this is torchvision. Please co-ordinate with @fmassa on where to put this in torchvision (unless fmassa already has NMS written and in-flight). In fact, we are removing the ROIPooling stuff that is currently in ATen/native as well. |
This PR implements Non Maximum Suppression, as per pytorch/vision#392. For more rigorous (but slower) correctness tests than the one in test_nn.py, as well as a benchmarking script, take a look at https://github.com/dssa56/projects/tree/master/nms. The gpu implementation here is a bit naive, but still performs quite well. I ran into performance problems with allocating and freeing intermediate buffers when trying a more sophisticated implementation; you can see what I was aiming for there if you look at "nms_cuda_workspace.cu" in the repo I linked to above.