try enabling torch.set_deterministic — PyTorch master documentation 1, and read its doc
it may well fall with runtime errors, as some operations don’t have built-in deterministic implementations (on gpu); sometimes only ops used in backward() diverge, then only the first batch has reproducible outputs. if whole first epoch is reproducible, maybe problem is with dataloader’s workers.