My server crashed after running this code?

The order of calls still matter as shown here:

torch.manual_seed(2809)
# modelA weight matrix
weightA = torch.randn(2, 2)
# modelB weight matrix
weightB = torch.randn(3, 3)
print(weightA)
print(weightB)

# will yield exactly the same results
torch.manual_seed(2809)
# modelA weight matrix
weightA = torch.randn(2, 2)
# modelB weight matrix
weightB = torch.randn(3, 3)
print(weightA)
print(weightB)

# this will not!
torch.manual_seed(2809)
# modelB weight matrix
weightB = torch.randn(3, 3)
# modelA weight matrix
weightA = torch.randn(2, 2)
print(weightA)
print(weightB)

Have a look at the Wikipedia article on PRNG for more information.