Centos安装Jupyter
datehoer 12/13/2022 教程pythoncentos
推荐使用anaconda管理python版本,或者别的虚拟环境对python进行管理。
首先新建一个python版本
conda create --name py39 python=3.9
1
然后进入环境安装jupyter
conda activate py39
pip install jupyter
1
2
2
如果报错的话,应该是因为pip的版本低
可以更新一下pip的版本
pip install --upgrade pip
1
然后设置一下密码
# 生成配置文件
jupyter notebook --generate-config
# 设置密码,提示两次输入密码,然后密码被保存到jupyter_notebook_config.json中
jupyter notebook password
1
2
3
4
2
3
4
之后执行命令启动即可
jupyter notebook --ip 0.0.0.0 --allow-root
1