Repository navigation
Conversation
apply_time_correction with sum_nuclides=True returns a derived tally that only holds a mean and standard deviation, so applying a virtual material afterwards failed with "the tally does not contain any results". For such tallies the mean and standard deviation are now scaled directly, which gives the same result as scaling the raw moments first. Co-authored-by: jon-proximafusion <174589458+jon-proximafusion@users.noreply.github.com>
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
For a D1S decay photon dose in a virtual material the natural sequence is to sum the time corrected tally over parent nuclides and then apply the material:
The summed tally is derived and only holds a mean and standard deviation (
sum/sum_sqare dropped since they cannot be combined across parent nuclides), soapply_virtual_materialraisedUnable to apply a virtual material since the tally does not contain any results, which reads as if the run produced nothing. Applying the material first worked, so the result depended on call order.For a derived tally with no raw moments the mean and standard deviation are now scaled by the atom densities directly. This is the same answer as scaling the raw moments: checked on a D1S statepoint (steel shell, silicon dose, 37 parent nuclides), both orders now give identical means and standard deviations. Tallies with no results at all still raise the same error.
Test
test_apply_virtual_material_to_derived_tallybuilds a derived copy of the existing virtual material test tally, applies the material and checks it against scaling the raw moments.Checklist