scikit-image 无法安装



我正在尝试在装有python 7的Windows 64位计算机上安装scikit-image软件包3.5。安装 scikit 时,满足以下要求:

Requirement already satisfied: six>=1.7.3 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from scikit-image)
Requirement already satisfied: networkx>=1.8 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from scikit-image)
Requirement already satisfied: pillow>=2.1.0 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from scikit-image)
Requirement already satisfied: PyWavelets>=0.4.0 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from scikit-image)
Requirement already satisfied: decorator>=4.1.0 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from networkx>=1.8->scikit-image)
Requirement already satisfied: numpy>=1.9.1 in c:usersxappdatalocalprogramspythonpython35libsite-packages (from PyWavelets>=0.4.0->scikit-image)

但最终,安装失败并显示:

UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 114: character maps to <undefined>
    ----------------------------------------
  Failed building wheel for scikit-image
Command "C:UsersXAppDataLocalProgramsPythonPython35python.exe -u -c "import setuptools, tokenize;__file__='C:\Users\X\AppData\Local\Temp\pycharm-packaging\scikit-image\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('rn', 'n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:UsersXAppDataLocalTemppip-3hy8fcuv-recordinstall-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:UsersXAppDataLocalTemppycharm-packagingscikit-image

我已经尝试过:

pip install -U wheel
pip install -U setuptools
pip install -U scipy

并且还升级点子本身,没有任何效果。

实际的解决方案是在安装命令之前键入chcp 65001。这会将控制台的默认字符编码更改为 UTF-8,然后它起作用了。

我知道

现在有点晚了(r(,但我只是遇到了完全相同的问题。我的解决方案是从这里安装轮子。

TBH,我不知道他们做什么不同,他们为什么工作以及他们是谁。

在那里下载正确的版本。 例如,对于python 3.5,您希望版本包含35。目前,这是scikit_image‑0.13.1‑cp35‑cp35m‑win32.whl的,正下方是64位版本。

通过运行 pip install C:usersyoudownloadsthe_wheel_you_downloaded 来安装它。

最新更新