关闭本地计算机后,继续在Jupyter Notebook中远程运行单元

时间:2018-10-02 08:18:49

标签: python pandas server jupyter-notebook

我正在使用本地计算机并在服务器中运行算法。为了使Jupyter笔记本保持运行,我在服务器中运行以下命令:

  

nohup jupyter笔记本-无浏览器&

我通过此cmd访问本地计算机中的jupyter笔记本服务器:

ssh -nNT -L 9999:localhost:8888 myuser@ipServer

我试图在jupyter的单元格中同时运行这两个编码行:

profile=pandas_profiling.ProfileReport(df)
profile.to_file(outputfile='myoutputfile_FINAL_DATASET.html')

数据集非常庞大:4,51 GB,有840.000行和5308列(运行了4天)

我认为,如果我添加这两行以nohup运行,它将保留变量概要文件,并转到下面的行。但是,变量配置文件似乎在运行完第一行后就消失了。

在本地计算机上关闭jupyter笔记本时,是否仍要运行整个单元格?

编辑:

我意识到今天早晨发生了一些事情,突然,内核在 [I 06:54:03.346 NotebookApp]

无故重启
[I 12:43:53.577 NotebookApp] Starting buffering for c9688f9f-ed12-4eff-a18c-aa300b62faf1:8a1a4286bc5d43d6823c15c9ad8c9512
[I 12:43:55.592 NotebookApp] Starting buffering for b207c9f7-f0c7-40e7-8f67-1c85024a8be6:4a9971a622294cd1832873e0fbc181f0
[I 06:54:03.346 NotebookApp] KernelRestarter: restarting kernel (1/5), keep random ports
[I 09:35:34.509 NotebookApp] 302 GET / (127.0.0.1) 24.76ms
[W 09:35:35.347 NotebookApp] 404 GET /apple-touch-icon-precomposed.png (127.0.0.1) 53.83ms referer=None
[W 09:35:35.376 NotebookApp] 404 GET /apple-touch-icon.png (127.0.0.1) 1.23ms referer=None
[I 09:35:47.593 NotebookApp] Adapting to protocol v5.1 for kernel b207c9f7-f0c7-40e7-8f67-1c85024a8be6
[I 09:37:47.424 NotebookApp] Saving file at /Profiling_FINAL_DATASET.ipynb
[I 09:39:49.759 NotebookApp] Saving file at /Profiling_FINAL_DATASET.ipynb
[I 09:41:49.777 NotebookApp] Saving file at /Profiling_FINAL_DATASET.ipynb
[W 09:44:47.657 NotebookApp] WebSocket ping timeout after 119897 ms.
[I 09:44:52.708 NotebookApp] Starting buffering for b207c9f7-f0c7-40e7-8f67-1c85024a8be6:eb4a6d0415604f078b9c0229d93cdc33
[I 10:04:17.875 NotebookApp] Adapting to protocol v5.1 for kernel b207c9f7-f0c7-40e7-8f67-1c85024a8be6
[I 10:04:17.884 NotebookApp] Restoring connection for b207c9f7-f0c7-40e7-8f67-1c85024a8be6:eb4a6d0415604f078b9c0229d93cdc33
[I 10:04:25.803 NotebookApp] 302 GET / (127.0.0.1) 3.45ms
[I 10:04:42.583 NotebookApp] Adapting to protocol v5.1 for kernel b207c9f7-f0c7-40e7-8f67-1c85024a8be6
[I 10:07:56.233 NotebookApp] Saving file at /Profiling_FINAL_DATASET.ipynb
[I 10:09:56.421 NotebookApp] Saving file at /Profiling_FINAL_DATASET.ipynb

0 个答案:

没有答案