Skip to content
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

YOLOF/cvpods/_C.cpython-37m-x86_64-linux-gnu.so: undefined symbol: _Z39tree_filter_refine_backward_edge_weightRKN2at6TensorES2_S2_S2_S2_S2_S2_S2_S2_ #24

Open
sundaykingg opened this issue Apr 26, 2021 · 6 comments

Comments

@sundaykingg
Copy link

when I run
cd playground/detection/coco/yolof/yolof.res50.C5.1x
pods_train --num-gpus 8
i get a problem:
YOLOF/cvpods/_C.cpython-37m-x86_64-linux-gnu.so: undefined symbol: Z39tree_filter_refine_backward_edge_weightRKN2at6TensorES2_S2_S2_S2_S2_S2_S2_S2
How should I solve it?

@chensnathan
Copy link
Collaborator

This may help you.

@sundaykingg
Copy link
Author

This may help you.

my CUDA==11.1 and pytorch== 1.8.1+cu111
The problem is still not solved

@chensnathan
Copy link
Collaborator

You may provide more environmental details so that I can help.

@sundaykingg
Copy link
Author

You may provide more environmental details so that I can help.

sorry i check my environmental that cuda and pytorch not match.
when i reinstall cuda and torch,i found a new problem:

In file included from /home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/THC/THCGeneral.h:7:0,
from /home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/THC/THC.h:4,
from /home/hznu/mysoftware/pyproject/YOLOF/cvpods/layers/csrc/PSROIPool/psroi_pool_cuda.h:4,
from /home/hznu/mysoftware/pyproject/YOLOF/cvpods/layers/csrc/vision.cpp:14:
/home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/c10/cuda/CUDAStream.h:6:10: fatal error: cuda_runtime_api.h: No such file or directory
#include <cuda_runtime_api.h>
^~~~~~~~~~~~~~~~~~~~
compilation terminated.
error: command 'gcc' failed with exit status 1

python:3.7
cuda:11.1
pytorch: 1.8.1+cu111
torchvision:0.9.1+cu111

i just run 'python setup.py develop'

@tangjiuqi097
Copy link

This may help you.

my CUDA==11.1 and pytorch== 1.8.1+cu111
The problem is still not solved

Hi, could you try pytorch<1.8?

@ghost
Copy link

ghost commented Dec 18, 2021

You may provide more environmental details so that I can help.

sorry i check my environmental that cuda and pytorch not match. when i reinstall cuda and torch,i found a new problem:

In file included from /home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/THC/THCGeneral.h:7:0, from /home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/THC/THC.h:4, from /home/hznu/mysoftware/pyproject/YOLOF/cvpods/layers/csrc/PSROIPool/psroi_pool_cuda.h:4, from /home/hznu/mysoftware/pyproject/YOLOF/cvpods/layers/csrc/vision.cpp:14: /home/hznu/.conda/envs/yolof/lib/python3.7/site-packages/torch/include/c10/cuda/CUDAStream.h:6:10: fatal error: cuda_runtime_api.h: No such file or directory #include <cuda_runtime_api.h> ^~~~~~~~~~~~~~~~~~~~ compilation terminated. error: command 'gcc' failed with exit status 1

python:3.7 cuda:11.1 pytorch: 1.8.1+cu111 torchvision:0.9.1+cu111

i just run 'python setup.py develop'

Adding these paths to include_dirs in setup.py may solve your problem:
include_dirs = [os.path.realpath('../include'), '/usr/local/cuda/include/']

However, you may still encounter a new problem when using even if you can successfully setup.
Please use 'conda list | grep "cuda" ' to see if the version of conda's cudatoolkit is higer than that of cuda_driver_api(using 'nvidia-smi'), if so, that may be the reason.

BTW, I have also met this error:
"YOLOF/cvpods/_C.cpython-37m-x86_64-linux-gnu.so: undefined symbol : Z39tree_filter_refine_backward_edge_weightRKN2at6TensorES2_S2_S2_S2_S2_S2_S2_S2", and solved it by matching versions of these components. I wrote down the steps in https://zhuanlan.zhihu.com/p/446495433, I hope this will help you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants