Including weight function specification into ALARAJOYWrapper - #317
Open
eitan-weinstein wants to merge 2 commits into
Open
Including weight function specification into ALARAJOYWrapper#317eitan-weinstein wants to merge 2 commits into
eitan-weinstein wants to merge 2 commits into
Conversation
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.
Closes #312.
This PR enables ALARAJOYWrapper to process groupwise cross-sections with weight functions other than the standard Vitamin-E, that was otherwise hard-coded as a pre-set GROUPR parameter in
njoy_tools. Primarily, this is accomplished by abstracting the functionnjoy_tools.set_group_structure()to beingnjoy_tools.set_modifiable_groupr_parameters(). The logic for implementing group structure vs weight function specifications is nearly identical, so I've combined both into an agnostic function wherein the respective command line argument and reference dictionaries are supplied to extract either group structure or weight function parameters. In its implementation withinpreprocess_fendl3.main(), this looks like:Unlike the group structure handling, I did not include functionality for arbitrary weight function applications, even though NJOY is capable of accommodating them. My main reasoning was that I was building this new functionality specifically for the purpose of having the ability to do
1/Eweighting, which is included among the built-in NJOY weight functions, so that I could have a 1:1 comparison to FISPACT-II's PREPRO-processed TENDL data. While I could conceive of a user theoretically wanting to create a fully customized weight function themselves (although Vitamin-E is still the standard FENDL weight function), the NJOY implementation is considerably more complex than for arbitrary group structures, which really only require the group bounds. Given that, it did not seem like a worthwhile way to spend my time at this point to build the most expansive arbitrary weight function capabilities, but rather to limit the scope to NJOY's built-in options, which will still allow us to make the necessary comparisons with FISPACT-II.