我正在尝试在 Ubuntu 18.04 上运行 jupyter notebook。安装后:
sudo apt-get install python3-notebook jupyter-core python-ipykernel
sudo apt-get install python3-dev
sudo apt-get install python-dev
pip3 install jupyter
jupyter notebook --generate-config
通过运行它似乎可以正常工作jupyter notebook
,但是重新启动后,系统返回此错误:
Error executing Jupyter command 'notebook': [Errno 2] No such file or directory
Jupyter 似乎可以通过运行以下命令来工作:
python3 -m IPython notebook
但我想用命令解决问题jupyter notebook
。
关于我的 jupyter 的更多信息:
之后pip3 list | grep jupyter
:
jupyter (1.0.0)
jupyter-client (5.2.3)
jupyter-console (5.2.0)
jupyter-contrib-core (0.3.3)
jupyter-contrib-nbextensions (0.5.0)
jupyter-core (4.4.0)
jupyter-highlight-selected-word (0.2.0)
jupyter-latex-envs (1.4.4)
jupyter-nbextensions-configurator (0.4.0)
之后pip3 list | grep ipy
:
ipykernel (4.8.2)
ipython (6.5.0)
ipython-genutils (0.2.0)
之后jupyter --paths
:
config:
/home/ale/.jupyter
/usr/etc/jupyter
/usr/local/etc/jupyter
/etc/jupyter
data:
/home/ale/.local/share/jupyter
/usr/local/share/jupyter
/usr/share/jupyter
runtime:
/run/user/1000/jupyter
显然,我的
PATH
变量以某种方式搞砸了,因为它没有./local/bin
正确引用目录。由于路径,我也面临同样的问题,使用
export PATH=$PATH:~/.local/bin/
它会解决你的问题