Web开发工具——Jupyter notebook

2023-06-05,,

jupyter-notebook 安装及远程访问

Introduction

Jupyter Notebook(此前被称为 IPython notebook)是一个交互式笔记本,支持运行 40 多种编程语言

Jupyter Notebook 的本质是一个 Web 应用程序,便于创建和共享文学化程序文档,支持实时代码,数学方程,可视化和 markdown

Install

pip install jupyter

Start

jupyter-notebook

Remote Visit

# create config
jupyter notebook --generate-config # config passwd
ipython
from notebook.auth import passwd
passwd()
Enter password:
Verify password:
Out[2]: 'sha1:15403540516a:71855952007c3cb7421f9f2b2b54623a897febc4' # modify config
vim ~/.jupyter/jupyter_notebook_config.py
c.NotebookApp.ip='*'
c.NotebookApp.password = u'sha1:15403540516a:71855952007c3cb7421f9f2b2b54623a897febc4'
c.NotebookApp.open_browser = False
c.NotebookApp.port =8888 #随便指定一个端口

常见问题

描述:jupyter开启远程访问以及遇到No address associated with hostname问题
解决方案:将c.NotebookApp.ip='*' 改为 c.NotebookApp.ip='0.0.0.0'

Web开发工具——Jupyter notebook的相关教程结束。

《Web开发工具——Jupyter notebook.doc》

下载本文的Word格式文档,以方便收藏与打印。