pytracking
pytracking copied to clipboard
_prroi_pooling.so: cannot open shared object file
I'm trying to run the tracker with a webcam or in a video but it gives this error: ImportError: /home/user/.cache/torch_extensions/py39_cu113/_prroi_pooling/_prroi_pooling.so: cannot open shared object file: No such file or directory
and ImportError: Can not compile Precise RoI Pooling library.
Here is my Traceback:
/home/user/Documents/Computer Vision/pytracking/pytracking/../pytracking/features/preprocessing.py:109: UserWarning: floordiv is deprecated, and its behavior will change in a future version of pytorch. It currently rounds toward 0 (like the 'trunc' function NOT 'floor'). This results in incorrect rounding for negative values. To keep the current behavior, use torch.div(a, b, rounding_mode='trunc'), or for actual floor division, use torch.div(a, b, rounding_mode='floor').
tl = posl - (szl - 1) // 2
/home/user/Documents/Computer Vision/pytracking/pytracking/../pytracking/features/preprocessing.py:110: UserWarning: floordiv is deprecated, and its behavior will change in a future version of pytorch. It currently rounds toward 0 (like the 'trunc' function NOT 'floor'). This results in incorrect rounding for negative values. To keep the current behavior, use torch.div(a, b, rounding_mode='trunc'), or for actual floor division, use torch.div(a, b, rounding_mode='floor').
br = posl + szl//2 + 1
/home/user/anaconda3/envs/pytracking/lib/python3.9/site-packages/torch/nn/functional.py:3631: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details.
warnings.warn(
Using /home/user/.cache/torch_extensions/py39_cu113 as PyTorch extensions root...
Detected CUDA files, patching ldflags
Emitting ninja build file /home/user/.cache/torch_extensions/py39_cu113/_prroi_pooling/build.ninja...
Building extension module _prroi_pooling...
Allowing ninja to set a default number of workers... (overridable by setting the environment variable MAX_JOBS=N)
1.10.0
Loading extension module _prroi_pooling...
Traceback (most recent call last):
File "/home/user/Documents/Computer Vision/pytracking/pytracking/../ltr/external/PreciseRoIPooling/pytorch/prroi_pool/functional.py", line 30, in _import_prroi_pooling
_prroi_pooling = load_extension(
File "/home/user/anaconda3/envs/pytracking/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1124, in load
return _jit_compile(
File "/home/user/anaconda3/envs/pytracking/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1362, in _jit_compile
return _import_module_from_library(name, build_directory, is_python_module)
File "/home/user/anaconda3/envs/pytracking/lib/python3.9/site-packages/torch/utils/cpp_extension.py", line 1752, in _import_module_from_library
module = importlib.util.module_from_spec(spec)
File "
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/user/Documents/Computer Vision/pytracking/pytracking/run_webcam.py", line 41, in
Try it by first fixing your path which is "/home/user/Documents/Computer Vision/pytracking/pytracking/" remove the space between "Computer Vision" either by removing the space or adding an underscore. Then check
It isn't the case because path is given with "
so it understand the path.
@vahmelk99 Have you solved the problem? Which cuda and pytorch version have you installed ?
No.
CUDA Version: 11.6
conda list | grep pytorch
:
pytorch 1.10.1 py3.9_cuda11.3_cudnn8.2.0_0 pytorch
pytorch-mutex 1.0 cuda pytorch
torchaudio 0.10.1 py39_cu113 pytorch
torchvision 0.11.2 py39_cu113 pytorch
I solved this issue by creating a virtual env and installing pytorch 1.10.0 with cuda 11.1 Keep your current installation and try this in virtual env.