braun-steven / DAFNe

Code for our paper "DAFNe: A One-Stage Anchor-Free Deep Model for Oriented Object Detection".
MIT License
60 stars 12 forks source link

No module named 'poly_nms' #4

Closed adickskylar closed 2 years ago

adickskylar commented 2 years ago

Hello, i cloned the repo, followed the readme, installed requirements but am getting an error when i run >python plain_train_net.py

The error is being thrown from nms/nms.py imports: from poly_nms import poly_gpu_nms

I gather these are part of the DOTA devkit. i tried copying the contents of the poly_nms_gpu folder from the devkit into the nms folder but that did not fix the error. Are the imports for poly_nms and poly_overlaps meant to import the cython .pyx files? How do i set up things up for these imports to work correctly?

Thanks,

adickskylar commented 2 years ago

Resolved this by compiling the polyiou.i via: swig -c++ -python polyiou.i python setup.py build_ext --inplace and compiling poly_nms and poly_overlaps via: python setup.py build_ext --inplace

then copying the .so into the dir for the calling modules

cheers!

braun-steven commented 2 years ago

Sorry for the late reply. I'm glad you could resolve it!

I haven't covered the step-by-step installation instructions for a manual environment installation since I'm offering a full Docker solution where the steps that you found are also used, see https://github.com/steven-lang/DAFNe/blob/52d6bf8a3c95fe86cd27612528d58b51a2b9994a/Dockerfile#L37..L42.