forked from mom-ocean/MOM6
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
+Add optional conversion argument to register_field
Added the option to rescale variables as they are written out via MOM_io_file. These involved adding optional conversion arguments to register_field_infra and register_field_nc, which are then stored in a new element in the MOM_field type, and use the conversion factors to unscale variables before they are written in the ten write_field routines in MOM_io_file. The new optional arguments to register_field are used in MOM_create_file, taking their values from the vardesc types sent to this routine. This commit also alters modify_vardesc to store the value of the conversion optional argument in the conversion element of the vardesc type. Also modified query_vardesc so that the conversion factor is returned via the conversion optional argument. These steps had been intended when these optional arguments were first added, but for some reason they had not actually been used. The conversion values stored in a vardesc type are also now used in the register_diag_field call in ocean_register_diag. However, it does not appear that ocean_register_diag is actually used anymore, so it might be a candidate for deletion. All answers are bitwise identical, but there are new optional arguments to publicly visible routines.
- Loading branch information
1 parent
a4d13e8
commit f82369f
Showing
3 changed files
with
113 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters