Repository navigation
Add optional input clamping and non-negative heat flux clipping to TGLFNN-UKAEA. - #2970
Open
copybara-service[bot] wants to merge 1 commit into
Open
copybara-service[bot] wants to merge 1 commit into
copybara-service[bot] wants to merge 1 commit into
Conversation
…LFNN-UKAEA. - Add static `clip_inputs` (default `False`, matching QLKNN) and validated `clip_margin` (default `0.95`, in `(0, 1]` without inverting machine training bounds) to `TGLFNNukaeaTransportModelConfig` and `RuntimeParams`. Training input bounds come from Zanisi et al.: the Table 1 hypercube ranges for `multimachine`, and the support of the Figure 2 training distributions for `step`. - Add static `clip_heat_fluxes` (default `False`) to clip turbulent ion and electron heat fluxes (`efi_gb`, `efe_gb`) to be non-negative (as in QLKNN) while preserving signed particle flux (`pfi_gb`). - Add unit tests covering input range alignment, `clip_inputs` bounds/margin behavior, `clip_margin` validation, and `call_implementation` clipping (including `jax.jit` compilation with static flags). PiperOrigin-RevId: 1031188037
copybara-service
Bot
force-pushed
the
test_1031188037
branch
from
November 30, 2026 15:13
46e6bca to
58a658c
Compare
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.
Add optional input clamping and non-negative heat flux clipping to TGLFNN-UKAEA.
clip_inputs(defaultFalse, matching QLKNN) and validatedclip_margin(default0.95, in(0, 1]without inverting machine trainingbounds) to
TGLFNNukaeaTransportModelConfigandRuntimeParams. Traininginput bounds come from Zanisi et al.: the Table 1 hypercube ranges for
multimachine, and the support of the Figure 2 training distributions forstep.clip_heat_fluxes(defaultFalse) to clip turbulent ion andelectron heat fluxes (
efi_gb,efe_gb) to be non-negative (as in QLKNN)while preserving signed particle flux (
pfi_gb).clip_inputsbounds/marginbehavior,
clip_marginvalidation, andcall_implementationclipping(including
jax.jitcompilation with static flags).