Skip to content

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

@xyxxmb

Description

@xyxxmb

My environment is:
linux system:centos7
cuda: 10.2
torch:1.11.0
bitsandbytes:0.34.0

Then the error is:

import bitsandbytes as bnb

===================================BUG REPORT===================================
Welcome to bitsandbytes. For bug reports, please submit your error trace to: https://github.com/TimDettmers/bitsandbytes/issues
For effortless bug reporting copy-paste your error into this form: https://docs.google.com/forms/d/e/1FAIpQLScPB8emS3Thkp66nvqwmjTEgxp8Y9ufuWTzFyr9kJ5AoI47dQ/viewform?usp=sf_link
================================================================================
/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/cuda_setup/paths.py:86: UserWarning: /xxx/anaconda3 did not contain libcudart.so as expected! Searching further paths...
  warn(
/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/cuda_setup/paths.py:20: UserWarning: WARNING: The following directories listed in your path were found to be non-existent: {PosixPath('printf "\\033]0;%s@%s'), PosixPath('%s\\007" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/~}";/etc/sysconfig/bash-prompt-history')}
  warn(
CUDA_SETUP: WARNING! libcudart.so not found in any environmental path. Searching /usr/local/cuda/lib64...
CUDA SETUP: CUDA runtime path found: /usr/local/cuda/lib64/libcudart.so
CUDA SETUP: Highest compute capability among GPUs detected: 7.0
CUDA SETUP: CUDA version lower than 11 are currenlty not supported for LLM.int8(). You will be only to use 8-bit optimizers and quantization routines!!
CUDA SETUP: Detected CUDA version 102
CUDA SETUP: Loading binary /xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/libbitsandbytes_cuda102_nocublaslt.so...
---------------------------------------------------------------------------
OSError                                   Traceback (most recent call last)
<ipython-input-1-b6686ac3a796> in <module>
----> 1 import bitsandbytes as bnb

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/__init__.py in <module>
      4 # LICENSE file in the root directory of this source tree.
      5
----> 6 from .autograd._functions import (
      7     MatmulLtState,
      8     bmm_cublas,

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/autograd/_functions.py in <module>
      3
      4 import torch
----> 5 import bitsandbytes.functional as F
      6
      7 from dataclasses import dataclass

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/functional.py in <module>
     11 from torch import Tensor
     12
---> 13 from .cextension import COMPILED_WITH_CUDA, lib
     14 from functools import reduce  # Required in Python 3
     15

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/cextension.py in <module>
     39
     40
---> 41 lib = CUDALibrary_Singleton.get_instance().lib
     42 try:
     43     lib.cadam32bit_g32

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/cextension.py in get_instance(cls)
     35         if cls._instance is None:
     36             cls._instance = cls.__new__(cls)
---> 37             cls._instance.initialize()
     38         return cls._instance
     39

~/xxx/anaconda3/lib/python3.8/site-packages/bitsandbytes/cextension.py in initialize(self)
     29         else:
     30             print(f"CUDA SETUP: Loading binary {binary_path}...")
---> 31             self.lib = ct.cdll.LoadLibrary(binary_path)
     32
     33     @classmethod

~/xxx/anaconda3/lib/python3.8/ctypes/__init__.py in LoadLibrary(self, name)
    457
    458     def LoadLibrary(self, name):
--> 459         return self._dlltype(name)
    460
    461 cdll = LibraryLoader(CDLL)

~/xxx/anaconda3/lib/python3.8/ctypes/__init__.py in __init__(self, name, mode, handle, use_errno, use_last_error, winmode)
    379
    380         if handle is None:
--> 381             self._handle = _dlopen(self._name, mode)
    382         else:
    383             self._handle = handle

OSError: libcublas.so.11: cannot open shared object file: No such file or directory

I can not update the cuda version into 11.x. How should I solve the issue?

Metadata

Metadata

Assignees

No one assigned

    Labels

    EnhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions