pytorch验证gpu可用

2022-10-26 08:58:20
(3.9.7) xiaxinkai@tuf:~$ python
Python 3.9.7 (default, Sep 16 2021, 13:09:58) 
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> print(torch.cuda.is_available())
True
>>> exit()
(3.9.7) xiaxinkai@tuf:~$
  • 作者:夏天了啊
  • 原文链接:https://blog.csdn.net/xiaxinkai/article/details/123564395
    更新时间:2022-10-26 08:58:20