当前位置:网站首页>[pytorch] install torch 1.8.1 and check whether torch version and GPU are available
[pytorch] install torch 1.8.1 and check whether torch version and GPU are available
2022-07-26 05:04:00 【zoetu】
stay conda Virtual environment installation torch==1.8.1+gpu edition .
The native environment
CUDA 11.1
python 3.7
install torch1.8.1
Use online installation , Offline installation requires downloading the corresponding torch、torchvision、torchaudia Installation package is a little troublesome .
1. Find the corresponding on the official website cuda edition 
2. Installation command
pip install torch==1.8.1+cu111 torchvision==0.9.1+cu111 torchaudio==0.8.1 -f https://download.pytorch.org/whl/torch_stable.html
If the version cannot be found , Please use pip3 install

View version
import torch
# testing torch、cuda、cudnn edition
print(torch.__version__)
print(torch.version.cuda)
print(torch.backends.cudnn.version())
# Is it available gpu
flag = torch.cuda.is_available()
print(flag)

边栏推荐
- 基于通用优化软件GAMS的数学建模和优化分析
- Unnamed Article 33
- Whether the SQL that fails to execute MySQL is counted into the slow query?
- When AQS wakes up the thread, I understand why it traverses from the back to the front
- AXI协议(4):AXI通道上的信号
- What is the difference between asynchronous and synchronous transmission signals (electronic hardware)
- CountLaunch Demo的测试
- Stm32fsmc extended SRAM
- JVM第五讲:纵横数据如何应对洪峰推送
- Excel VBA:实现自动下拉填充公式至最后一行
猜你喜欢

Excel VBA: summarize calculation output results by date (SUMIF)

columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by mysql8.0解决办法

The landing of tdengine in the GPS and AIS scheduling of Zhongtian steel

一次线上事故,我顿悟了异步的精髓

mysql函数汇总之日期和时间函数

Vector explanation and iterator failure

The first open source MySQL native HTAP database in China will be released soon! Look at the three highlights first, limited to the surrounding areas, waiting for you~

Nacos 介绍和部署

【pytorch】torch1.8.1安装、查看torch版本、GPU是否可用

推荐12个免费查找文献的学术网站,建议点赞、收藏!
随机推荐
汉字风格迁移篇---通过生成对抗网络学习一对多程式化汉字的转换和生成
Have you known several distribution methods of NFT? What are the advantages and disadvantages of different distribution methods?
科技论文翻译,俄语文档的语法有何特点
域名解析过程全分析,就着文字理解更佳
To study the trend of open source and gain insight into the future of the industry, stonedb community and the China Academy of communications and communications released the Research Report on the dev
C language -- string function, memory function collection and Simulation Implementation
Excel VBA: realize automatic drop-down filling formula to the last line
Building blocks for domestic databases, stonedb integrated real-time HTAP database is officially open source!
The integrated real-time HTAP database stonedb, how to replace MySQL and achieve nearly 100 times the improvement of analysis performance
注解@Autowired如何自动装配
Minipcie interface can card solves the problem of industrial computer expanding can channel minipcie can
MySQL基础学习
What is the real HTAP? (1) Background article
[mathematical modeling] analytic hierarchy process (AHP)
Principle of image nonlocal mean filtering
Test of countlaunch demo
地球系统模式(CESM)实践技术
提高shuffle操作中的reduce并行度
关于负数表示的数值为什么比整数大1?
webassembly 01基本资料