Jupyter Notebook是以网页的形式打开,可以在网页页面中直接编写代码和运行代码,代码的运行结果也会直接在代码块下显示。如在编程过程中需要编写说明文档,可在同一个页面中直接编写,便于作及时的说明和解释。 详见:[[https://www.jianshu.com/p/91365f343585|Jupyter Notebook介绍、安装及使用教程]] ====== 安装 ====== 小白用户(并且磁盘剩余空间超过3G)推荐通过Anaconda安装,Anaconda包括Jupyter以及其他科学计算相关包。 Python高级用户可以使用Pip安装,安装包名称是jupyter ====== 启动 ====== jupyter notebook # 指定端口 jupyter notebook --port # 不自动打开浏览器 jupyter notebook --no-browser ====== 远程访问 ====== 详见:[[https://www.jianshu.com/p/8fc3cd032d3c|远程访问服务器Jupyter Notebook的两种方法]] * 生成默认配置文件 jupyter notebook --generate-config * 生成访问密码(token) 终端输入''ipython'',设置你自己的jupyter访问密码,注意复制输出的sha1:xxxxxxxx密码串: In [1]: from notebook.auth import passwd In [2]: passwd() Enter password: Verify password: Out[2]: 'sha1:xxxxxxxxxxxxxxxxx' * 修改./jupyter/jupyter_notebook_config.py中对应行如下 c.NotebookApp.ip='*' c.NotebookApp.password = u'sha:ce...刚才复制的那个密文' c.NotebookApp.open_browser = False c.NotebookApp.port =8888 #可自行指定一个端口, 访问时使用该端口 随后启动jupyter即可在同一网络中的任意电脑浏览器访问