jupyter notebook

1. jupyter notebook 是一个基于web方式的ide

 1 C:\luke\Learn\ML\LearnJupyter>jupyter notebook
 2 [I 09:54:37.690 NotebookApp] Serving notebooks from local directory: C:\luke\Learn\ML\LearnJupyter
 3 [I 09:54:37.690 NotebookApp] Jupyter Notebook 6.4.11 is running at:
 4 [I 09:54:37.691 NotebookApp] http://localhost:8888/?token=141e865c5dad63d861ce9ec5ba0092573ab8fb8733ef6c2a
 5 [I 09:54:37.691 NotebookApp]  or http://127.0.0.1:8888/?token=141e865c5dad63d861ce9ec5ba0092573ab8fb8733ef6c2a
 6 [I 09:54:37.691 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
 7 [C 09:54:37.823 NotebookApp]
 8 
 9     To access the notebook, open this file in a browser:
10         file:///C:/Users/cuyz/AppData/Roaming/jupyter/runtime/nbserver-20268-open.html
11     Or copy and paste one of these URLs:
12         http://localhost:8888/?token=141e865c5dad63d861ce9ec5ba0092573ab8fb8733ef6c2a
13      or http://127.0.0.1:8888/?token=141e865c5dad63d861ce9ec5ba0092573ab8fb8733ef6c2a
14 [W 09:54:51.438 NotebookApp] Notebook shell_commands.ipynb is not trusted
15 [I 09:54:52.085 NotebookApp] Kernel started: 21aafe77-aa90-43bf-af0e-fd6261e9eed5, name: python3
16 [IPKernelApp] ERROR | No such comm target registered: jupyter.widget.control
17 [IPKernelApp] WARNING | No such comm: a8a9b2da-c789-4933-9d27-0b20a27ffb66
18 [I 09:56:51.838 NotebookApp] Saving file at /shell_commands.ipynb
19 [W 09:56:51.839 NotebookApp] Notebook shell_commands.ipynb is not trusted
20 [I 10:06:41.555 NotebookApp] 302 GET /?token=141e865c5dad63d861ce9ec5ba0092573ab8fb8733ef6c2a (::1) 2.000000ms
21 [W 10:06:49.649 NotebookApp] Notebook shell_commands.ipynb is not trusted
22 [IPKernelApp] ERROR | No such comm target registered: jupyter.widget.control
23 [IPKernelApp] WARNING | No such comm: be3d2c7f-4bdd-40d5-91d8-e7c5763cb621
24 [W 10:07:11.373 NotebookApp] Notebook shell_commands.ipynb is not trusted
25 [W 10:07:11.374 NotebookApp] Trusting notebook /shell_commands.ipynb
26 [IPKernelApp] ERROR | No such comm target registered: jupyter.widget.control
27 [IPKernelApp] WARNING | No such comm: c7836c53-1aaa-47aa-83da-bd31c58260c6
28 [I 10:09:13.017 NotebookApp] Saving file at /shell_commands.ipynb

运行后有后台进程在terminal里运行,并自动打开浏览器,可以按照terminal中的提示讲url copy到浏览器中打开jupyter notebook.

 

 2. 给函数添加说明,详见https://peps.python.org/pep-0257/

 3. Magic Commands, 以%开始,列出所有Magic Commands

1 %lsmagic

 

posted @ 2022-05-13 10:15  脱缰的野猪  阅读(1118)  评论(0编辑  收藏  举报