Python3上的Scipy安装

Python3上的Scipy安装,python,linux,numpy,scipy,Python,Linux,Numpy,Scipy,我正在运行Linux Ubuntu 16.04 LTS。我安装pip是为了加载Python的第三方软件包。我的Linux发行版附带了Python 2.7和3.5.2,但我后来安装了3.6。现在我正在尝试安装Scipy。按照Scipy.org上的Scipy堆栈安装说明,我在终端中运行了以下命令(在上次pip安装之后): pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose 问题是,这只安装Pytho

我正在运行Linux Ubuntu 16.04 LTS。我安装pip是为了加载Python的第三方软件包。我的Linux发行版附带了Python 2.7和3.5.2,但我后来安装了3.6。现在我正在尝试安装Scipy。按照Scipy.org上的Scipy堆栈安装说明,我在终端中运行了以下命令(在上次pip安装之后):

pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose

问题是,这只安装Python2.7的软件包,而不是3.5.2或3.6。如何让安装在Python3.x上运行?非常感谢您的指导。我的头发已经变白了,我似乎无法通过谷歌搜索得到正确的结果。

我可以推荐Anaconda吗

Anaconda(又称Conda)是一款支持Windows、Mac和Linux的跨平台软件包管理器。它旨在解决与其他软件包管理器(例如easy install、pip、distutils)的问题

康达解决了许多包装问题。安装Conda后,您可以安装所需的软件包,而不用担心它们会失败。您还可以创建“虚拟环境”。你想让Python2和Python3在同一个系统上吗?完成了

conda create -n Python2 python=2.7.13
conda create -n Python3 python=3.6.0
要切换到一个,请键入:

activate Python2
现在您处于Python2环境中

您可以随意调用环境

这是一段非常有用的20分钟视频,来自Continuum的Aaron Meurer在SciPy 2014上介绍了Conda。()我看了这个视频,它永远改变了我的生活(关于Python环境和打包)

使用Conda,要创建SciPy2和SciPy3环境:

>conda search scipy
Fetching package metadata ...........
scipy                        0.11.0               np17py27_1  defaults
                             0.11.0               np16py27_1  defaults
                             0.11.0               np17py26_1  defaults
                             0.11.0               np16py26_1  defaults
                             0.12.0               np17py26_0  defaults
                             0.12.0               np17py33_0  defaults
                             0.12.0               np17py27_0  defaults
                             0.12.0              np16py27_p0  defaults        [mkl]
                             0.12.0              np17py27_p0  defaults        [mkl]
                                        << Truncated >>
                             0.18.0              np111py34_0  defaults
                             0.18.0              np111py35_0  defaults
                             0.18.0              np111py27_0  defaults
                             0.18.1              np111py35_0  defaults
                             0.18.1              np111py27_0  defaults
                             0.18.1              np111py36_0  defaults
                             0.18.1              np111py34_0  defaults
                             0.18.1              np112py27_1  defaults
                             0.18.1              np111py34_1  defaults
                             0.18.1              np112py36_1  defaults
                             0.18.1              np111py36_1  defaults
                             0.18.1              np112py35_1  defaults
                          *  0.18.1              np111py27_1  defaults
                             0.18.1              np111py35_1  defaults

>conda search python
Fetching package metadata ...........
python                       2.6.8                         5  defaults
                             2.6.8                         6  defaults
                             2.6.9                         0  defaults
                             2.6.9                         1  defaults
                             2.7.3                         2  defaults
                                        << Truncated >>
                             2.7.10                        0  defaults
                             2.7.10                        1  defaults
                             2.7.10                        3  defaults
                             2.7.10                        4  defaults
                             2.7.10                        5  defaults
                             2.7.11                        0  defaults
                             2.7.11                        1  defaults
                             2.7.11                        2  defaults
                             2.7.11                        4  defaults
                             2.7.11                        5  defaults
                             2.7.12                        0  defaults
                          *  2.7.13                        0  defaults
                             3.3.0                         4  defaults
                             3.3.1                         0  defaults
                             3.3.2                         0  defaults
                             3.3.3                         0  defaults
                             3.3.4                         0  defaults
                             3.3.5                         0  defaults
                                        << Truncated >>
                             3.5.1                         0  defaults
                             3.5.1                         1  defaults
                             3.5.1                         2  defaults
                             3.5.1                         4  defaults
                             3.5.1                         5  defaults
                             3.5.2                         0  defaults
                             3.6.0                         0  defaults

>conda create -n SciPy2 python=2.7.13 scipy=0.18.1
Fetching package metadata ...........
Solving package specifications: .

Package plan for installation in environment D:\Applications\Anaconda\envs\SciPy2:

The following NEW packages will be INSTALLED:

    mkl:            2017.0.1-0
    numpy:          1.12.0-py27_0
    pip:            9.0.1-py27_1
    python:         2.7.13-0
    scipy:          0.18.1-np112py27_1
    setuptools:     27.2.0-py27_1
    vs2008_runtime: 9.00.30729.5054-0
    wheel:          0.29.0-py27_0

Proceed ([y]/n)? y

numpy-1.12.0-p 100% |###############################| Time: 0:00:00  10.88 MB/s
scipy-0.18.1-n 100% |###############################| Time: 0:00:00  13.49 MB/s
#
# To activate this environment, use:
# > activate SciPy2
#
# To deactivate this environment, use:
# > deactivate SciPy2
#
# * for power-users using bash, you must source
#


>conda create -n SciPy3 python=3.6.0 scipy=0.18.1
Fetching package metadata ...........
Solving package specifications: .

Package plan for installation in environment D:\Applications\Anaconda\envs\SciPy3:

The following NEW packages will be INSTALLED:

    mkl:            2017.0.1-0
    numpy:          1.12.0-py36_0
    pip:            9.0.1-py36_1
    python:         3.6.0-0
    scipy:          0.18.1-np112py36_1
    setuptools:     27.2.0-py36_1
    vs2015_runtime: 14.0.25123-0
    wheel:          0.29.0-py36_0

Proceed ([y]/n)? y

vs2015_runtime 100% |###############################| Time: 0:00:00   9.96 MB/s
python-3.6.0-0 100% |###############################| Time: 0:00:02  12.86 MB/s
numpy-1.12.0-p 100% |###############################| Time: 0:00:00  13.61 MB/s
setuptools-27. 100% |###############################| Time: 0:00:00  13.15 MB/s
wheel-0.29.0-p 100% |###############################| Time: 0:00:00  18.89 MB/s
pip-9.0.1-py36 100% |###############################| Time: 0:00:00  11.73 MB/s
scipy-0.18.1-n 100% |###############################| Time: 0:00:00  12.76 MB/s
#
# To activate this environment, use:
# > activate SciPy3
#
# To deactivate this environment, use:
# > deactivate SciPy3
#
# * for power-users using bash, you must source
#


>activate SciPy3

(SciPy3) >
>康达搜索引擎
正在获取包元数据。。。。。。。。。。。
scipy 0.11.0 np17py27_1默认值
0.11.0 np16py27_1默认值
0.11.0 np17py26_1默认值
0.11.0 np16py26_1默认值
0.12.0 np17py26_0默认值
0.12.0 np17py33_0默认值
0.12.0 np17py27_0默认值
0.12.0 np16py27_p0默认值[mkl]
0.12.0 np17py27_p0默认值[mkl]
>
0.18.0 np111py34_0默认值
0.18.0 np111py35_0默认值
0.18.0 np111py27_0默认值
0.18.1 np111py35_0默认值
0.18.1 np111py27_0默认值
0.18.1 np111py36_0默认值
0.18.1 np111py34_0默认值
0.18.1 np112py27_1默认值
0.18.1 np111py34_1默认值
0.18.1 np112py36_1默认值
0.18.1 np111py36_1默认值
0.18.1 np112py35_1默认值
*0.18.1 np111py27_1默认值
0.18.1 np111py35_1默认值
>康达搜索python
正在获取包元数据。。。。。。。。。。。
python 2.6.8.5默认值
2.6.8.6违约
2.6.9.0默认值
2.6.9.1违约
2.7.3.2违约
>
2.7.10默认值
2.7.10.1违约
2.7.10.3违约
2.7.10.4违约
2.7.10.5违约
2.7.11.0默认值
2.7.11.1违约
2.7.11.2违约
2.7.11.4违约
2.7.11.5违约
2.7.12 0默认值
*2.7.13 0默认值
3.3.0 4默认值
3.3.1.0默认值
3.3.2 0默认值
3.3.3.0默认值
3.3.4.0默认值
3.3.5 0默认值
>
3.5.1.0默认值
3.5.1 1违约
3.5.1.2违约
3.5.1.4违约
3.5.1.5违约
3.5.2.0默认值
3.6.0默认值
>conda create-n SciPy2 python=2.7.13 scipy=0.18.1
正在获取包元数据。。。。。。。。。。。
正在解决程序包规范:。
环境D:\Applications\Anaconda\envs\SciPy2中安装的程序包计划:
将安装以下新软件包:
mkl:2017.0.1-0
numpy:1.12.0-py27_0
pip:9.0.1-py27_1
python:2.7.13-0
sc
python3.x Hello.py
python2.x Hello.py
python Hello.py