pytorch 中view是tensor方法,然而在sequential中包装的是nn.module的子类, 因此需要自己定义一个方法: import torch.nn as nn cla Reshape(nn.Modu.
確定! 回上一頁