跳过vscode的安装
使用语句“conda create -n 容器的名称 python=3.7”创建容器使得可在一台电脑上安装多个版本的pytorch
conda create -n xxx python=yyy
或
如果报错
Solving environment: failed
CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://repo.anaconda.com/pkgs/main/win-64/repodata.json.bz2>
Elapsed: -
An HTTP error occurred when trying to retrieve this URL.
HTTP errors are often intermittent, and a simple retry will get you on your way.
If your current network has https://www.anaconda.com blocked, please file
a support request with your network engineering team.
ConnectionError(ReadTimeoutError("HTTPSConnectionPool(host='repo.anaconda.com', port=443): Read timed out."))
解决办法 base为当前所在的环境,“conda activate 名称”为新环境的激活方式
安装pytorch
https://pytorch.org/get-started/locally/ 进入容器,运行代码,pip list查看
|