2017-01-15 5 views
0

scipyをインストールする必要があります。しかし、コンパイル時間の約5-7minutes後、私はUbuntuの14.04.3 LTSにfollwingエラーを取得しています:pip3インストール時のコンパイルエラーscipy

sudo pip3 install scipy 
... 
error: Command "x86_64-linux-gnu-g++ -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -fPIC -D__STDC_FORMAT_MACROS=1 -Iscipy/sparse/sparsetools -I/usr/local/lib/python3.4/dist-packages/numpy/core/include -I/usr/include/python3.4m -c scipy/sparse/sparsetools/csc.cxx -o build/temp.linux-x86_64-3.4/scipy/sparse/sparsetools/csc.o" failed with exit status 4 

In file included from /usr/local/lib/python3.4/dist-packages/numpy/core/include/numpy/ndarraytypes.h:1777:0, 

       from /usr/local/lib/python3.4/dist-packages/numpy/core/include/numpy/ndarrayobject.h:18, 

       from scipy/sparse/sparsetools/sparsetools.h:5, 

       from scipy/sparse/sparsetools/csc.cxx:4: 

/usr/local/lib/python3.4/dist-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: #warning "Using deprecated NumPy API, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-Wcpp] 

#warning "Using deprecated NumPy API, disable it by " \ 

^

x86_64-linux-gnu-g++: internal compiler error: Killed (program cc1plus) 

Please submit a full bug report, 

with preprocessed source if appropriate. 

See <file:///usr/share/doc/gcc-4.8/README.Bugs> for instructions. 

---------------------------------------- 
Cleaning up... 
Command /usr/bin/python3 -c "import setuptools, tokenize;__file__='/tmp/pip_build_root/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-e3q7ek8f-record/install-record.txt --single-version-externally-managed --compile failed with error code 1 in /tmp/pip_build_root/scipy 
Storing debug log for failure in /home/ubuntu/.pip/pip.log 

は、誰もがどのようにこの問題を解決するアイデアを持っていますか?

+0

に私のために働かせたあなたがnumpyのがすでにインストールされているのですか? – Maaaaa

+0

はい、numpyがインストールされています – toom

+0

pip3をインストールしてください-U numpyを実行してpip3をインストールしてからscipyをインストールしてください – Maaaaa

答えて

1

numpyパッケージはPythonライブラリのdist-packagesディレクトリにあるので、distroパッケージマネージャを使用してnumpyがインストールされている(つまり、apt-get install python3-numpyを実行している)ようです。なぜこの方法でscipyをインストールしないのですか?あなたがpipを使用する場合は、このような競合を避けるようにするにはちょうど私が(より良いか、virtualenvwrappervirtualenvインスタンスでパッケージをインストールしましょう、

sudo apt-get install python3-scipy

を実行することができます。それ以外の場合は、ユーザがインストールしたものではなく、システム全体のバージョンを使用している必要があります(出力はあなたのパイプがユーザubuntuに属していると言います)ので、最初にapt-getを使用してインストールしてから、 。 setuptoolsをインストール

+0

いいえ、私はnumpyをインストールするpip3を使いました – toom

+0

あなたは両方のために同じpipを使用していますか? – kiliantics

0

は、それがUbuntuの14.04

関連する問題