pip를 통해 Scipy를 설치할 수 없습니다
다음을 사용하여 pip를 통해 scipy를 설치할 때 :
pip install scipy
Pip가 scipy를 작성하지 못하고 다음 오류가 발생합니다.
Cleaning up...
Command /Users/administrator/dev/KaggleAux/env/bin/python2.7 -c "import setuptools, tokenize;__file__='/Users/administrator/dev/KaggleAux/env/build/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/zl/7698ng4d4nxd49q1845jd9340000gn/T/pip-eO8gua-record/install-record.txt --single-version-externally-managed --compile --install-headers /Users/administrator/dev/KaggleAux/env/bin/../include/site/python2.7 failed with error code 1 in /Users/administrator/dev/KaggleAux/env/build/scipy
Storing debug log for failure in /Users/administrator/.pip/pip.log
scipy를 성공적으로 구축하려면 어떻게해야합니까? 방금 업그레이드하고 이전에 scipy를 설치하는 데 문제가 없었기 때문에 이것은 OSX Yosemite의 새로운 문제 일 수 있습니다.
디버그 로그 :
Cleaning up...
Removing temporary dir /Users/administrator/dev/KaggleAux/env/build...
Command /Users/administrator/dev/KaggleAux/env/bin/python2.7 -c "import setuptools, tokenize;__file__='/Users/administrator/dev/KaggleAux/env/build/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/zl/7698ng4d4nxd49q1845jd9340000gn/T/pip-eO8gua-record/install-record.txt --single-version-externally-managed --compile --install-headers /Users/administrator/dev/KaggleAux/env/bin/../include/site/python2.7 failed with error code 1 in /Users/administrator/dev/KaggleAux/env/build/scipy
Exception information:
Traceback (most recent call last):
File "/Users/administrator/dev/KaggleAux/env/lib/python2.7/site-packages/pip/basecommand.py", line 122, in main
status = self.run(options, args)
File "/Users/administrator/dev/KaggleAux/env/lib/python2.7/site-packages/pip/commands/install.py", line 283, in run
requirement_set.install(install_options, global_options, root=options.root_path)
File "/Users/administrator/dev/KaggleAux/env/lib/python2.7/site-packages/pip/req.py", line 1435, in install
requirement.install(install_options, global_options, *args, **kwargs)
File "/Users/administrator/dev/KaggleAux/env/lib/python2.7/site-packages/pip/req.py", line 706, in install
cwd=self.source_dir, filter_stdout=self._filter_install, show_stdout=False)
File "/Users/administrator/dev/KaggleAux/env/lib/python2.7/site-packages/pip/util.py", line 697, in call_subprocess
% (command_desc, proc.returncode, cwd))
InstallationError: Command /Users/administrator/dev/KaggleAux/env/bin/python2.7 -c "import setuptools, tokenize;__file__='/Users/administrator/dev/KaggleAux/env/build/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/zl/7698ng4d4nxd49q1845jd9340000gn/T/pip-eO8gua-record/install-record.txt --single-version-externally-managed --compile --install-headers /Users/administrator/dev/KaggleAux/env/bin/../include/site/python2.7 failed with error code 1 in /Users/administrator/dev/KaggleAux/env/build/scipy
SciPy 팀에 문제 를 연 후 다음 과 같이 pip를 업그레이드해야한다는 것을 알았습니다.
pip install --upgrade pip
그리고이 Python 3
작품에서 :
python3 -m pip install --upgrade pip
SciPy가 제대로 설치되도록 왜? 때문에:
이전 버전의 pip에는 휠, IIRC --use-wheel을 사용하도록 지시해야합니다. 또는 핍 자체를 업그레이드하면 바퀴를 들어야합니다.
pip를 업그레이드하면 문제가 해결되지만 --use-wheel
플래그를 사용할 수도 있습니다 .
64 비트 Python 설치의 Microsoft Windows 사용자는 여기.whl
에서 64 비트 Scipy를 다운로드 한 다음 파일을 다운로드 한 폴더 로 간단히 다운로드해야 합니다.cd
.whl
pip install scipy-0.16.1-cp27-none-win_amd64.whl
우분투에서 Scipy를 설치할 때 동일한 문제가 발생합니다.
나는 명령을 사용해야했다.
$ sudo apt-get install libatlas-base-dev gfortran
$ sudo pip3 install scipy
자세한 내용은 여기를 참조하십시오. pip로 SciPy 설치
죄송합니다. OS X Yosemite에서 수행하는 방법을 모르겠습니다.
Windows 10에서는 대부분의 옵션이 작동하지 않습니다. 다음과 같이하세요:
CMD와 윈도우 10에서는 다운로드 할 수 없습니다
scipy
직접 잘 알려진 명령처럼 대부분의 사용wget
,cloning scipy github
,pip install scipy
, 등설치하려면 pythonlibs .whl 파일 로 이동 하여 사용중인
python 2.7 32 bit
경우 다운로드numpy-1.11.2rc1+mkl-cp27-cp27m-win32.whl and scipy-0.18.1-cp27-cp27m-win32.whl
하거나python 2.7 62 bit
다운로드하십시오numpy-1.11.2rc1+mkl-cp27-cp27m-win_amd64.whl and scipy-0.18.1-cp27-cp27m-win_amd64.whl
다운로드 후, 아래의 파일을 저장
python directory
, 내 경우에이었다c:\>python27
그런 다음 다음을 실행하십시오.
pip install C:\Python27\numpy-1.11.2rc1+mkl-cp27-cp27m-win32.whl
pip install C:\Python27\scipy-0.18.1-cp27-cp27m-win32.whl
노트 :
scipy
numpy
의존성이 필요 하기 때문에numpy
전에 다운로드하는 이유scipy
입니다.cp27
.whl 파일에서이 파일은 특별히 > = 3.3 을 의미python 2.7
하고cp33
의미합니다.python 3.x
몇 가지 단서에 대한 이 답변 을 찾은 후이 작업을 수행했습니다.
brew install gcc
pip install scipy
(이 단계 중 첫 번째 단계는 2011 Mac Book Air에서 96 분이 걸렸으므로 서두르지 않기를 바랍니다.)
들어 윈도우 (10)
Download whl file for the apropriate python version from http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy
put it under directory run the below command
C:\directory> pip install scipy-0.19.0rc2-cp35-cp35m-win_amd64.whl
If you are totally new to python read step by step or go directly to last step. Follow the below method to install scipy 0.18.1 on Windows 64-bit , Python 64-bit . If below command is not working then proceed further
pip install scipy
Be careful with the versions of
Python
Windows
.whl version of numpy and scipy files
First install numpy and scipy.
pip install FileName.whl
For Numpy:http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy For Scipy:http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy
Be aware of the file name (check the version number).
Ex :scipy-0.18.1-cp35-cp35m-win_amd64.whl
To check which version is supported by your pip, go to point No 2 below.
If you are using .whl file . Following errors are likely to occur .
- You are using pip version 7.1.0, however version 8.1.2 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command
- scipy-0.15.1-cp33-none-win_amd64.whl.whl is not supported wheel on this platform
For the above error: start Python and type :
import pip
print(pip.pep425tags.get_supported())
Output:
[('cp35', 'cp35m', 'win_amd64'), ('cp35', 'none', 'win_amd64'), ('py3', 'none', 'win_amd64'), ('cp35', 'none', 'any'), ('cp3', 'none', 'any'), ('py35', 'none', 'any'), ('py3', 'none', 'any'), ('py34', 'none', 'any'), ('py33', 'none', 'any'), ('py32', 'none', 'any'), ('py31', 'none', 'any'), ('py30', 'none', 'any')]
In the output you will observe cp35 is there , so download cp35 for numpy as well as scipy.Further edits are most welcome.
Rather than going the harder route of downloading specific packages. I prefer to go the faster route of using Conda. pip has its issues.
- Python -v (3.6.0)
- Windows 10 (64 bit)
Conda , install conda from : https://conda.io/docs/install/quick.html#windows-miniconda-install
command prompt
C:\Users\xyz>conda install -c anaconda scipy=0.18.1
Fetching package metadata .............
Solving package specifications:
Package plan for installation in environment C:\Users\xyz\Miniconda3:
The following NEW packages will be INSTALLED:
mkl: 2017.0.1-0 anaconda
numpy: 1.12.0-py36_0 anaconda
scipy: 0.18.1-np112py36_1 anaconda
The following packages will be SUPERCEDED by a higher-priority channel:
conda: 4.3.11-py36_0 --> 4.3.11-py36_0 anaconda
conda-env: 2.6.0-0 --> 2.6.0-0 anaconda
Proceed ([y]/n)? y
conda-env-2.6. 100% |###############################| Time: 0:00:00 32.92 kB/s
mkl-2017.0.1-0 100% |###############################| Time: 0:00:24 5.45 MB/s
numpy-1.12.0-p 100% |###############################| Time: 0:00:00 5.09 MB/s
scipy-0.18.1-n 100% |###############################| Time: 0:00:02 5.59 MB/s
conda-4.3.11-p 100% |###############################| Time: 0:00:00 4.70 MB/s
- Download SciPy from http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy
- Go into the directory the downloaded file is in and
pip install
the file. - Go to python shell, run
import scipy
; it worked for me with no errors.
This is an alternative to pip. I also had the same error when installing scipy with pip.
Then I downloaded and installed MiniConda. And then I used the below command to install pytables.
conda install -c conda-forge scipy
Please refer the below screenshot.
the best method I could suggest is this
Download the wheel file from this location for your version of python
Move the file to your Main Drive eg C:>
Run Cmd and enter the following
- pip install scipy-1.0.0rc1-cp36-none-win_amd64.whl
Please note this is the version I am using for my pyhton 3.6.2 it should install fine
you may want to run this command after to make sure all your python add ons are up to date
pip list --outdated
Alternatively, manually download and execute http://www.lfd.uci.edu/~gohlke/pythonlibs Scipy version suitable for you. Consider your Python version (python --version) and your system architecture (32/64 bit). Choose the Scipy version accordingly. scipy-0.18.1-cp27-cp27m-win32 - for Python 2.7 32 bit scipy-0.18.1-cp27-cp27m-win_amd64 - for Python 2.7 64 bit Otherwise the error scipy-0.15.1-cp33-none-win_amd64.whl.whl is not supported wheel on this platform will popup on installation.
Now change directory to the downloaded file and execute command pip install scipy-0.15.1-cp33-none-win_amd64.whl.whl
(change file name appropriately)
I have added this answer only because the Arun's answer(found useful by myself) has not mentioned anything about 32/64 bit matching which i have faced.
If you are using CentOS you need to install lapack-devel like so:
$ yum install lapack-devel
Try downloading the scipy file from the below link
https://sourceforge.net/projects/scipy/?source=typ_redirect
It will be a .exe file and you just need to run it. But be sure to chose the scipy version corresponding to your python version.
When the scipy.exe file is run it will locate the python directory and will be installed .
use the wheel file to install download from here http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy install
pip install c:\jjjj\ggg\fdadf.whl
I was having the same issue, and I had succeeded using sudo
.
$ sudo pip install scipy
The easiest way is in the following steps: Fixing scipy for python [ 2.n < python < 3.n ]
Download the necessary files from: http://www.lfd.uci.edu/~gohlke/pythonlibs/
Download the version of numpy+mkl (needed to run scipy) and then download scipy for your python type (2.n python written as 2n) or (3.n python written as 3n), n is a variable. Note you must know whether you have a 32bit or 64bit processor.
Create a directory somewhere on your computer, example [C:\DIRECTORY] to install the files numpy+mkd.whl and scipy.whl
Once both file are downloaded, find the location of the file on your computer and move it to the directory you created.
Example: First file installation is needed for scipy is in
C:\DIRECTORY\numpy\numpy-0.0.0+mkl-cp2n-cp2nm-win_amd32.whl
Example: Second file installation is in
C:\DIRECTORY\scipy\scipy-0.0.0-cp2n-cp2nm-win_amd32.whl
Go to your command prompt and proceed the following example for a python version 2.n:
py -2.n -m pip install C:\DIRECTORY\numpy\numpy-0.0.0+mkl-cp2n-cp2nm-win_amd32.whl
should install
py -2.n -m pip install C:\DIRECTORY\scipy\scipy-0.0.0-cp2n-cp2nm-win_amd32.whl
should install
Test both modules on your python IDLE as following:
import numpy
import scipy
the modules are working if no errors are returned.
IFDAAS
For windows(7 in my case):
- download scipy-0.19.1-cp36-cp36m-win32.whl from http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy
create one some.bat file with content
@echo off C:\Python36\python.exe -m pip -V C:\Python36\python.exe -m pip install scipy-0.19.1-cp36-cp36m-win32.whl C:\Python36\python.exe -m pip list pause
then run this batch file some.bat
- call python shell "C:\Python36\pythonw.exe "C:\Python36\Lib\idlelib\idle.pyw" and test if scipy was installed with
import scipy
The easy way to install scipy on Windows 10 100% is this: Just pip this ====>
pip install scipy==1.0.0rc2
Thank me later :)
I experienced similar issues with Python 3.7 (3.7.0b4). This was due to some changes regarding some encoding assumptions (Python 3.6 >> Python 3.7)
As a result lots of package installations (e.g. via pip) failed.
You can test this answer:
python -m pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose
참고URL : https://stackoverflow.com/questions/26575587/cant-install-scipy-through-pip
'Programing' 카테고리의 다른 글
ggplot2 boxplot에서 특이 값 무시 (0) | 2020.07.19 |
---|---|
이진 데이터가 포함 된 텍스트 파일을 grep하는 방법은 무엇입니까? (0) | 2020.07.19 |
불변으로 객체의 속성 제거 (0) | 2020.07.19 |
curl : (1) 프로토콜 https가 libcurl에서 지원되지 않거나 비활성화되었습니다 (0) | 2020.07.19 |
리프 서명을 확인할 수 없습니다 (0) | 2020.07.19 |