【问题标题】:Scipy intallation errorscipy安装错误
【发布时间】:2017-07-08 08:01:04
【问题描述】:

我第一次遇到这个错误:

Downloading scipy-0.19.1.tar.gz (14.1MB)
    100% |████████████████████████████████| 14.1MB 36kB/s
Building wheels for collected packages: scipy
  Running setup.py bdist_wheel for scipy ... error
  Failed building wheel for scipy
  Running setup.py clean for scipy
  Complete output from command c:\users\appdata\local\programs\python\pytho
n36-32\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\URO~1\
\AppData\\Local\\Temp\\pip-build-kk764kiy\\scipy\\setup.py';f=getattr(tokenize,
'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compi
le(code, __file__, 'exec'))" clean --all:

  `setup.py clean` is not supported, use one of the following instead:

    - `git clean -xdf` (cleans all files)
    - `git clean -Xdf` (cleans all versioned files, doesn't touch
                        files that aren't checked into the git repo)

  Add `--force` to your command to use it anyway if you must (unsupported).


 ----------------------------------------
Failed cleaning build dir for scipy
Failed to build scipy
Installing collected packages: scipy
Running setup.py install for scipy ... error

之后它会打印一堆红色代码(“在处理上述异常期间,发生了另一个 excwption:”,然后是很多文件路径),我没有在这里粘贴它,因为它有很多,可能对解决方案没用问题。我有 python 3,尝试在 cmd 中安装 scipy 时出现以下错误。

然后我尝试从http://www.lfd.uci.edu/~gohlke/pythonlibs下载。

但它返回错误:

`C:\Users\Downloads>C:\Users\AppData\Local\Programs\Python\Python36-32\ 脚本\pip install scipy-0.19.1-cp36-cp36m-win_amd64.whl

scipy-0.19.1-cp36-cp36m-win_amd64.whl 不是该平台支持的轮子。`

前两个路径是我写的(第一个是下载文件的路径,第二个是 python 脚本文件(这就是我在教程中应该做的))

谁能帮我解决这个问题?

【问题讨论】:

  • scipy 版本与您的 Python 版本不匹配。在我看来,您正在尝试使用 32 位 python 安装 64 位 scipy。请尝试使用 32 位 scipy 版本。

标签: python-3.x scipy


【解决方案1】:

你必须先从http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy 安装 numpy‑1.13.1+mkl‑cp36‑cp36m‑win_amd64.whl。这将删除任何以前安装的 numpy 并安装它的新版本。

那么你必须像以前一样安装 scipy‑0.19.1‑cp36‑cp36m‑win_amd64.whl。

注意,检查你的python版本,这里的numpy和scipy都兼容python 3.6。

【讨论】:

    猜你喜欢
    • 2015-10-01
    • 2015-10-29
    • 2017-06-18
    • 2018-08-28
    • 2018-02-12
    • 2015-07-14
    • 2023-04-06
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多