Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

IPython Notebooks Unreadable

So I just installed IPython for the first time (Windows 7 64 bit). Followed the instructions here:

IPython Installation

Downloaded and installed Anaconda 1.9.1 then gave the commands

conda update conda
conda update ipython

(running the command line terminal as an Administrator)

Installation completed OK and I tried to open an example .ipynb notebook file from here;

Example IPython Notebook File

but I get the following error;

Error loading notebook
Unreadable Notebook: Notebook does not appear to be JSON: '\n\n

I've tried a number of other example notebooks from the IPython Example Notebooks and all fail to open and give the same error!

Anybody know what is wrong here and how to fix it?

like image 582
GoFaster Avatar asked Mar 03 '14 19:03

GoFaster


People also ask

What is the difference between Jupyter Notebook and IPython notebook?

The IPython Notebook is now known as the Jupyter Notebook. It is an interactive computational environment, in which you can combine code execution, rich text, mathematics, plots and rich media. For more details on the Jupyter Notebook, please see the Jupyter website.

Why is Jupyter Notebook unresponsive?

Jupyter doesn't load or doesn't work in the browserTry disabling any browser extensions and/or any Jupyter extensions you have installed. Some internet security software can interfere with Jupyter. If you have security software, try turning it off temporarily, and look in the settings for a more long-term solution.

How do I read Aipynb file?

How to open an IPYNB file. You can open an IPYNB file in Jupyter Notebook (cross-platform), Jupyter Notebook Viewer (Web), Cantor (Linux), or Google Colaboratory (Web). To open an IPYNB file in Jupyter Notebook Viewer, the file must be hosted online (via GitHub or another file hosting service).


1 Answers

Based on the comment:

Visited IPython Examples Using Chrome, right click on the notebook of interest, click 'Save link as...' and the .ipynb file appears in the IPython Notebook folder. Think I'm doing it right?

It's clear that you're downloading the whole webpage, not the notebooks. Following that procedure and opening the resulting file in a text editor, I get something like this:

<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title></title>

    <meta name="viewport" content="width=device-width, initial-scale=1.0">


    <meta name="description" content="">



    <meta name="author" content="">


    <!--NEW RELIC Start Perf Measurement-->

    <!--NREND-->

    <!-- Le styles -->
    <!--<link href="/static/css/bootstrap.css" rel="stylesheet">-->
    ...

What you need to do is follow each link to it's nbviewer rendering, and click the download link.

enter image description here

Alternatively, I would just download or clone the repository from github, change to the resulting directory, and start the notebook server there.

like image 112
Paul H Avatar answered Oct 26 '22 19:10

Paul H