问题描述
我终于能够在Windows 7 PC上安装ipython,它运行时没有任何错误.问题是我曾经在ipython中但是在MAC中编码.现在,我尝试上传以前的笔记本时,出现以下错误:
I finally was able to install ipython on my Windows 7 PC and it runs without any errors. The problem is that I used to code in ipython but in MAC. Now that I am trying to upload my previous notebooks I receive the following error:
Unreadable Notebook: MyFile.ipynb Unsupported nbformat version 4
对于我的问题,我找到了此答案,但不幸的是,该答案不适用于Windows,并且无法解决我的问题.值得一提:
I found this answer for my question but unfortunately that is not for windows and did not resolve my problem. It is worth to mention:
ipython --version
产生:2.3.1
对此有任何帮助或评论,我们将不胜感激.
Any help or comment on this is much appreciated.
谢谢
推荐答案
我花了一些时间才弄清楚这一点,但我从用户"cel"获得了第一笔线索.我曾经有多个版本的python(2.7和3.4).我删除了python 3.4,因为它与spark不兼容.接下来,我必须删除WinPython3.4并将其替换为WinPython2.7,以便它可以与安装在我的PC上的python 2.7集成.最后,我安装了python 2.7.9,并将 C:/Python27/Script
设置为系统环境变量的一部分.完成所有这些操作后,我运行了以下命令:
It took me a while to figure this out but I got the first lead from user "cel". I used to have multiple versions of python (2.7 and 3.4). I removed python 3.4 because it's not compatible with spark yet. Next, I had to remove WinPython3.4 and replace it with WinPython2.7 so it can integrate with python 2.7 installed on my PC. Finally, I installed python 2.7.9 and set the C:/Python27/Script
as a part of system environment variable. After doing all this I ran the following commands:
pip uninstall ipython
这帮助我删除了旧版本的ipython.然后:
This helped me to remove older version of ipython. Then:
pip install ipython
这在Windows pc上安装了最新版本的ipython.最后:
This installed the latest version of ipython on my windows pc. Finally:
pip install notebook --upgrade
将笔记本升级到最新版本.现在,已经安装了ipython os,并且应该可以正常运行:
To upgrade notebook to latest version. Right now, ipython os installed and and should work fine doing this:
ipython notebook
在上述所有操作之后导入我以前的.ipynb都没有问题.
Had no problem importing my previous .ipynb after all of the above.
祝大家好运.
这篇关于无法读取的笔记本-Windows上不支持的nbformat版本4的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!