步骤如下图:
第一步:下载安装conda或者是miniconda
第二步:新建一个虚拟环境
新建:conda create -n d2l-zh python=3.8
【问题:使用conda创建或安装Python包出现网络连接失败】
解决方案:添加国内镜像
查看conda已有镜像:conda config --show channels
激活使用:conda activate d2l-zh
第三步:安装需要的包
pip install jupyter d2l torch torchvison
1.【matplotlib】matplotlib-3.4.0-cp38-cp38-win_amd64.whl
2.【numpy】numpy-1.22.3-cp38-cp38-win_amd64.whl
3.【torch】torch-1.10.2-cp38-cp38-win_amd64.whl
4.【torchvision】torchvision-0.11.3-cp38-cp38-win_amd64.whl
安装需要的包:安装包