본문 바로가기
TensorFlow(AI)/Python&Django

The easiest way to convert Jupyter(.ipynb) to Python(.py)

by swconsulting swconsulting 2018. 12. 6.

source : https://medium.com/@researchplex/the-easiest-way-to-convert-jupyter-ipynb-to-python-py-912e39f16917




Install ipython libraries (Of course, you can skip if already installed.)

> pip install ipython

> pip install nbconvert

Convert single file

> ipython nbconvert — to script abc.ipynb

You can have abc.py

Convert multi files

> ipython nbconvert — to script abc.ipynb def.ipynb

abc.py, def.py

> ipython nbconvert — to script *.ipynb

abc.py, def.py

All done!

Have a good day ^^


D:\Workspace.deepLearning\keras\keras>jupyter nbconvert 2.1-a-first-look-at-a-neural-network.ipynb

[NbConvertApp] Converting notebook 2.1-a-first-look-at-a-neural-network.ipynb to html

[NbConvertApp] Writing 298899 bytes to 2.1-a-first-look-at-a-neural-network.html

'TensorFlow(AI) > Python&Django' 카테고리의 다른 글

python get current datetime  (0) 2018.12.15
Sample plots in Matplotlib¶  (0) 2018.12.14
The easiest way to convert Jupyter(.ipynb) to Python(.py)  (0) 2018.12.06
pandas-datareader  (0) 2018.11.21
django forms  (0) 2018.10.25
Python3 json Parse  (0) 2018.10.08

댓글0