多版本python下选择一个安装

我的服务器上有python3.4和python2.7,今天需要对python2.7的numpy进行降级到1.11.0。

当我执行:sudo pip install -U numpy==1.11.0后,显示装到了python3.4上,因为这个是系统默认的python3.4。


所以可以执行下面命令,指定装到哪个python中:

python2.7 /usr/local/bin/pip install -U numpy==1.11.0

ok了

参考文献:

https://github.com/rbgirshick/py-faster-rcnn/issues/481

http://stackoverflow.com/questions/8964736/multiple-versions-of-python-when-installing-a-package-with-aptitude

你可能感兴趣的:(多版本python下选择一个安装)