1.Anaconda下载
在Anaconda官网上下载安装包,下载时选择python的版本,我选择的是python3.7版本,可能不是非常稳定。下载完成之后进行安装,存放在E盘里面。
2.Anaconda配置
打开Anaconda Prompt进行操作,下载pytorch和相应的内容。
conda info --envs 查看子环境,这里只有base和pytorch两个子环境
conda activate base 激活子环境
pip list查看该子环境下的所有内容
3.vscode关联Anaconda中pytorch里面的python
需要先将code-runner卸载掉,再在setting.json里,设置路径,加上code-runner.executormap