-
Notifications
You must be signed in to change notification settings - Fork 60
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
Bug fix for categorize_axes causing crash #221
Bug fix for categorize_axes causing crash #221
Conversation
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 for this suggested fix. I see how this would address the specific case highlighted in #220, but if the variable in question does not have either the "cartesian_axis" attribute or the "axis" attribute, the variable cartesian
will likely either be uninitialized or use an incorrect value from a previous dimension when it is used in line 1578. (Cartesian was never used without first being set in the previous version of the code.)
Please modify this code either to set cartesian
before it is used, or avoid using it if it is not being set by one of the get_variable_attribute()
calls.
- The subroutine categorize_axes cannot find the axes in ice restart files and gives warnings WARNING from PE 0: categorize_axes: Failed to identify x- and y- axes in the axis list (xaxis_1, yaxis_1, Time) of a variable being read from INPUT/ice_model.res.nc - This leads to an incorrect initializations and a subsequent sat.vap.press.overflow crash when using infra/FMS2 - Same experiment runs fine with infra/FMS1 - After the fix the infra/FMS1 and infra/FMS2 answers are bitwise identical
- The subroutine categorize_axes cannot find the axes in ice restart files and gives warnings WARNING from PE 0: categorize_axes: Failed to identify x- and y- axes in the axis list (xaxis_1, yaxis_1, Time) of a variable being read from I NPUT/ice_model.res.nc - This leads to an incorrect initializations and a subsequent sat.vap.press.overflow crash when using infra/FMS2 - Same experiment runs fine with infra/FMS1 - After the fix the infra/FMS1 and infra/FMS2 answers are bitwise identical
Added a line initializing the string Cartesian to a blank string in categorize_axes, so that it not be uninitialized when it is used a few lines later.
8040676
to
00324fc
Compare
Codecov Report
@@ Coverage Diff @@
## dev/gfdl #221 +/- ##
============================================
- Coverage 37.23% 37.19% -0.04%
============================================
Files 263 263
Lines 73060 72972 -88
Branches 13605 13589 -16
============================================
- Hits 27201 27144 -57
+ Misses 40841 40819 -22
+ Partials 5018 5009 -9
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
Gaea regression: https://gitlab.gfdl.noaa.gov/ogrp/MOM6/-/pipelines/17298 ✔️ |
Closes #220
The subroutine categorize_axes cannot find the axes in ice restart files and gives warnings
WARNING from PE 0: categorize_axes: Failed to identify x- and y- axes in the axis list (xaxis_1, yaxis_1, Time) of a variable being read fr
om I
NPUT/ice_model.res.nc
This leads to an incorrect initializations and a subsequent sat.vap.press.overflow crash when using
infra/FMS2
Same experiment runs fine with infra/FMS1
After the fix the infra/FMS1 and infra/FMS2 answers are bitwise
identical
Thanks @uramirez8707 for suggesting this fix.