Ich habe gerade IPython
3.0 mit pip
auf meinem Laptop installiert, auf dem Ubuntu
14.04 ausgeführt wird:
$ pip search ipython
ipython-cluster-helper - Simplify IPython cluster start up and use for
multiple schedulers.
ipython - IPython: Productive Interactive Computing
INSTALLED: 3.0.0 (latest)
Wenn ich jedoch IPython
verwende, scheint das Terminal zu glauben, dass es Version 1.2.1 verwendet:
$ ipython
Python 2.7.6 (default, Mar 22 2014, 22:59:38)
Type "copyright", "credits" or "license" for more information.
IPython 1.2.1 -- An enhanced Interactive Python.
? -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help -> Python's own help system.
object? -> Details about 'object', use 'object??' for extra details.
In [1]
Schlimmer ist, wenn ich ein Notebook in JSON nbformat Version 4 öffne, das IPython
3.0 unterstützt, erhalte ich die folgende Fehlermeldung:
Unreadable Notebook: Unsupported JSON nbformat version 4 (supported version: 3)
Ich habe versucht, das Notebook auf Version 3 mit dem von IPython
empfohlenen Befehl herunterzurüsten. Dies schlägt jedoch auch für mich fehl:
$ ipython nbconvert --to notebook --nbformat 3 1-intro-to-brian-neurons.ipynb
. . .
[NbConvertApp] CRITICAL | Bad config encountered during initialization:
[NbConvertApp] CRITICAL | Unrecognized flag: '--nbformat'
Was ist denn hier los?
Eine ältere Version von IPython
wurde zuvor mit apt-get
installiert. Entfernen Sie die ältere Version mit apt-get remove ipython
.
jupyter nbconvert --to notebook --nbformat=3 <file.ipynb>
arbeitete für mich. Mein lokaler anaconda2 unterstützt Version 4, ipython des Dockers kann jedoch nicht.