-
Notifications
You must be signed in to change notification settings - Fork 368
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
Removed functionality from MPAS framework that overwrites attributes #4987
Removed functionality from MPAS framework that overwrites attributes #4987
Conversation
Removed functionality from MPAS framework that overwrites Registry attributes with stream file attributes. This change prevents input files from overwriting CF-compliant units in Registry with non-CF compliant ones in the input file.
@akturner, thank s a lot for making this PR. I'd like to test it with some other CF changes from the Hackathon, which I'm still working on. It would be good to test with @darincomeau's units changes, too. |
@xylar how are those tests going? |
@rljacob, it's not. I have too much else on my plate at the moment. |
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.
@akturner, sorry for the delay. I tested this with standalone MPAS-Ocean in compass (in a test E3SM branch where I also merged #5026 and #5027), and it worked like a charm! I used an initial condition from before, where the units for salinity are:
double salinity(Time, nCells, nVertLevels) ;
salinity:long_name = "salinity" ;
salinity:units = "grams salt per kilogram seawater" ;
The resulting output is:
double salinity(Time, nCells, nVertLevels) ;
salinity:long_name = "salinity grams salt per kilogram seawater"
;
salinity:units = "1.e-3" ;
as desired.
In time series stats daily, I also see:
double timeDaily_avg_activeTracers_salinity(Time, nCells, nVertLevels) ;
timeDaily_avg_activeTracers_salinity:long_name = "salinity grams salt per kilogram seawater" ;
timeDaily_avg_activeTracers_salinity:units = "1.e-3" ;
@mark-petersen and @matthewhoffman, please give this a try as well when you can. |
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.
I agree, this works as expected based on @xylar's test above. Thanks.
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.
I'm approving by inspection and the testing that Xylar and Mark did. This is a valuable change.
Remove functionality from MPAS framework that overwrites attributes Removes functionality from MPAS framework that overwrites Registry attributes with stream file attributes. This change prevents input files from overwriting CF-compliant units in Registry with non-CF compliant ones in the input file. Fixes #4986 [BFB]
passes sanity testing, merged to next |
merged to master |
Removed functionality from MPAS framework that overwrites Registry attributes with stream file attributes. This change prevents input files from overwriting CF-compliant units in Registry with non-CF compliant ones in the input file.
Fixes #4986
[BFB]