Yes, you don’t see it is called later. But in pytorch, the in-build random generator use the seed. Trace the related codes, you can find https://github.com/pytorch/pytorch/blob/1c51c185a1152ae7efe7d8d490102a9cdb7782e7/torch/lib/THC/THCTensorRandom.cpp 153. It is where you seed finally goes to.