snap-stanford / ogb

Benchmark datasets, data loaders, and evaluators for graph machine learning
https://ogb.stanford.edu
MIT License
1.89k stars 397 forks source link

Python3.9: OSError: libcublas.so.11: cannot open shared object file: No such file or directory #402

Open colossusb opened 1 year ago

colossusb commented 1 year ago

Aware, of course, that you don't yet officially support Python3.9, but thought this might be useful for someone who needs to use it:

Had this error when trying to install the module on Python3.9:

/python3.9/site-packages/torch/__init__.py", line 153, in _load_global_deps
     ctypes.CDLL(lib_path, mode=ctypes.RTLD_GLOBAL)
   File "/usr/lib64/python3.9/ctypes/__init__.py", line 374, in __init__
     self._handle = _dlopen(self._name, mode)
 OSError: libcublas.so.11: cannot open shared object file: No such file or directory

Worked around the error by updating the torch version in our model's requirements.txt to include a different cuda version (when running on Python3.9 or greater) thus:

# Workaround for OGB issue on Python3.9
--find-links https://download.pytorch.org/whl/torch_stable.html
torch==1.13.0+cu116; python_version >= '3.9'