pytorch基础
一、两大函数
1、dir()函数
2、help()函数
3、函数的使用
import torch
torch.cuda.is_available()
Out[4]: True
dir(torch)
Out[5]:dir(torch.cuda)
Out[6]:dir(torch.cuda.is_available)
Out[7]:help(torch.cuda.is_available)
Help on function is_available in module torch.cuda:
is_available() -> bool
Returns a bool indicating if CUDA is currently available.
二、Pycharm、Python控制台、Jupyter的使用对比
三、加载数据
help()函数查询Dataset的作用