pip安装scikit-image时出现报错
ERROR: Command errored out with exit status 1:
command: /usr/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-85St38/scikit-image/setup.py'"'"'; __file__='"'"'/tmp/pip-install-85St38/scikit-image/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-2bq8I8
cwd: /tmp/pip-install-85St38/scikit-image/
Complete output (39 lines):
Partial import of skimage during the build process.
Cython >= 0.23.4 not found; falling back to pre-built geometry.c
Cython >= 0.23.4 not found; falling back to pre-built transform.c
Cython >= 0.23.4 not found; falling back to pre-built interpolation.c
Cython >= 0.23.4 not found; falling back to pre-built _draw.c
Cython >= 0.23.4 not found; falling back to pre-built corner_cy.c
Cython >= 0.23.4 not found; falling back to pre-built censure_cy.c
Cython >= 0.23.4 not found; falling back to pre-built orb_cy.c
Cython >= 0.23.4 not found; falling back to pre-built brief_cy.c
Cython >= 0.23.4 not found; falling back to pre-built _texture.c
Cython >= 0.23.4 not found; falling back to pre-built _hessian_det_appx.c
Cython >= 0.23.4 not found; falling back to pre-built _hoghistogram.c
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-85St38/scikit-image/setup.py", line 154, in <module>
**extra
File "/usr/lib/python2.7/dist-packages/numpy/distutils/core.py", line 137, in setup
config = configuration()
File "/tmp/pip-install-85St38/scikit-image/setup.py", line 70, in configuration
config.add_subpackage('skimage')
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 1036, in add_subpackage
caller_level = 2)
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 1005, in get_subpackage
caller_level = caller_level + 1)
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 942, in _get_configuration_from_setup_py
config = setup_module.configuration(*args)
File "skimage/setup.py", line 14, in configuration
config.add_subpackage('feature')
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 1036, in add_subpackage
caller_level = 2)
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 1005, in get_subpackage
caller_level = caller_level + 1)
File "/usr/lib/python2.7/dist-packages/numpy/distutils/misc_util.py", line 942, in _get_configuration_from_setup_py
config = setup_module.configuration(*args)
File "skimage/feature/setup.py", line 22, in configuration
cython(['_haar.pyx'], working_path=base_path)
File "skimage/_build.py", line 42, in cython
% CYTHON_VERSION)
RuntimeError: Cython >= 0.23.4 is required to build scikit-image from git checkout
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
该报错原因是Cython未安装或版本过低
pip install Cython
即可解决