Please help me with OSError: libcusparse.so.10: cannot open shared object file: No such file or directory
See original GitHub issue❓ Questions & Help
this is the traceback
`Traceback (most recent call last): File “/home/yrwang/.local/lib/python3.6/site-packages/torch_sparse/init.py”, line 15, in <module> library, [osp.dirname(file)]).origin) File “/home/yrwang/.local/lib/python3.6/site-packages/torch/_ops.py”, line 106, in load_library ctypes.CDLL(path) File “/usr/lib/python3.6/ctypes/init.py”, line 348, in init self._handle = _dlopen(self._name, mode) OSError: libcusparse.so.10: cannot open shared object file: No such file or directory
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File “<stdin>”, line 1, in <module> File “/home/yrwang/.local/lib/python3.6/site-packages/torch_geometric/init.py”, line 2, in <module> import torch_geometric.nn File “/home/yrwang/.local/lib/python3.6/site-packages/torch_geometric/nn/init.py”, line 2, in <module> from .data_parallel import DataParallel File “/home/yrwang/.local/lib/python3.6/site-packages/torch_geometric/nn/data_parallel.py”, line 5, in <module> from torch_geometric.data import Batch File “/home/yrwang/.local/lib/python3.6/site-packages/torch_geometric/data/init.py”, line 1, in <module> from .data import Data File “/home/yrwang/.local/lib/python3.6/site-packages/torch_geometric/data/data.py”, line 7, in <module> from torch_sparse import coalesce File “/home/yrwang/.local/lib/python3.6/site-packages/torch_sparse/init.py”, line 23, in <module> raise OSError(e) OSError: libcusparse.so.10: cannot open shared object file: No such file or directory `
my cuda,cudnn is well installed :
nvcc -V nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2019 NVIDIA Corporation Built on Sun_Jul_28_19:07:16_PDT_2019 Cuda compilation tools, release 10.1, V10.1.243
my torch version:
>>> print(torch.__version__) 1.4.0
I use
`pip3 install torch-scatter==2.0.4+cu101 -f https://pytorch-geometric.com/whl/torch-1.4.0.html
pip3 install torch-sparse==0.6.1+cu101 -f https://pytorch-geometric.com/whl/torch-1.4.0.html
pip3 install torch-cluster==1.5.4+cu101 -f https://pytorch-geometric.com/whl/torch-1.4.0.html
pip3 install torch-spline-conv==1.2.0+cu101 -f https://pytorch-geometric.com/whl/torch-1.4.0.html
pip3 install torch-geometric` to install torch-geometric, but the problem occur, thanks for helping me
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:39 (11 by maintainers)
Top GitHub Comments
Ubuntu 18.04 This is my procedure to fix this bug.
find -name libcus*
if you see “libcusparse.so.11”, continue following steps:
remove current cuda
sudo apt-get --purge remove "*cublas*" "cuda*" "nsight*"
sudo apt-get --purge remove "*nvidia*"
install new cuda-10-2 5.
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64/cuda-ubuntu1804.pin
6.sudo mv cuda-ubuntu1804.pin /etc/apt/preferences.d/cuda-repository-pin-600
7.wget http://developer.download.nvidia.com/compute/cuda/10.2/Prod/local_installers/cuda-repo-ubuntu1804-10-2-local-10.2.89-440.33.01_1.0-1_amd64.deb
8.sudo dpkg -i cuda-repo-ubuntu1804-10-2-local-10.2.89-440.33.01_1.0-1_amd64.deb
9.sudo apt-key add /var/cuda-repo-10-2-local-10.2.89-440.33.01/7fa2af80.pub
10.sudo apt-get update
11.sudo apt-get -y install cuda-10-2
add CUDA to PATH
I had this problem when using conda. In my conda environment I had installed pytorch and torchvision with pip, but
pip uninstall
pytorch and torchvision and then install them through conda instead solved the issue