【发布时间】:2017-05-15 17:48:21
【问题描述】:
与此问题sys.path different in Jupyter and Python - how to import own modules in Jupyter? 中的问题相同。在纯 Python 中,它将我的系统环境变量 PYTHONPATH 添加到 sys.path 但 Jupyter notebook 没有,所以我无法导入自己的模块。
在SO上问过很多类似的问题,解决方法是直接在脚本中操作sys.path。
有没有办法让 Jupyter notebook 使用我的系统 PYTHONPATH 变量,就像在纯 python 中一样?
【问题讨论】:
标签: python windows jupyter-notebook