(1)在anaconda3环境下创建python2虚拟环境:
conda create -n py27 python=2.7
(2)激活虚拟环境,并且安装python2.7版本jupyter notebook的kernel(内核):
conda activate py27
pip install ipykernel
(3)配置jupyter notebook的kernel(内核):
python -m ipykernel install --user
(5)打开jupyter notebook网页,选择kernel-->change kernel-->py27即可。