用torch写一个topk+add的小模型 import torch print(torch.__version__) class Net1(torch.nn.Module): def __init__(self): super(Net1, self).__init__() def forward(self, x): output = torch.topk(x,1000) print("**********