1. Modify the storage location of the virtual environment (optional)
Windows
: Open the file C:\Users\DongZhaoCheng(对应到你本人的用户名)\.condarc
, add envs_dirs: [D:\003SoftDevTool\anaconda_env](对应到你自己执行的目录)
, save and exit
2. Enter the system terminal to create a virtual environment
Windows:
conda env list
: View the list of currently owned conda environments
conda create -n env_py38_jupyter python=3.8
: Create a virtual environment with the name and the version env_py38_jupyter
of the interpreter usedpython3.8
create
When the command is in use, please close vpn
the circumvention proxy
3. Enter Anaconda prompt
the command window
Anaconda prompt
Windows: Execute the following commands in sequence
activate env_py39_jupyter
: Activate the virtual environment
pip install -i https://pypi.tuna.tsinghua.edu.cn/simple ipykernel
: Install the kernel
python -m ipykernel install --user --name Python39 --display-name "Python 39"
: Write the kernel of the current Python environment to the kernel of Jupyter
A successful result looks like this:
4. Go back to the normal terminal and open the Jupyter notebook
Excuting an order:jupyter notebook
If this article is useful to you, you can like and bookmark this article. It will be much easier to find next time you use it. It would be great
if you can follow the author. The author will continue to learn, output, and share! Thank you for your encouragement!