Skip to content

Add qsat_scaled_names to SharedGlobalMeanRemovalConfig#1256

Open
mcgibbon wants to merge 2 commits into
mainfrom
feature/qsat-scaled-shared-global-mean-removal
Open

Add qsat_scaled_names to SharedGlobalMeanRemovalConfig#1256
mcgibbon wants to merge 2 commits into
mainfrom
feature/qsat-scaled-shared-global-mean-removal

Conversation

@mcgibbon

Copy link
Copy Markdown
Contributor

The shared global mean removal transform shifts temperature-like fields by a per-sample offset, but humidity-like fields scale multiplicatively with saturation vapor pressure rather than shifting additively with temperature. This PR adds a qsat_scaled_names option to SharedGlobalMeanRemovalConfig so humidity fields can be scaled by the ratio qsat(reference_mean) / qsat(sample_mean) in forward_transform and divided back in inverse_transform, using the Bolton (1980) saturation vapor pressure formula. The default (empty list) leaves existing behavior unchanged.

Changes:

  • fme.core.humidity.bolton_saturation_vapor_pressure: new helper computing Bolton (1980) saturation vapor pressure over liquid water (hPa) from temperature in Kelvin

  • fme.core.step.global_mean_removal.SharedGlobalMeanRemovalConfig / SharedGlobalMeanRemoval: new qsat_scaled_names field; listed fields are multiplied by the per-sample qsat ratio in forward_transform and unscaled in inverse_transform, with name validation warnings matching field_names

  • Tests added

  • If dependencies changed, "deps only" image rebuilt and "latest_deps_only_image.txt" file updated

mcgibbon added 2 commits June 8, 2026 19:47
Standalone physics helper exposing the Bolton (1980) formula for
saturation vapor pressure over liquid water given temperature in
Kelvin.  Will be used by an upcoming extension to
SharedGlobalMeanRemovalConfig.
Listed fields are multiplied by qsat(reference_mean) /
qsat(sample_mean_of_reference_field) in forward_transform and
divided back in inverse_transform, where qsat is the Bolton (1980)
saturation vapor pressure as a function of temperature in Kelvin.
This is intended for humidity-like fields whose saturation value
scales with the reference temperature; the per-sample ratio brings
them closer to a temperature-invariant input distribution.

The new list is independent of ``field_names``: temperature-like
fields still get the additive offset; humidity-like fields get the
multiplicative qsat ratio.  Default empty preserves existing
behavior.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant