Greetings,
I’m running a depletion simulation:
...
with change_directory(saveDir):
with openmc.lib.quiet_dll(True):
dep.pool.USE_MULTIPROCESSING = True
depletion_operator = dep.CoupledOperator(
model=model,
chain_file=chainLoc,
normalization_mode = "fission-q",
fission_yield_mode = "average",
reduce_chain_level = 5,
reaction_rate_mode = "flux",
reaction_rate_opts = {
'energies': np.logspace(-5, 7 + np.log10(2), 3000, base=10),
'reactions': ['fission', '(n,gamma)', '(n,2n)', '(n,3n)', '(n,4n)', '(n,a)', '(n,p)'],
'nuclides': ['Th232', 'Pa231', 'U232', 'U233', 'U234', 'U235'],
})
dep.pool.USE_MULTIPROCESSING = True
depletion_operator.cleanup_when_done = True
integrator_class = dep.integrators.integrator_by_name[burnup_algo]
integrator = integrator_class(depletion_operator, time_steps, power_density=powerDensity, timestep_units='d')
with openmc.lib.quiet_dll(True):
dep.pool.USE_MULTIPROCESSING = True
integrator.integrate(True)
depletion_operator.finalize()
I know that pool.USE_MULTIPROCESSING = True
by default, and it will use all availabe threads because NUM_PROCESSES = None
by default. However, when I run the simulation using mpiexec -n 2 --map-by node:PE=12 --bind-to hwthread -x OMP_NUM_THREADS=12 python main-noreflector2.py
, and even though the output says MPI Processes | 2, OpenMP Threads | 12
, the depletion part only use one thread per processes:
Why is that? Is it because my system lacks of memory?
Thanks!