一:老版本的 variable
二:新版 tensor
曾经:求导相关
如今:数据相关
–dtype: 张量的数据类型,三大类,共9种。torch.FloatTensor, torch.cuda.FloatTensor
–shape: 张量的形状。如:(64,3,224,224)
–decive: 所在设备
三:tensor创建方法
Tensor创建一:直接创建 (共享内存:out)
1
曾经:求导相关
如今:数据相关
–dtype: 张量的数据类型,三大类,共9种。torch.FloatTensor, torch.cuda.FloatTensor
–shape: 张量的形状。如:(64,3,224,224)
–decive: 所在设备
1