Skip to content
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

Merged
merged 4 commits into from
Oct 31, 2022

Conversation

nikizadehgfdl
Copy link

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.

Copy link
Member

@Hallberg-NOAA Hallberg-NOAA left a 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.

nikizadehgfdl and others added 3 commits October 28, 2022 16:36
- 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.
@codecov
Copy link

codecov bot commented Oct 28, 2022

Codecov Report

Merging #221 (7609385) into dev/gfdl (bc01d95) will decrease coverage by 0.03%.
The diff coverage is n/a.

@@             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     
Impacted Files Coverage Δ
src/core/MOM_PressureForce_FV.F90 32.87% <0.00%> (-9.24%) ⬇️

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@marshallward
Copy link
Member

Gaea regression: https://gitlab.gfdl.noaa.gov/ogrp/MOM6/-/pipelines/17298 ✔️

@marshallward marshallward merged commit e26d8da into NOAA-GFDL:dev/gfdl Oct 31, 2022
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.

CM4 crashes due to incorrect initialization after reading old ice restart file when compiled with infra/FMS2
3 participants