Allow Integrators to deplete w/o multiprocessing

Through a discussion on the user's group
https://groups.google.com/forum/#!topic/openmc-users/xHKYV-EBgrY
it was determined that some computing environments don't support
calls to fork() that multiprocessing.Pool requires. This can
lead to the depletion hanging indefinitely.

Users can now configure the
openmc.deplete.pool.USE_MULTIPROCESSING boolean to control
the use of multiprocessing during depletion. The default state
is to use multiprocessing. Otherwise itertools.starmap will be
used to update the compositions "in serial"
This commit is contained in:
Andrew Johnson 2020-06-18 16:02:34 -04:00
parent a905e5c9e2
commit 89259e310e
No known key found for this signature in database
GPG key ID: 253418E91B7F6FEB
3 changed files with 37 additions and 7 deletions

View file

@ -145,6 +145,17 @@ with :func:`cram.CRAM48` being the default.
cram.CRAM48
pool.deplete
.. data:: pool.USE_MULTIPROCESSING
Boolean switch to enable or disable the use of :mod:`multiprocessing`
when solving the Bateman equations. The default is to use
:mod:`multiprocessing`, but can cause the simulation for hang in
some computing environments, namely due to MPI and networking
restrictions. Disabling this option will not utilize all processing
units and take a little more time.
:type: bool
The following classes are used to help the :class:`openmc.deplete.Operator`
compute quantities like effective fission yields, reaction rates, and
total system energy.