anaconda安装 pytorch

事件前言:

今天凌晨2点多时清华镜像源还可以正常使用,但是刚刚我电脑却使用不了了

使用中科大、阿里云等国内镜像的时候,一直报错:
Warning: 'https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/' already in 'channels' list, moving to the top

无奈我只能自己下载了

pytorch下载链接 <———点击这里进入网站

在这里插入图片描述

下载方法:

我需要下载两个文件: torch-1.4torchvision-0.4

torch 我选择 torch-1.4.0+cpu-cp36-cp36m-win_amd64.whl
(我的环境是 windows 下的 python3.6 )
在这里插入图片描述

torchvision 我选择: torchvision-0.4.2+cpu-cp36-cp36m-win_amd64.whl
在这里插入图片描述
这个 whl 后缀的文件迅雷应该不能下载,所以等待谷歌慢慢下载吧

安装:

进入环境:

输入安装 torch 的命令:
pip install C:\Users\27511\Desktop\torch-1.4.0+cpu-cp36-cp36m-win_amd64.whl

在这里插入图片描述

输入安装 torchvision 的命令:
pip install C:\Users\27511\Desktop\torchvision-0.4.2+cpu-cp36-cp36m-win_amd64.whl

在这里插入图片描述
这样就安装成功了。

注意:版本不能乱下载,不然可能会安装不了

如果有同学对本文方法不明白的可以评论联系我。

发布了35 篇原创文章 · 获赞 67 · 访问量 9189

猜你喜欢

转载自blog.csdn.net/qq_45504119/article/details/104905471