- syntax fixes and adjustments
- change name of FluxDepletionOperator to IndependentOperator
- flux_operator.py -> independent_operator.py
- new class, MicroXS, for creating (for now) one-group microscopic
cross section DataFrames. This class takes the functionality that was
previously in static functions in IndependentOperator
- Associated changes to the test suite and online docs
- new class OpenMCOperator to contain shared bits of code between the
currently existing Operator class and the as-of-yet to be created
FluxDepletionOperator class
- Operator is now a subclass of OpenMCOperator
- move _distribute method to OpenMCOperator
- move _get_burnable_mats, _extract_number, _set_number_from_mat,
_set_number_from_results to OpenMCOperator
- split initial condition into openmc.lib dependent and non-dependent
parts; dependent part goes to Operator, non-dependent part goes to
OpenMCOperator
- move _update_materials to OpenMCOperator
- move _get_tally_nuclides to OpenMCOperator
- rename _unpack_tallies_and_normalize to _calculate_reaction_rates;
move to OpenMCOperator
- move get_results_info to OpenMCOperator
Provide explicit __all__ lists for files in openmc/deplete
containing classes that should be brought into the "primary"
API. This prevents cluttering the openmc.deplete namespace
caused by the wildcard imports
```
from .nuclide import *
...
```
The abc, cram, and helpers modules are imported simply as
```
from . import abc
from . import cram
from . import helpers
```
Much of the previous API is intact, with the major change
being CRAM functions are imported from openmc.deplete.cram
in the test_deplete_cram.
The integrator abstract classes are placed in
openmc/deplete/abc.py with all concrete classes going in to
openmc/deplete/integrators.py
Documentation updated accordingly
Method openmc.deplete.Results.save now accepts a new argument,
proc_time, to represent the time each process spent depleting
all materials. This value is summed across all processes to
get the total cpu time depleting. Time in transport simulations
should not be included.
The value written to depletion_results.h5 is
proc_time / (n_proc * n_burn_materials)
to get a look at the average time required to deplete a material.
A new dataset, "depletion time" is created in this file, and has
one fewer rows than other data set, like eigenvalues. This corresponds
to there being one fewer round of depletion simulations than transport.
The proc_time is also read in from the depletion file in the
class method Results.from_hdf5(), with one notable exception.
If data from the last step is requested, then the proc_time
attribute will be a numpy array of nans, reflecting the lack
of depletion data.
Check added in openmc/depletion/__init__.py.
Without this check, the exporting of the Results to hdf5 will
hang, as the second process attempts to write to a file
that has already been opened on another process.
This error is only raised after a full transport calculation
has been run.
The check raises a more helpful error directly at the import
from openmc.deplete, prior to transport calculations.