Error building extension '_prroi_pooling'

Viewed 26

I am installing pytracking,but I found a problem compiling the '_prroi_pooling'

Using /tmp/torch_extensions as PyTorch extensions root...
Detected CUDA files, patching ldflags
Emitting ninja build file /tmp/torch_extensions/_prroi_pooling/build.ninja...
Building extension module _prroi_pooling...
[1/3] c++ -MMD -MF prroi_pooling_gpu.o.d -DTORCH_EXTENSION_NAME=_prroi_pooling -DTORCH_API_INCLUDE_EXTENSION_H -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/torch/csrc/api/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/TH -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/THC -isystem /usr/local/cuda/include -isystem /home/gy/anaconda3/envs/pytracking/include/python3.7m -D_GLIBCXX_USE_CXX11_ABI=0 -fPIC -std=c++11 -c /home/gy/pytracking/ltr/external/PreciseRoIPooling/pytorch/prroi_pool/src/prroi_pooling_gpu.c -o prroi_pooling_gpu.o
[2/3] /usr/local/cuda/bin/nvcc -DTORCH_EXTENSION_NAME=_prroi_pooling -DTORCH_API_INCLUDE_EXTENSION_H -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/torch/csrc/api/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/TH -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/THC -isystem /usr/local/cuda/include -isystem /home/gy/anaconda3/envs/pytracking/include/python3.7m -D_GLIBCXX_USE_CXX11_ABI=0 -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options '-fPIC' -std=c++11 -c /home/gy/pytracking/ltr/external/PreciseRoIPooling/pytorch/prroi_pool/src/prroi_pooling_gpu_impl.cu -o prroi_pooling_gpu_impl.cuda.o
FAILED: /usr/local/cuda/bin/nvcc -DTORCH_EXTENSION_NAME=_prroi_pooling -DTORCH_API_INCLUDE_EXTENSION_H -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/torch/csrc/api/include -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/TH -isystem /home/gy/anaconda3/envs/pytracking/lib/python3.7/site-packages/torch/include/THC -isystem /usr/local/cuda/include -isystem /home/gy/anaconda3/envs/pytracking/include/python3.7m -D_GLIBCXX_USE_CXX11_ABI=0 -D__CUDA_NO_HALF_OPERATORS__ -D__CUDA_NO_HALF_CONVERSIONS__ -D__CUDA_NO_HALF2_OPERATORS__ --expt-relaxed-constexpr --compiler-options '-fPIC' -std=c++11 -c /home/gy/pytracking/ltr/external/PreciseRoIPooling/pytorch/prroi_pool/src/prroi_pooling_gpu_impl.cu -o prroi_pooling_gpu_impl.cuda.o
/home/gy/pytracking/ltr/external/PreciseRoIPooling/pytorch/prroi_pool/src/prroi_pooling_gpu_impl.cu(1): error: expected a declaration

I have set path of cuda10.0 in ./bashrc with path "/home/gy/usr/local/cuda10/bin",but the code above "/usr/local/cuda/bin/nvcc" is the common cuda(version 11.3) of the lab's server ,the instructions above possibly showed by 'ninja -v',thanks

0 Answers
Related