feat: Add logic to copy prognostics from forecaster to downscaler at overlapping timesteps - #219
Draft
MicheleCattaneo wants to merge 8 commits into
Draft
feat: Add logic to copy prognostics from forecaster to downscaler at overlapping timesteps#219MicheleCattaneo wants to merge 8 commits into
MicheleCattaneo wants to merge 8 commits into
Conversation
MicheleCattaneo
marked this pull request as draft
July 20, 2026 08:10
MicheleCattaneo
marked this pull request as ready for review
July 20, 2026 15:59
MicheleCattaneo
marked this pull request as draft
July 22, 2026 09:48
Contributor
Author
|
As discussed with @hlasco, we will try to move the logic in an anemoi plugin. This PR will then mostly reduce to a config change and an added dependency on the plugin for the inference environment. |
Contributor
Author
|
MeteoSwiss/anemoi-plugins-meteoswiss#33 Introduces the plugin |
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.
Adds an optional opt-in
copy_prognostic_from_forecasterflag for temporal downscalers.When enabled on a downscaler run that has a forecaster parent, overwrite the prognostic variables at the overlap steps in the downscaler's GRIB with the forecaster's values, so forecaster-alone and forecaster+downscaler metrics agree at multiples of the forecaster stride. Diagnostics (typically tp) are left untouched. It's going to be off by default, maintaining the current behavior.
Everything is defined from the downscaler's anemoi.json:
config.training.explicit_times({input:[0,6], target:[1..6]}):overlap_offsets = set(input) ∩ set(target) (={6}),window stride = max(input) (=6); global overlap steps = multiples of the stride within the run's steps. If the intersection is empty → log "no overlap" and no-op.data_indices.data.data.output.prognostic. output.diagnostic (such as['tp']) is never copied.TODO: