-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Closed
Labels
windowsA Windoze-specific issueA Windoze-specific issue
Description
I compiled and installed the latest code (0.1.5) in Windows 11 with Python 3.10.11 and CUDA 11.8. The compilation with cuBLAS flag and installation were successful. When importing the module via from llama_cpp import Llama
, python reported
Failed to load shared library 'C:\Users\teristam\Anaconda3\envs\textgen\Lib\site-packages\llama_cpp\llama.dll':
Could not find module 'C:\Users\teristam\Anaconda3\envs\textgen\Lib\site-packages\llama_cpp\llama.dll' (or one of its dependencies). Try using the full path with constructor syntax.
But when I change
llama-cpp-python/llama_cpp/llama_cpp.py
Line 55 in d90c9df
return ctypes.CDLL(str(_lib_path)) |
to ctypes.CDLL(str(_lib_path),winmode=0)
, the dll is able to load succesfully. It may be related to a bug in ctype in Windows:
https://stackoverflow.com/questions/59330863/cant-import-dll-module-in-python/64472088#64472088
https://bugs.python.org/issue42114
Metadata
Metadata
Assignees
Labels
windowsA Windoze-specific issueA Windoze-specific issue