Как скачать ipynb с github
Перейти к содержимому

Как скачать ipynb с github

  • автор:

Как сохранить записные книжки Jupyter с GitHub

Когда я загружаю файл ipynb с помощью кнопки RAW в GitHub, он отображает текст (json) в браузере.

Может мне просто скопировать этот текст в файл и назвать его xxx.ipynb ? Как лучше всего это сделать?

2 ответа

  1. Сначала нажмите Raw
  2. Затем нажмите ctrl + s, чтобы сохранить его как .ipynb (обратите внимание, что вам придется вручную ввести .ipynb после имени файла, чтобы это сработало, поскольку файлы из GitHub по умолчанию сохраняются как текстовые файлы).
  3. Откройте блокнот jupyter
  4. Перейдите в место, где вы сохранили файл .ipynb
  5. Откройте файл, вы увидите код

Надеюсь это поможет

Вот разработанное мной расширение Lifesaver для обоих

  • Хром
  • Fire Fox

Расширение открывает не только записные книжки, размещенные на github, в Colab, но и в nbviewer! И вы можете открыть репозиторий github из Colab и nbviewer и перейти к nbviewer из Colab и github Работает всеми тремя способами !!

Новая функция открытия новых блокнотов в один клик уже разработана в ветке master, просто нужно перенести ее на платформы расширения 🙂

How to save Jupyter notebooks from GitHub

When I download an ipynb file using the RAW button in GitHub it displays the text (json) in the browser.

Should I just copy this text into a file and name it xxx.ipynb ? What’s the best way to do it?

Eswar's user avatar

aerin's user avatar

5 Answers 5

  1. First click on Raw
  2. Then, press ctrl+s to save it as .ipynb (Note that you’ll have to manually type ‘.ipynb’ after the file name to make this work, as files from GitHub are saved as text files as default.)
  3. Open jupyter notebook
  4. Go to location where you saved .ipynb file
  5. Open file, you will see the code

Hope this helps

Ramesh Kumar's user avatar

The following steps worked for me:

  1. Click on Raw in git repository.
  2. Save the file. The file was saved as *.ipynb.txt format for me.
  3. Then, in the jupyter directory tree (not in local directory), I selected, removed the .txt at the end and renamed the file as *.ipynb. enter image description here
  4. Finally I was able to run the file as jupyter notebook. enter image description here

Note that, when I tried to rename the *.txt file in local directory to *.ipynb, it did not work. This had to be renamed in directory in jupyter itself.

Here is the Lifesaver Extension developed by me for both

  • Chrome
  • Firefox

The project is open-sourced here.

The extension not only opens github hosted notebooks in Colab but also in nbviewer!

And you can open the github repo from Colab and nbviewer And go to nbviewer from Colab and github Works all 3 ways!!

A new feature of opening new notebooks in one-click is already developed in the master branch, just need to push it to the extension platforms 🙂

How to download a Jupyter Notebook from GitHub?

I am working on a data science project inside of a Pandas tutorial. I can access my Jupyter notebooks through my Anaconda installation. The only problem is that the tutorial notebooks (exercise files) are on GitHub.

My question: how do I download the exercise files from GitHub and then have them display in the Jupyter notebook section on my computer so that I can use them interactively?

I am very new to Jupyter Notebooks. So far, I have been using PyCharm to execute all of my code.

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Downloading Jupyter notebooks from GitHub #10

Downloading Jupyter notebooks from GitHub #10


When you download an ipynb file using the RAW button in GitHub it displays the text int the browser. This is json code and contains all of the jupyter notebook cells. You can copy this text into a file and name it with the extension ipynb and it will contain the notebook when using it with Jupyter.

This is a little clunky so another options is:

  1. Launch an instance of the mybinder service
  2. Navigate to the notebook of interest
  3. Right Click and select Download linked file as

The text was updated successfully, but these errors were encountered:

First click on Raw.
Then, press ctrl+s to save it as .ipynb.
Open jupyter notebook.
Go to the location where you saved .ipynb file.
Open file, you will see the code.

Thanks..this is working

Thank you


If the first step (that is click on RAW) doesnot do anything (as it didnot work for me), so there is an alternative. The alternative step is to click on pencil icon (to Edit) which will show the code. So copy the contents in a notepad and save as .ipynb instead of .txt. (pls cancel the edit after you have saved the content in a file in your local computer). Then open the file in jupyter it will work like you wanted it to be. Hope this helps !

Добавить комментарий

Ваш адрес email не будет опубликован. Обязательные поля помечены *