Fix deadlock when calling InitRandomPars without seed
Created by: femtobit
Calling GetRandomEngine
may create a new DistributedRandomEngine
. This operation, through GetDerivedSeed
, performs an MPI broadcast. Thus, GetRandomEngine
needs to be called from all MPI processes in order to prevent a deadlock.