我试图在Windows上使用pip在python2.7上安装一些特定的软件包,并在尝试安装scipy 0.16.1时出现以下错误:
(env) C:\Users\Asus\Documents\LEI\Algo-Rhythm>pip install --no-use-wheel scipy==0.16.1
DEPRECATION: --no-use-wheel is deprecated and will be removed in the future. Please use --no-binary :all: instead.
Collecting scipy==0.16.1
Using cached scipy-0.16.1.tar.gz
Skipping bdist_wheel for scipy, due to binaries being disabled for it.
Installing collected packages: scipy
Running setup.py install for scipy ... error
Complete output from command c:\users\asus\documents\lei\algo-rhythm\env\scripts\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\asus\\appdata\\local\\temp\\pip-build-itlx8i\\scipy\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record c:\users\asus\appdata\local\temp\pip-uzs8w6-record\install-record.txt --single-version-externally-managed --compile --install-headers c:\users\asus\documents\lei\algo-rhythm\env\include\site\python2.7\scipy:
lapack_opt_info:
openblas_lapack_info:
libraries openblas not found in ['c:\\users\\asus\\documents\\lei\\algo-rhythm\\env\\lib', 'C:\\']
NOT AVAILABLE
lapack_mkl_info:
mkl_info:
libraries mkl,vml,guide not found in ['c:\\users\\asus\\documents\\lei\\algo-rhythm\\env\\lib', 'C:\\']
NOT AVAILABLE
NOT AVAILABLE
atlas_3_10_threads_info:
Setting PTATLAS=ATLAS
c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\system_info.py:635: UserWarning: Specified path C:\projects\np-wheel-builder\atlas-builds\atlas-3.11.38-sse2-64\lib is invalid.
warnings.warn('Specified path %s is invalid.' % d)
<class 'numpy.distutils.system_info.atlas_3_10_threads_info'>
NOT AVAILABLE
atlas_3_10_info:
<class 'numpy.distutils.system_info.atlas_3_10_info'>
NOT AVAILABLE
atlas_threads_info:
Setting PTATLAS=ATLAS
<class 'numpy.distutils.system_info.atlas_threads_info'>
NOT AVAILABLE
atlas_info:
<class 'numpy.distutils.system_info.atlas_info'>
NOT AVAILABLE
c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\system_info.py:1552: UserWarning:
Atlas (http://math-atlas.sourceforge.net/) libraries not found.
Directories to search for the libraries can be specified in the
numpy/distutils/site.cfg file (section [atlas]) or by setting
the ATLAS environment variable.
warnings.warn(AtlasNotFoundError.__doc__)
lapack_info:
libraries lapack not found in ['c:\\users\\asus\\documents\\lei\\algo-rhythm\\env\\lib', 'C:\\']
NOT AVAILABLE
c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\system_info.py:1563: UserWarning:
Lapack (http://www.netlib.org/lapack/) libraries not found.
Directories to search for the libraries can be specified in the
numpy/distutils/site.cfg file (section [lapack]) or by setting
the LAPACK environment variable.
warnings.warn(LapackNotFoundError.__doc__)
lapack_src_info:
NOT AVAILABLE
c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\system_info.py:1566: UserWarning:
Lapack (http://www.netlib.org/lapack/) sources not found.
Directories to search for the sources can be specified in the
numpy/distutils/site.cfg file (section [lapack_src]) or by setting
the LAPACK_SRC environment variable.
warnings.warn(LapackSrcNotFoundError.__doc__)
NOT AVAILABLE
Running from scipy source directory.
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\users\asus\appdata\local\temp\pip-build-itlx8i\scipy\setup.py", line 253, in <module>
setup_package()
File "c:\users\asus\appdata\local\temp\pip-build-itlx8i\scipy\setup.py", line 250, in setup_package
setup(**metadata)
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\core.py", line 135, in setup
config = configuration()
File "c:\users\asus\appdata\local\temp\pip-build-itlx8i\scipy\setup.py", line 175, in configuration
config.add_subpackage('scipy')
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 1002, in add_subpackage
caller_level = 2)
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 971, in get_subpackage
caller_level = caller_level + 1)
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 908, in _get_configuration_from_setup_py
config = setup_module.configuration(*args)
File "scipy\setup.py", line 15, in configuration
config.add_subpackage('linalg')
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 1002, in add_subpackage
caller_level = 2)
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 971, in get_subpackage
caller_level = caller_level + 1)
File "c:\users\asus\documents\lei\algo-rhythm\env\lib\site-packages\numpy\distutils\misc_util.py", line 908, in _get_configuration_from_setup_py
config = setup_module.configuration(*args)
File "scipy\linalg\setup.py", line 20, in configuration
raise NotFoundError('no lapack/blas resources found')
numpy.distutils.system_info.NotFoundError: no lapack/blas resources found
----------------------------------------
Command "c:\users\asus\documents\lei\algo-rhythm\env\scripts\python.exe -u -c "import setuptools, tokenize;__file__='c:\\users\\asus\\appdata\\local\\temp\\pip-build-itlx8i\\scipy\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record c:\users\asus\appdata\local\temp\pip-uzs8w6-record\install-record.txt --single-version-externally-managed --compile --install-headers c:\users\asus\documents\lei\algo-rhythm\env\include\site\python2.7\scipy" failed with error code 1 in c:\users\asus\appdata\local\temp\pip-build-itlx8i\scipy\
我想我错过了一些软件包,但我很难理解这个错误。我使用了不使用轮选项,因为它很容易制造轮子。提前谢谢。
答案 0 :(得分:1)
在Windows上,您必须从源代码构建Scipy。
在Windows上获取Scipy的最简单方法是使用anaconda包管理器。它将自动安装Scipy及其所有依赖项。