注意:torch.mm和转置(.t())只是适用于2维矩阵,推荐使用torch.matmul(等价于@) 多维度数据的转置使用的是transpose或者permute。 matmul:只取后两个维度进行相乘。符合broadcast机制的可以相乘。