RuntimeError: CUDA error: invalid device function (hard_voxelize_gpu at mmdet3d/ops/voxel/src/voxelization_cuda.cu:232) #188
Labels
installation/environment
Installation and environment issues
Describe the bug
File "tools/test.py", line 152, in
main()
File "tools/test.py", line 130, in main
outputs = single_gpu_test(model, data_loader, args.show, args.show_dir)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/apis/test.py", line 29, in single_gpu_test
result = model(return_loss=False, rescale=True, **data)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/mmcv/parallel/data_parallel.py", line 42, in forward
return super().forward(*inputs, **kwargs)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/nn/parallel/data_parallel.py", line 150, in forward
return self.module(*inputs[0], **kwargs[0])
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/mmcv/runner/fp16_utils.py", line 84, in new_func
return old_func(*args, **kwargs)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/models/detectors/base.py", line 61, in forward
return self.forward_test(**kwargs)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/models/detectors/base.py", line 42, in forward_test
return self.simple_test(points[0], img_metas[0], img[0], **kwargs)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/models/detectors/voxelnet.py", line 98, in simple_test
x = self.extract_feat(points, img_metas)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/models/detectors/voxelnet.py", line 40, in extract_feat
voxels, num_points, coors = self.voxelize(points)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/autograd/grad_mode.py", line 49, in decorate_no_grad
return func(*args, **kwargs)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/mmcv/runner/fp16_utils.py", line 164, in new_func
return old_func(*args, **kwargs)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/models/detectors/voxelnet.py", line 55, in voxelize
res_voxels, res_coors, res_num_points = self.voxel_layer(res)
File "/home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, kwargs)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxelize.py", line 113, in forward
self.max_num_points, max_voxels)
File "/home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxelize.py", line 53, in forward
coors_range, max_points, max_voxels, 3)
RuntimeError: CUDA error: invalid device function (hard_voxelize_gpu at mmdet3d/ops/voxel/src/voxelization_cuda.cu:232)
frame #0: c10::Error::Error(c10::SourceLocation, std::string const&) + 0x47 (0x7fe0603f8627 in /home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/lib/libc10.so)
frame #1: voxelization::hard_voxelize_gpu(at::Tensor const&, at::Tensor&, at::Tensor&, at::Tensor&, std::vector<float, std::allocator >, std::vector<float, std::allocator >, int, int, int) + 0x819 (0x7fdffdac175b in /home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxel_layer.cpython-37m-x86_64-linux-gnu.so)
frame #2: voxelization::hard_voxelize(at::Tensor const&, at::Tensor&, at::Tensor&, at::Tensor&, std::vector<float, std::allocator >, std::vector<float, std::allocator >, int, int, int) + 0x117 (0x7fdffda7fa77 in /home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxel_layer.cpython-37m-x86_64-linux-gnu.so)
frame #3: + 0x4371c (0x7fdffda8a71c in /home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxel_layer.cpython-37m-x86_64-linux-gnu.so)
frame #4: + 0x4396e (0x7fdffda8a96e in /home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxel_layer.cpython-37m-x86_64-linux-gnu.so)
frame #5: + 0x3f651 (0x7fdffda86651 in /home/nio/pointdet/mmdetection3d/mmdet3d/ops/voxel/voxel_layer.cpython-37m-x86_64-linux-gnu.so)
frame #11: THPFunction_apply(_object, _object) + 0xa0f (0x7fe0929cda3f in /home/nio/anaconda3/envs/mm3d/lib/python3.7/site-packages/torch/lib/libtorch_python.so)
Segmentation fault (core dumped)
Reproduction
Did you make any modifications on the code or config? Did you understand what you have modified?
NO modifications.
What dataset did you use?
kitti.
Environment
Please run
python mmdet3d/utils/collect_env.py
to collect necessary environment infomation and paste it here.sys.platform: linux
Python: 3.7.9 (default, Aug 31 2020, 12:42:55) [GCC 7.3.0]
CUDA available: True
GPU 0: GeForce GTX 1080 Ti
CUDA_HOME: /usr/local/cuda
NVCC: Cuda compilation tools, release 10.0, V10.0.130
GCC: gcc (Ubuntu 5.4.0-6ubuntu1~16.04.12) 5.4.0 20160609
PyTorch: 1.4.0
PyTorch compiling details: PyTorch built with:
TorchVision: 0.5.0
OpenCV: 4.4.0
MMCV: 1.1.6
MMCV Compiler: GCC 7.3
MMCV CUDA Compiler: 10.0
MMDetection: 2.6.0
MMDetection3D: 0.7.0+37ce187
conda
$PATH
,$LD_LIBRARY_PATH
,$PYTHONPATH
, etc.)Error traceback
If applicable, paste the error trackback here.
Bug fix
If you have already identified the reason, you can provide the information here. If you are willing to create a PR to fix it, please also leave a comment here and that would be much appreciated!
The text was updated successfully, but these errors were encountered: