AttributeError: module 'model.nms._ext.nms' has no attribute 'nms_cuda'
See original GitHub issueI’m running from the master branch with PyTorch 0.4.0 and CUDA 9.0. I already ran sh make.sh and everything compiled without errors. When I run trainval_net.py, however, I’m getting this error:
Loading pretrained weights from data/pretrained_model/resnet101_caffe.pth
Traceback (most recent call last):
File "trainval_net.py", line 320, in <module>
rois_label = fasterRCNN(im_data, im_info, gt_boxes, num_boxes)
File "/n/fs/unpcap/py36/lib64/python3.6/site-packages/torch/nn/modules/module.py", line 491, in __call__
result = self.forward(*input, **kwargs)
File "/n/fs/unpcap/bfeng/faster-rcnn.pytorch/lib/model/faster_rcnn/faster_rcnn.py", line 50, in forward
rois, rpn_loss_cls, rpn_loss_bbox = self.RCNN_rpn(base_feat, im_info, gt_boxes, num_boxes)
File "/n/fs/unpcap/py36/lib64/python3.6/site-packages/torch/nn/modules/module.py", line 491, in __call__
result = self.forward(*input, **kwargs)
File "/n/fs/unpcap/bfeng/faster-rcnn.pytorch/lib/model/rpn/rpn.py", line 78, in forward
im_info, cfg_key))
File "/n/fs/unpcap/py36/lib64/python3.6/site-packages/torch/nn/modules/module.py", line 491, in __call__
result = self.forward(*input, **kwargs)
File "/n/fs/unpcap/bfeng/faster-rcnn.pytorch/lib/model/rpn/proposal_layer.py", line 148, in forward
keep_idx_i = nms(torch.cat((proposals_single, scores_single), 1), nms_thresh, force_cpu=not cfg.USE_GPU_NMS)
File "/n/fs/unpcap/bfeng/faster-rcnn.pytorch/lib/model/nms/nms_wrapper.py", line 21, in nms
return nms_gpu(dets, thresh) if force_cpu == False else nms_cpu(dets, thresh)
File "/n/fs/unpcap/bfeng/faster-rcnn.pytorch/lib/model/nms/nms_gpu.py", line 10, in nms_gpu
nms.nms_cuda(keep, dets, num_out, thresh)
AttributeError: module 'model.nms._ext.nms' has no attribute 'nms_cuda'
srun: error: node717: task 0: Exited with exit code 1
Any idea why this is happening? Thank you!
Issue Analytics
- State:
- Created 5 years ago
- Reactions:3
- Comments:8
Top Results From Across the Web
AttributeError: 'module' object has no attribute 'model'
It's called models.Model and not models.model (case sensitive). Fix your Poll model like this - class Poll(models.Model): question = models.
Read more >Blog - Open3D
Here are the highlights: Open3D visualization now works on Google Colab, and CPU rendering is now easy to use on all Linux machines....
Read more >Changelog — MMDetection 2.26.0 documentation
This change has no effect on the pre-trained models in the v2.x model zoo, but will affect the training of all models with...
Read more >ModuleNotFoundError: No Module named nms.gpu_nms
If your program nms_wrapper is unable to find nms.gpu_nms or nms.cpu_nms then we need to do a few modifications in the nms.wrapper.py file...
Read more >RuntimeError: CUDA error: no kernel image is available for ...
RuntimeError: CUDA error: no kernel image is available for execution ... line 1, in <module> AttributeError: module 'torch' has no attribute ...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Compile the cuda dependencies using following simple commands:] cd lib sh make.sh
Read the documentation
Hi, @mohanrobotics Could you please provide me a docker image? Appreciate it if you help me!