OS X未使用最新的NumPY版本 [英] OS X not using most recent NumPY version

查看:87
本文介绍了OS X未使用最新的NumPY版本的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试通过运行pip install -U numpy来更新NumPY,这将产生需求已经是最新的:/Library/Python/2.7/site-packages中的numpy".然后使用import numpynumpy.version.version检查版本会得出"1.6.2"(旧版本). Python正在通过路径'/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy'导入numpy.请在这里帮助我.

Trying to update NumPY by running pip install -U numpy, which yields "Requirement already up-to-date: numpy in /Library/Python/2.7/site-packages". Then checking the version with import numpy and numpy.version.version yields '1.6.2' (old version). Python is importing numpy via the path '/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy'. Please help me out here.

推荐答案

新的NumPY版本将(通过pip)安装到系统路径中,而Python不会识别该版本.为了解决这个问题,我运行pip install --user numpy==1.7.1来指定我要在我的Python(用户)路径上使用NumPY版本1.7.1. :)

The new NumPY version would install (via pip) into the System path, where it wasn't being recognized by Python. To solve this I ran pip install --user numpy==1.7.1 to specify I want NumPY version 1.7.1 on my Python (user) path. :)

这篇关于OS X未使用最新的NumPY版本的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆