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

Create ESMF field attributes using the same kind as field data values #236

Merged
merged 3 commits into from
Jan 25, 2023

Conversation

DusanJovic-NOAA
Copy link
Contributor

Description

This PR updates add_field_to_bundle subroutine in driver/fvGFS/fv_nggps_diag.F90. The values used for esmf field attributes (_FillValue and missing_value) must be the same real kind as the field data values, in this case REAL(4) in order to avoid type mismatch checks in PIO library which is used by ESMF I/O module.

See: ufs-community/ufs-weather-model#1564

How Has This Been Tested?

Full usf-weather-model regression test on Hera.

Checklist:

Please check all whether they apply or not

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules

@laurenchilutti
Copy link
Contributor

HI @DusanJovic-NOAA is there anyone from EMC or the UFS community that you would like to review this?

@junwang-noaa
Copy link
Collaborator

junwang-noaa commented Jan 13, 2023

@DusanJovic-NOAA Since the data buffer is in real(4) for dyn history outputs, can we just change line #106 to real(4)?

@DusanJovic-NOAA
Copy link
Contributor Author

@DusanJovic-NOAA Since the data buffer is in real(4) for dyn history outputs, can we just change line #106 to real(4)?

missing_value is also used in other subroutines like hailcast_init and register_diag_field and the corresponding dummy arguments are declared as default real (either 4-byte or 8-byte depending on the compile options). So if we explicitly declare missing_value as real(4) that will introduce argument mismatch.

@junwang-noaa
Copy link
Collaborator

I see. The changes look good to me.

@jkbk2004
Copy link

@laurenchilutti @bensonr all tests at ufs-community/ufs-weather-model#1566 are done. Can you go ahead to merge in this pr?

@laurenchilutti laurenchilutti merged commit 3f7b57a into NOAA-GFDL:dev/emc Jan 25, 2023
@DusanJovic-NOAA DusanJovic-NOAA deleted the missing_value_r4 branch January 26, 2023 14:45
BinLiu-NOAA pushed a commit to NOAA-EMC/GFDL_atmos_cubed_sphere that referenced this pull request Mar 20, 2023
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.

5 participants