-
Notifications
You must be signed in to change notification settings - Fork 245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Diagnostic scaling fixes #991
Diagnostic scaling fixes #991
Conversation
This patch adds and fixes the scaling factors for several diagnostics.
This patch fixes an issue in the time scalings of the tendencies in MOM_diagnostics, where the timestep (dt) was not being scaled, and was only corrected in some of the variables. This patch also passes through the scaling of KE and dKE_dt onto the diagnostic conversion factors.
Finished the rescaling of the layer KE tendency diagnostics, which are all now passing the diagnostic checksum scaling tests.
Codecov Report
@@ Coverage Diff @@
## dev/gfdl #991 +/- ##
============================================
- Coverage 43.24% 43.24% -0.01%
============================================
Files 213 213
Lines 62214 62214
============================================
- Hits 26905 26903 -2
- Misses 35309 35311 +2
Continue to review full report at Codecov.
|
This patch fixes the scaling of the diagnostic parameters in the [uv]hbt and [uv]hbt_hifreq transport diagnostics.
… into tendency_scaling
Might as well keep this PR open to gather up other incoming scaling fixes. |
Length scaling for global averaging is no longer required and has been removed. This has fixed the dimensional scaling of any diagnostics using this function.
Diagnostics of diffusive tracer fluxes (*_diff[xy], *_diff[xy]_2d) were not scaling due to issues with the Coef_x term, which was in units of L2 while the tracer itself was in units of m2. Although the Coef_x term was being de-scaled to meters, the cumulative sum was failing to reproduce for many tracers, either being reverted (in temp) or failing to reproduce all bits (in salt). We resolve this by re-defining the diffusive flux terms as H L2 s-1, rather than H m2 s-1, and moving the scaling to the final conversion factor, which restored reproducibility of all tracers. This patch contains an API change. We have added the unit scaling struct (US) to the register_tracer_diagnostic function.
Dimensional scaling factor was added to the MEKE_src diagnostic, fixing the rescaling reproducibility.
This patch fixes a bug in the registration of CAu, where the conversion argument had been included in the string of the dimensions of the diagnostic registration. The units of various accelerations have also been changed from 'meter second-2' to 'm s-2' for consistent with the rest of the model.
This patch fixes the dimensional scaling of the pre-ALE u and v diagnostics, and the uhml and vhml mixed layer diagnostics.
Most of the low hanging fruit related to dimensional scaling has been fixed in this PR, so this should be OK to merge after review. Gaea regression testing: https://gitlab.gfdl.noaa.gov/ogrp/MOM6/pipelines/8857 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you, @marshallward, for these corrections to the dimensional rescaling of the diagnostic output. The fact that we can now systematically catch such missing or incorrect scaling factors for MOM6 diagnostics is a significant advance for the MOM6 code.
This PR should be merged in once the corresponding MOM6-examples pipeline test has passed.
Regression tests have passed, so this is ready to merge. This doesn't address all of the scaling problems, but has resolved the majority of them. |
This patch fixes an issue in the time scalings of the tendencies in MOM_diagnostics, where the timestep (
dt
) was not being scaled, and was only corrected in some of the variables.This patch also passes through the scaling of the KE and the layer KE tendency diagnostic conversions.