Thank you for your kind help . As you said, the results are equal.
For the convenience of others, I also post the code seed_torch：
def seed_torch(seed=1029):
    random.seed(seed)
    os.environ['PYTHONHASHSEED'] = str(seed)
    np.random.seed(seed)
    torch.manual_seed(seed)
    torch.cuda.manual_seed(seed)
    torch.backends.cudnn.deterministic = True

Actually, I’m working on a kaggle competition and reproducibility is very important. That’s one of the reasons I use pytorch.
Finally, thank you again for your help.