Ipython笔记本:Mac中的jupyter_Notebook_config.py在哪里?

2024-05-18 08:44:26 发布

您现在位置:Python中文网/ 问答频道 /正文

我刚开始用Mac,所以请原谅我这听起来太天真了。

我正在尝试安装Interactive Parallel。从https://github.com/ipython/ipyparallel,上面说我需要找到jupyter_notebook_config.py

我已经用Anaconda安装了python和相关的包,并且可以使用ipython笔记本。但是当我用spotlight搜索jupyter_notebook_config.py时,我找不到这个文件:

enter image description here

那么,我在哪里可以找到这个文件?

更新:这是我的home文件夹:

enter image description here

只有anaconda


Tags: 文件pyhttpsgithubcomconfigparallelmac
3条回答

正如cqcn1991所说,首先需要生成配置文件。

从我的主路径向下钻取之后,我在这里找到了生成配置文件的可执行文件,以及如何生成它。

我还必须用./引用jupyter可执行文件,因为我的路径中显然还没有这个文件,但将添加它。

cd /Users/myMac/anaconda2/bin
 ./jupyter notebook --generate-config
Writing default config to: /Users/myMac/.jupyter/jupyter_notebook_config.py

然后我在主目录中找到了配置文件。

在主目录中查找.jupyter文件夹。 它应该包含符合docs的文件:

The notebook web server can also be configured using Jupyter profiles and configuration files. The Notebook web server configuration options are set in a file named jupyter_notebook_config.py in your Jupyter directory, which itself is usually .jupyter in your home directory.

如果.jupyter文件夹不包含jupyter_notebook_config.py文件,则需要使用jupyter notebook --generate-config生成它。

相关问题 更多 >