adding trigger to mgxs convert#3925
Draft
shimwell wants to merge 3 commits into
Draft
Conversation
…ation # Conflicts: # openmc/model/model.py
convert_to_multigroup now defaults nparticles=None ("auto"). In auto mode the
continuous-energy generation run is no longer given a fixed, guessed particle
count; a relative-error trigger (ignore_zeros=True) is attached to the
cross-section tallies via Library.tally_trigger, so the run extends batches
until the group constants are statistically converged, bounded by an internal
max_batches cap. Passing an explicit integer keeps the previous fixed behaviour.
The convergence target, seed particles-per-batch and max-batches cap are
internal constants rather than new user-facing arguments, so the public API
gains no knobs.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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
At Physor 2026 an chatting with @jtramm and @pshriwise about making generation of multigroup use a trigger to allow it to end earlier if the reaction rates all meet the trigger relative error value. At the time it sounded like a good idea but in practice it appears to have enlarged the api interface to users which I was trying to avoid. I wanted to make this a draft PR just to show @jtramm and @pshriwise that I tried.
Fixes # (issue)
Checklist