合并:

torch.cat(inputs=(a, b), dimension=1)


e.g. x = torch.cat((x,y), 0) 沿x轴合并




截取:

x[:, 2:4]