找回密码
 会员注册
查看: 34|回复: 0

Couldnotbuildwheelsforllama-cpp-python,whichisrequiredtoinstallpyproject.toml-basedproj

[复制链接]

2万

主题

0

回帖

6万

积分

超级版主

积分
64454
发表于 2024-9-3 12:32:58 | 显示全部楼层 |阅读模式
安装llama-cpp-python包时,出现下述问题:Collectingllama-cpp-pythonUsingcachedllama_cpp_python-0.2.28.tar.gz(9.4MB)Installingbuilddependencies...doneGettingrequirementstobuildwheel...doneInstallingbackenddependencies...donePreparingmetadata(pyproject.toml)...doneRequirementalreadysatisfied:typing-extensions>=4.5.0ind:\software\anaconda3\lib\site-packages(fromllama-cpp-python)(4.8.0)Collectingdiskcache>=5.6.1Usingcacheddiskcache-5.6.3-py3-none-any.whl(45kB)Requirementalreadysatisfied:numpy>=1.20.0ind:\software\anaconda3\lib\site-packages(fromllama-cpp-python)(1.23.5)Buildingwheelsforcollectedpackages:llama-cpp-pythonBuildingwheelforllama-cpp-python(pyproject.toml)...errorerror:subprocess-exited-with-error×Buildingwheelforllama-cpp-python(pyproject.toml)didnotrunsuccessfully.│exitcode:1╰─>[20linesofoutput]***scikit-build-core0.7.1usingCMake3.28.1(wheel)***ConfiguringCMake...2024-01-1502:55:12,546-scikit_build_core-WARNING-Can'tfindaPythonlibrary,gotlibdir=None,ldlibrary=None,multiarch=None,masd=NoneloadinginitialcachefileC:\Windows\TEMP\tmpyjbtivnu\build\CMakeInit.txt--Buildingfor:NMakeMakefilesCMakeErroratCMakeLists.txt:3(project):Running'nmake''-?'failedwith:nosuchfileordirectoryCMakeError:CMAKE_C_COMPILERnotset,afterEnableLanguageCMakeError:CMAKE_CXX_COMPILERnotset,afterEnableLanguage--Configuringincomplete,errorsoccurred!***CMakeconfigurationfailed[endofoutput]note:Thiserrororiginatesfromasubprocess,andislikelynotaproblemwithpip.ERROR:Failedbuildingwheelforllama-cpp-pythonFailedtobuildllama-cpp-pythonERROR:Couldnotbuildwheelsforllama-cpp-python,whichisrequiredtoinstallpyproject.toml-basedprojects12345678910111213141516171819202122232425262728293031323334353637383940414243根据下面的链接https://github.com/abetlen/llama-cpp-python/issues/54BuildingwindowswheelsforPython3.10requiresMicrosoftVisualStudio2022.1所以需要新装个VisualStudio2022+C++buildingtool再重装去官网下载必须勾选C++桌面开发(10G+),我只改了IDE(4G+)的路径。安装好之后,再次输入,即可安装成功pipinstallllama-cpp-python1WARNING:Retrying(Retry(total=4,connect=None,read=None,redirect=None,status=None))afterconnectionbrokenby'SSLError(SSLEOFError(8,'EOFoccurredinviolationofprotocol(_ssl.c:997)'))':/simple/llama-cpp-python/Collectingllama-cpp-pythonUsingcachedllama_cpp_python-0.2.28.tar.gz(9.4MB)Installingbuilddependencies...doneGettingrequirementstobuildwheel...doneInstallingbackenddependencies...donePreparingmetadata(pyproject.toml)...doneCollectingdiskcache>=5.6.1Usingcacheddiskcache-5.6.3-py3-none-any.whl(45kB)Requirementalreadysatisfied:numpy>=1.20.0ind:\software\anaconda3\lib\site-packages(fromllama-cpp-python)(1.23.5)Requirementalreadysatisfied:typing-extensions>=4.5.0ind:\software\anaconda3\lib\site-packages(fromllama-cpp-python)(4.8.0)Buildingwheelsforcollectedpackages:llama-cpp-pythonBuildingwheelforllama-cpp-python(pyproject.toml)...doneCreatedwheelforllama-cpp-python:filename=llama_cpp_python-0.2.28-cp310-cp310-win_amd64.whlsize=1906661sha256=da0b3f2650793d7d67bdc9355c28c3c8d9ad630a2aa5c8a480f3afa21bcdd31aStoredindirectory:c:\users\dell\appdata\local\pip\cache\wheels\74\a0\5c\281bde8a2e00a36b941882b1723e70eb7ac0f773a5c50f4132Successfullybuiltllama-cpp-pythonInstallingcollectedpackages:diskcache,llama-cpp-pythonSuccessfullyinstalleddiskcache-5.6.3llama-cpp-python-0.2.28123456789101112131415161718参考:https://ceshiren.com/t/topic/27526/7
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 会员注册

本版积分规则

QQ|手机版|心飞设计-版权所有:微度网络信息技术服务中心 ( 鲁ICP备17032091号-12 )|网站地图

GMT+8, 2024-12-27 13:28 , Processed in 0.746002 second(s), 26 queries .

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表