conda使用新版本numpy创建环境

时间:2018-01-22 06:55:41

标签: conda

我是python和conda的新手。我在mac上使用默认版本的python(2.7.14),我想使用已安装的pandas 0.22(使用conda);为此,我也用conda安装了numpy 1.14,但当我尝试运行导入pandas(导入pandas)的脚本时,它只是说:

ImportError: this version of pandas is incompatible with numpy < 1.9.0
your numpy version is 1.8.0rc1.
Please upgrade numpy to >= 1.9.0 to use this pandas version

我认为python正在调用python 2.7附带的默认numpy版本(在:/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python /)。

我的问题是,如果我用conda为这个模块创建一个环境,我的意思是这样的:

conda create --name numpy1.14 anaconda=4.4.7 numpy=1.14.0 python=2.7

export PATH=~/anaconda/envs/numpy1.14/bin:$PATH
当pthon从任何给定的脚本运行时,或者当我导入pandas时,它将调用numpy 1.14.0 ???它将导入新版本(1.14.0)或旧版本???它是在mac ????中运行默认版本的python的脚本中导入任何模块的特定版本的任何方式

谢谢

0 个答案:

没有答案