Pytorch错误:Torch not compiled with CUDA enabled
一、问题
今天跑一个项目代码遇到了一个问题,大致是pytorch和CUDA版本不匹配,然后我就降低pytorch版本,结果1.7中网络不包含我所需的函数,我直接pip install pytorch==1.8,这样产生了错误:Torch not compiled with CUDA enabled。
二、解决方法
nvcc -V
检查一下当前CUDA版本
根据自己的CUDA版本下载安装whl文件
参考链接:https://download.pytorch.org/whl/torch_stable.html
分别
pip install torch-1.8.1+cu101-cp38-cp38-linux_x86_64.whl
pip install torchcsprng-0.2.1+cu101-cp38-cp38-linux_x86_64.whl
pip install torchvision-0.9.1+cu101-cp38-cp38-linux_x86_64.whl
Pytorch错误:Torch not compiled with CUDA enabled相关推荐
- AssertionError: Torch not compiled with CUDA enabled【pycharm/python3/pip】
目录 问题 查阅资料 解决步骤 1.检查pytorch版本.是否有CUDA 2.安装CUDA前看电脑的显卡驱动程序版本.支持的最高版本 3.安装CUDA和cuDNN 4.卸载pytorch 5.重新安 ...
- Torch not compiled with CUDA enabled 报错的归纳总结
以前总是嫌装环境太麻烦,碰到些需要用到GPU的项目都不想去复现了...这次因为论文需要,下定决心要把pytorch的安装问题搞定,但是期间遇到了很多问题,最烦人的莫过于这个' AssertionErr ...
- AssertionError: Torch not compiled with CUDA enabled到底是什么原因
代码运行报错AssertionError: Torch not compiled with CUDA enabled 但是根据cuda安装显示 cuda是安装成功的 这是怎么回事 我先进入百度翻译 A ...
- 解决 AssertionError Torch not compiled with CUDA enabled
最近在矩池云的的Tesla K80机子上跑MMYOLO,跟着MMYOLO官方文档<自定义数据集 标注+训练+测试+部署 全流程 >操作到 "2.1.1 软件或者算法辅助" ...
- AssertionError: Torch not compiled with CUDA enabled解決方案
在執行pytorch代碼的時候,突然看到報錯 AssertionError: Torch not compiled with CUDA enabled 這說明了 1. 你pytoch确实安装了 2. ...
- Torch not compiled with CUDA enabled
Torch not compiled with CUDA enabled 如果没有可用的显卡资源,则检查代码,把调用显卡资源的部分全部去掉即可 https://blog.csdn.net/qq_403 ...
- 成功解决raise AssertionError(“Torch not compiled with CUDA enabled“)AssertionError: Torch not compiled
成功解决raise AssertionError("Torch not compiled with CUDA enabled") AssertionError: Torch not ...
- AssertionError: Torch not compiled with CUDA enabled 解决方案
报错 Traceback (most recent call last):File "main_pretrain.py", line 250, in <module>m ...
- 报错 AssertionError: Torch not compiled with CUDA enabled
报错: AssertionError: Torch not compiled with CUDA enabled 本文针对仅有CPU无GPU的设备,针对该报错进行修改: 在代码开头添加: // A c ...
最新文章
- TA 们放肆摇晃的青春尾巴
- pyhanlp 文本聚类
- Linux入门基础分享[一]
- 1103: [POI2007]大都市meg(dfs序+线段树||树状数组)
- .net core精彩实例分享 -- 文件与I/O
- java自己写不出来_java学习中,能看懂代码,但是自己写不出来怎么处理?
- java枚举类型详解
- ZZULIOJ 1050~1059(oj入门题)
- 微服务结合领域驱动设计落地
- 二级c语言考试怎么调试程序,计算机二级C语言上机考试操作步骤及流程和注意事项...
- 怎么更换驾驶证上面的照片?教你如何更换驾驶证照片
- 【网络爬虫项目】实战知识点 - webcrawler
- Pygame:播放声音和音效
- Chrome源码剖析——多线程模型、进程通信、进程模型
- 【电子技术】如何抑制共模、差模噪声?
- android自动生成dimens适配文件
- 基于微信小程序云开发实现的婚礼邀请函模板,可以自行定制开发
- 【网络游戏§绿色DOTA2魔笛V1.001 官方最新版§DOTA游戏辅助工具§】
- 鸿蒙系统2.0电视版,鸿蒙2.0系统,鸿蒙2.0发布系统官方最新版预约 v1.0-手游汇
- 结构体在cuda核函数里面不能用吗_求职招聘 | 面试机器学习职位,这些知识点你都会了吗?...