iPython笔记本不会升级,总是在0.12版本中运行 [英] iPython notebook won't upgrade, always runs in v. 0.12

查看:109
本文介绍了iPython笔记本不会升级,总是在0.12版本中运行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

自从第一次安装iPython笔记本以来,我遇到了一些问题。我已经通过pip install安装了iPython,但后来我决定安装Canopy Express来获取所有软件包和一个易于使用的软件包管理器。我正在安装最新Yosemite的MBP。

I've had some issues with iPython notebook since installing it for the first time. I already had installed iPython via pip install, but then I decided to install Canopy Express to get all the packages and a easy-to-use package manager. I am on a MBP with latest Yosemite installed.

当我运行ipython notebook时。

When I run ipython notebook via.

ipython notebook --pylab inline

$ b在终端中,笔记本电脑上的
$ b

在Chrome中启动正常。

in a terminal, notebook starts up fine in Chrome.

但是,我用

import IPython
IPython.__version__

它说0.12 - 这根本不是最新版本。并且不允许我使用 %matplotlib inline (因为魔法未添加到该版本中)

it says 0.12 -- which is not the latest version at all. And does not allow me for instance to use %matplotlib inline (as magic is not added to that version)

如果我尝试

pip install ipython --upgrade

我得到:

"Requirement already up-to-date: ipython in /usr/local/lib/python2.7/site-packages"

当我检查Canopy包管理器时,它说我有2.3.1-2。

When I check Canopy package manager, it says I have 2.3.1-2.

任何想法?

我的预感是,我可能有几个不同的python或ipython的依赖/安装,并且搞砸了。
无论如何,我可以完全删除所有内容重新开始,或快速重新安排我的依赖关系,以便他们运行。篷?

My hunch is, that I might have several different dependencies/installations of python or ipython and that mess things up.
Is there anyway I can completely remove everything and start afresh, or quickly rearrange my dependencies, such that they run via. Canopy?

PS。我第一次运行ipython笔记本时,我刚刚使用一些指南安装它,我记得它运行的是一个名为jupyter的东西?
仍然在浏览器中,但没有正常的IP [y]:Notebook徽标。这有点奇怪吗?

PS. The first time I ran ipython notebook, I had just installed it using some guide, and I remember that it ran in something called jupyter?
Still with in a browser, but not with normal IP[y]:Notebook logo. Is that strange?

编辑:

which -a ipython gives 

/Library/Frameworks/Python.framework/Versions/Current/bin/ipython
/usr/local/bin/ipython
/usr/local/bin/ipython
/usr/local/bin/ipython
/usr/local/bin/ipython

which -a python gives 

/Library/Frameworks/Python.framework/Versions/Current/bin/python
/usr/local/bin/python
/usr/local/bin/python
/usr/local/bin/python
/usr/local/bin/python
/usr/bin/python


推荐答案

我会自己回答这个问题。

I will self-answer this one.

1)删除所有非OSx相关的python,然后执行以下操作:如何在Mac OS X 10.6.4上卸载Python 2.7?

1) Removed all non-OSx related python, following this: How to uninstall Python 2.7 on a Mac OS X 10.6.4?

2)看一下.profile和.bash_profile。删除了所有过去的python依赖项(甚至有一个到Anaconda)。轻松使用打开-a TextEdit .profile

2) Had a look in both .profile and .bash_profile. Deleted all past python dependencies (even had one to Anaconda). Easy using open -a TextEdit .profile

3)重新启动

4)安装Canopy Express。这是我遇到新问题的地方,因为Canopy不会通过GUI将自己设置为默认python。通过更改.profile和.bash_profile来解决此问题。查看更多这里

4) Install Canopy Express. This is where I ran into new problems, as Canopy would not set itself as default python via the GUI. Fixed this by changing .profile and .bash_profile. See more here.

5)在终端中跑出 ipython notebook%pylab --inline 现在我已经更新了iPython!

5) Ran ipython notebook %pylab --inline in terminal, and now I have updated iPython!

这篇关于iPython笔记本不会升级,总是在0.12版本中运行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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