如何导航到 Jupyter Notebook 中的不同目录? [英] How to navigate to a different directory in Jupyter Notebook?

查看:49
本文介绍了如何导航到 Jupyter Notebook 中的不同目录?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近安装了 Anaconda 5 和 Jupyter Notebook.我对其丰富的功能感到兴奋,但我找不到导航到非子目录的方法.更具体地说,我尝试双击文件夹图标,但结果是相同的视图.

I have recently installed Anaconda 5 and with it Jupyter Notebook. I am excited with its rich functionality but I can not find a way to navigate to directories which are not children. More specifically I have tried to double-click the folder icon but that resulted in the same View.

您的建议将不胜感激.

推荐答案

Jupyter 资源管理器的默认根目录是您启动 Jupyter 服务器的当前位置(文件夹).使用资源管理器,您只能导航到子文件夹的所有级别,而不能导航到该位置的父文件夹.当您启动 Jupyter 时,可以选择设置根文件夹 --notebook-dir.这是启动 Jupyter 服务器并将根设置在 D:/my_works/jupyter_ipynbs

Default root of the Jupyter explorer is the current location (folder) where you start the Jupyter server. With the explorer, you can only navigate to all levels of the children folders, but not the parent's of that location. There is an option to set the root folder --notebook-dir when you start Jupyter. Here is an example that starts Jupyter server and sets the root at D:/my_works/jupyter_ipynbs

jupyter notebook --notebook-dir D:/my_works/jupyter_ipynbs

同样,对于jupyter lab:

jupyter lab --notebook-dir D:/my_works/jupyter_ipynbs

在浏览器上打开 Jupyter 后,其主目录或根目录将是您指定的 --notebook-dir 值,在本例中为 D:/my_works/jupyter_ipynbs.从那时起,您可以导航到其所有子目录.

Once Jupyter is open on the browser, its home or root directory will be what you specified as the value of --notebook-dir, in this case D:/my_works/jupyter_ipynbs. From that point, you can navigate to all its sub-directories.

这篇关于如何导航到 Jupyter Notebook 中的不同目录?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆