使用pip安装pytorch

写一个文章记录一下安装过程。最近要新装一个anaconda环境用来跑代码,需要安装一些依赖包。

先使用github作者给的安装方法:

pip install -r requirements.txt

显示torch安装失败,找不到指定版本。
怀疑没有指定源,换了个源:

pip install -r requirements.txt -i https://pypi.douban.com/simple/

结果还是找不到源,然后去找教程。
用的笔记本电脑,带有显卡,所以直接pip安装会显示找不到适合的版本。于是去pytorch官网找一个适合的版本,按照官网命令可以直接安装。(如果安装失败可能是网络问题)
教程参考windows10下安装GPU版pytorch简明教程

下面是pytorch官网截图

搞了半天终于把pytorch安装好,环境配好啦。
结果郁闷的事情发生啦,我说重新配置一个新环境,按照下面这个

pip install -r requirements.txt

居然这次跑成功啦。

真搞不懂为什么,不过两个torch版本装的是不一样。

使用pip安装pytorch失败,报错如下Could not find a version that satisfies the requirement torch相关推荐

  1. Python pip install 安装包报错ERROR: Could not find a version that satisfies the requirement XXX解决方法

    Python pip install 安装包报错ERROR: Could not find a version that satisfies the requirement XXX解决方法 文章目录 ...

  2. 【错误记录】Python 安装依赖库报错 ( ERROR: Could not find a version that satisfies the requirement elftools )

    文章目录 一.报错信息 二.解决方案 一.报错信息 报错信息 : ERROR: Could not find a version that satisfies the requirement elft ...

  3. pip安装tensorflow报错:could not find a version that satisfies the requirement grpcio>=1.8.6

    pip安装tensorflow报错:could not find a version that satisfies the requirement grpcio>=1.8.6 (venv) D: ...

  4. pip下载包报错ERROR: Could not find a version that satisfies the requirement xxxx==1.0.2 (from versions

    我在安装pymysql的时候报错 ERROR: Could not find a version that satisfies the requirement pymysql==1.0.2 (from ...

  5. Mac用Pycharm安装mediapipe报错ERROR: Could not find a version that satisfies the requirement mediapipe

    问题 因为最近要用python做一个手部检测的项目,于是用找了个开源的程序跑了跑,发现安装mediapipe的时候会报错 ERROR: Could not find a version that sa ...

  6. windows上报错:Could not find a version that satisfies the requirement torch==0.4.1

    windows上错误:Could not find a version that satisfies the requirement torch==0.4.1 文章目录: 一.问题 1.错误问题的出现 ...

  7. python pip下载本地依赖包,并在离线环境中安装,并解决报错ERROR: Could not find a version that satisfies the requirement报错

    文章目录 步骤1:导出依赖 步骤2:离线下载依赖包 步骤3:进入新环境使用python安装依赖 整体思路如下: 首先根据项目需要导出依赖包,由于本地的python环境中其实安装了很多乱七八糟的包,这些 ...

  8. pip安装tensorflow报错:could not find a version that satisfies the requirement grpcio=1.8.6

    下图红色字体为错误提示: - ERROR: Could not find a version that satisfies the requirement grpcio>=1.8.6 (from ...

  9. Python安装包报错ERROR: Could not find a version that satisfies the requirement XXX解决方法

    我们在使用 pip 安装 python 包时,经常会出现如下错误: ERROR: Could not find a version that satisfies the requirement xxx ...

最新文章

  1. 计算机游戏的产生,孩子容易沉迷计算机游戏,原来是因为过程中产生“心流”经验?...
  2. MySQL · 引擎分析 · InnoDB行锁分析
  3. 一个免费分享绘图代码的网站
  4. iOS:触摸控件UITouch、事件类UIEvent
  5. 77. Leetcode 1439. 有序矩阵中的第 k 个最小数组和 (堆-技巧二-多路归并)
  6. Subversion 1.7 Eclipse integration in Ubuntu12(转载)
  7. 如何使用 Linq 获取每个分组中的第一个元素?
  8. css规则中区块block,CSS的命名方式:BEM(区块、元素、修饰符)
  9. 在MyEclipse Tomcat可以运行但是在Tomcat 6.x上却不可以运行
  10. GNU __attribute__ 总结
  11. mysql如何清空数据库表内容
  12. iOS PDF 添加图片
  13. 2019-2020浴血凤凰DNF自动化辅助开发教程
  14. idea打开命令行窗口
  15. ionic3保存图片到本地相册
  16. android短信接受震动,Android中实现拨打电话、发送短信、响铃、震动和获取当前时间...
  17. acme.sh申请Let‘s Encrypt 免费HTTPS证书
  18. nth-of-type和nth-child区别
  19. 学员感言html效果图,学员感言:陪伴,是最长情的告白
  20. 用python做一个自动签到程序

热门文章

  1. 计算机毕业设计Java智能停车场管理系统(源码+系统+mysql数据库+lw文档)
  2. 独家3.1.2版本独立微信社群人脉系统社群空间站最新源开码源+详细教程
  3. Android M 新控件了解学习
  4. iTunes Connect 基本使用说明
  5. NodeMCU入门,烧程序点灯。
  6. (windows图形化界)粘滞键后门
  7. 在SQLServer处理中的一些问题及解决方法
  8. 分享股票level2接口的量价趋势指标源码
  9. Mathtype7在Word2016中闪退
  10. 眼科刀行业调研报告 - 市场现状分析与发展前景预测(2021-2027年)