使得jupyter可以创建虚拟环境的代码
记得用管理员权限打开 Anaconda Prompt
前置条件:在base环境中安装nb_conda_kernels(已安装)
conda activate base # could be also some other environment 这一步我已经做过啦!
conda install nb_conda_kernels
jupyter notebook
在需要使用jupyter的虚拟环境中安装ipkernel
conda activate my-conda-env # this is the environment for your project and code
conda install ipykernel
conda deactivate
在conda中打开jupyter notebook就可以了。
使得jupyter打开指定的工作区文件夹
jupyter notebook --generate-config查看路径
- 修改jupyter_notebook_config.py文件
## The directory to use for notebooks and kernels. #c.NotebookApp.notebook_dir = '' 将其改为 ## The directory to use for notebooks and kernels. c.NotebookApp.notebook_dir = '工作空间'