Preserve ENDF target excitation and reaction metadata in HDF5 - #4146
Open
paulromano wants to merge 3 commits into
Open
paulromano wants to merge 3 commits into
paulromano wants to merge 3 commits into
Conversation
Add FP_UNSET as a named quiet NaN and use it for unavailable target excitation energies and mass-difference Q values. Document that callers must check the sentinel with std::isnan rather than equality.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
I'm currently working on a capability in OpenMC for reconstructing recoil nuclei from neutron reactions. To properly identify the set of reaction products and energy available to them, it would be helpful to have a few pieces of data from the underlying ENDF evaluation that we don't currently store in our HDF5 files. Namely, the target excitation energy (ELIS), which accounts for energy stored in metastable targets; the mass-difference Q value (QM), which supplies the evaluated mass-difference energy release; and the breakup flag (LR), which identifies additional particles that the MT number alone does not specify. This PR simply pulls those pieces of data from the ENDF file when running
IncidentNeutron.from_njoyand stores it in our HDF5 files. While they are loaded in C++, they aren't currently used yet.To avoid confusion, I renamed the existing
q_valueattribute toq_reactionsince ENDF files hold two different definitions of the Q value (QI and QM; see ENDF-6 formats manual for details).q_valuestill works on the Python side but is deprecated.The change here is backwards compatible, so older produced HDF5 files will still work fine. I do plan on updating our data libraries but also have some other things in mind that I want to address while doing that (e.g., provenance metadata as proposed by #4117).
Checklist