mirror of
https://github.com/unslothai/unsloth.git
synced 2026-07-10 00:08:58 +00:00
Update __init__.py
This commit is contained in:
parent
7f780a6370
commit
bcfb13f0fe
1 changed files with 6 additions and 2 deletions
|
|
@ -64,7 +64,10 @@ try:
|
|||
cdequantize_blockwise_fp32 = bnb.functional.lib.cdequantize_blockwise_fp32
|
||||
libcuda_dirs()
|
||||
except:
|
||||
warnings.warn("CUDA is not linked properly. We shall run `ldconfig /usr/lib64-nvidia` to try to fix it.")
|
||||
warnings.warn(
|
||||
"CUDA is not linked properly.\n"\
|
||||
"We shall run `ldconfig /usr/lib64-nvidia` to try to fix it."
|
||||
)
|
||||
os.system("ldconfig /usr/lib64-nvidia")
|
||||
importlib.reload(bnb)
|
||||
importlib.reload(triton)
|
||||
|
|
@ -74,7 +77,8 @@ except:
|
|||
cdequantize_blockwise_fp32 = bnb.functional.lib.cdequantize_blockwise_fp32
|
||||
libcuda_dirs()
|
||||
except:
|
||||
raise ImportError("CUDA is not linked properly. We tried running `ldconfig /usr/lib64-nvidia` ourselves, but it didn't work.\n"\
|
||||
raise ImportError("CUDA is not linked properly.\n"\
|
||||
"We tried running `ldconfig /usr/lib64-nvidia` ourselves, but it didn't work.\n"\
|
||||
"You need to run in your terminal `ldconfig /usr/lib64-nvidia` yourself, then import Unsloth.")
|
||||
pass
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue