为 spacy 构建轮子失败 [英] Failed building wheel for spacy
本文介绍了为 spacy 构建轮子失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我正在尝试通过为 python 版本 3.6.1 运行 pip install spacy
来安装 spacy,但我不断收到如下错误,如何摆脱这个问题?以前我遇到 cl.exe not found 错误,之后我在 cl.exe 存在的环境变量中添加了 Visual Studio 路径.
I'm trying to install spacy by running pip install spacy
for python version 3.6.1 but continuously i'm getting errors like below,how to get rid of this issue? previously i was having cl.exe not found error, after that i added visual studio path in environment variables where cl.exe exists.
Failed building wheel for spacy
Running setup.py clean for spacy
Running setup.py bdist_wheel for murmurhash ... error
Complete output from command c:userssh00428701appdatalocalprogramspythonpython36python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\SH0042~1\AppData\Local\Temp\pip-build-joi6voav\murmurhash\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:UsersSH0042~1AppDataLocalTemp mpa6tzdkovpip-wheel- --python-tag cp36:
running bdist_wheel
running build
running build_py
----------------------------------------
Failed building wheel for murmurhash
Running setup.py clean for murmurhash
Running setup.py bdist_wheel for cymem ... error
Complete output from command c:userssh00428701appdatalocalprogramspythonpython36python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\SH0042~1\AppData\Local\Temp\pip-build-joi6voav\cymem\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:UsersSH0042~1AppDataLocalTemp mpz7p6hkiwpip-wheel- --python-tag cp36:
----------------------------------------
Failed building wheel for cymem
Running setup.py clean for cymem
Running setup.py bdist_wheel for preshed ... error
Complete output from command c:userssh00428701appdatalocalprogramspythonpython36python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\SH0042~1\AppData\Local\Temp\pip-build-joi6voav\preshed\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d C:UsersSH0042~1AppDataLocalTemp mpwppgmyp9pip-wheel- --python-tag cp36:
----------------------------------------
Failed building wheel for preshed
Running setup.py clean for preshed
Running setup.py bdist_wheel for thinc ... error
----------------------------------------
Failed building wheel for thinc
Running setup.py clean for thinc
Running setup.py bdist_wheel for ujson ... error
----------------------------------------
Failed building wheel for ujson
Running setup.py clean for ujson
Running setup.py bdist_wheel for cytoolz ... error
----------------------------------------
Failed building wheel for cytoolz
Running setup.py clean for cytoolz
Failed to build spacy murmurhash cymem preshed thinc ujson cytoolz
Installing collected packages: murmurhash, cymem, preshed, wrapt, tqdm, toolz, cytoolz, plac, pyreadline, dill, termcolor, pathlib, thinc, ujson, regex, spacy
Running setup.py install for murmurhash ... error
C:Program Files (x86)Microsoft Visual Studio 14.0VCincl.exe /c /nologo /Ox /W3 /GL /DNDEBUG /MD -Ic:userssh00428701appdatalocalprogramspythonpython36include -IC:UsersSH0042~1AppDataLocalTemppip-build-joi6voavmurmurhashmurmurhashinclude -Ic:userssh00428701appdatalocalprogramspythonpython36include -Ic:userssh00428701appdatalocalprogramspythonpython36include /EHsc /Tpmurmurhash/mrmr.cpp /Fobuild emp.win-amd64-3.6Releasemurmurhash/mrmr.obj /Ox /EHsc
mrmr.cpp
c1xx: fatal error C1083: Cannot open source file: 'murmurhash/mrmr.cpp': No such file or directory
error: command 'C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\cl.exe' failed with exit status 2
----------------------------------------
Command "c:userssh00428701appdatalocalprogramspythonpython36python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\SH0042~1\AppData\Local\Temp\pip-build-joi6voav\murmurhash\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('
', '
');f.close();exec(compile(code, __file__, 'exec'))" install --record C:UsersSH0042~1AppDataLocalTemppip-_j1cxej1-recordinstall-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:UsersSH0042~1AppDataLocalTemppip-build-joi6voavmurmurhash
推荐答案
一些想法:
- 从 http://www.lfd 获取您需要的各种轮文件.uci.edu/~gohlke/pythonlibs/#spacy 并使用
pip install x.whl y.whl etc.
安装 - 将您的 cpp 构建工具版本升级到 2017 并再次尝试 pip
这篇关于为 spacy 构建轮子失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文