Skip to content

Conversation

@mvertens
Copy link
Collaborator

@mvertens mvertens commented Jan 7, 2026

Description of changes

This introduces the following new stream modules that are optional and can be added to the datamode streams already in place:

Specific notes

The following new modules have been added

  • datm_pres_aero_mod.F90, datm_pres_co2_mod.F90, datm_pres_ndep_mod.F90, datm_pres_o3_mod.F90

For datm_pres_ndep_mod.F90:

  • added new streams clim_1850_cmip7, clim_2000_cmip7, clim_2010_cmip7, and hist_cmip7 (currently these are only used by NorESM)
  • renamed the following streams
    • clim_1850 -> clim_1850_cmip6
    • clim_2000 -> clim_2000_cmip6
    • ciim_2010 -> clim_2010_cmip6
    • hist -> hist_cmip6
      by default for CESM, the following cmip6 streams will be used (whereas for NorESM, the cmip7 streams are used)
      Note that for the cmip7 data, no unit conversion is done whereas for the default cmip6 data the input data is converted from g/m2/sec to kg/m2/sec.

For datm_pres_co2_mod.F90:

  • added the following logic which will change answers for non-CPLHIST mode
  if (datamode == 'CPLHIST') then
       Sa_co2diag(:) = strm_Sa_co2diag(:)
       Sa_co2prog(:) = strm_Sa_co2prog(:)
  else
       ! This is intentional since we don't have any Sa_co2prog - but for now
       ! will set Sa_co2prog equal to Sa_co2diag
       Sa_co2diag(:) = strm_Sa_co2diag(:)
       Sa_co2prog(:) = strm_Sa_co2diag(:)
  end if

Also

  • removed references to water isotopes in DATM modules since this will be refactored in upcoming work.
  • removed style sheet references in all component namelist_definition_dXXX.xml and stream_definition_dXXX.xml since they are not used.

Contributors other than yourself, if any: None

CDEPS Issues Fixed: #370
The following tests now have correct values of o3 sent to

ERI_D_Ld11.ne30pg3_ne30pg3_mtn14.I1850Clm60FatesNocompSpinup.betzy_gnu.clm-FatesColdSpinupAD
ERS_D_Ld11.ne30pg3_ne30pg3_mtn14.I1850Clm60FatesNocompSpinup.betzy_intel.clm-FatesColdSpinup
SMS_D_Ld1000_P1536.ne30pg3_ne30pg3_mtn14.I1850Clm60FatesNocompSpinup.betzy_gnu.clm-FatesColdSpinup

Are there dependencies on other component PRs: This PR contains all the changes from CDEPS PR #368.

Are changes expected to change answers (bfb): bfb except for Sa_o3 bug fix and when DATM_PRES_CO2 is used.

Any User Interface Changes: add new options for DATM_PRESNDEP

Testing performed: Successfully carried out aux_cdeps_noresm, aux_blom_noresm and aux_clm_noresm with a corresonding PR in NorESMhub (see testing description in NorESMhub#27).

Hashes used for testing:

…am_pointer_2d to have optional arguments requirePointer and errmsg and set default values to nan
…lev_input' into feature/new_datm_optional_streams
@mvertens mvertens changed the title Feature/escomp new datm optional streams2 new datm optional streams Jan 7, 2026
@mvertens
Copy link
Collaborator Author

mvertens commented Jan 7, 2026

@billsacks - this new PR no longer has the changes from #368. I'm not sure what happened - but I could not get github to recognize what I was seeing in terms of my changes in my local directory.

Copy link
Member

@billsacks billsacks 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 very much for this work, @mvertens ! This is a very nice cleanup that removes some existing duplication and will make it easier to keep things in sync moving forward, e.g., if new datm modes are added that need these various shared streams.

I have one thought for a possible improvement below, but I see it as optional, so I'm marking this as approved and will let you decide if my thought seems worth doing.

@billsacks billsacks requested a review from fischer-ncar January 8, 2026 20:17
@billsacks
Copy link
Member

@fischer-ncar - I'm adding you as a reviewer here so you can formally approve once your testing (aux_cdeps?) looks good.

@jedwards4b - do you want to review this before we merge it? (No rush/pressure, just wondering if we should wait for your review.)

@billsacks billsacks removed the request for review from fischer-ncar January 8, 2026 20:55
@billsacks
Copy link
Member

@fischer-ncar - I'm adding you as a reviewer here so you can formally approve once your testing (aux_cdeps?) looks good.

Oh, I just saw the email from yesterday describing the testing - so no need for any further comments / approval, Chris.

Here is Chris's message for the record:

Here's the test results for aux_cdeps for PR #373
All of the namelist failures are from NORMALIZED: <stream_info name='presndep.1850'> != <stream_info name='presndep.1850_cmip6'>
Of course 1850 is either hist, 2000, or 2010 depending on the compset name.
FAIL SMS_Ld5.f10_f10_mg37.1850_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.1850_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.2000_DATM%CRUv7_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.2000_DATM%NLDAS2_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.2000_DATM%QIA_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.2010_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.2010_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.HIST_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.f10_f10_mg37.HIST_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.ne30pg3_g17.2000_DATM%IAF_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.ne30pg3_g17.2000_DATM%NYF_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5_P1.1x1_mexicocityMEX.2000_DATM%1PT_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.datm-1PT NLCOMP
FAIL SMS_Ld5.T62_t232.2000_DATM%NYF_SLND_DICE%IAF_DOCN%DOM_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.T62_t232.2000_DATM%NYF_SLND_DICE%SSMI_DOCN%DOM_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.TL319_t232.2000_DATM%JRA-1p4-2018_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ld5.TL319_t232.2000_DATM%JRA_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel NLCOMP
FAIL SMS_Ln5.f19_f19_mg17.2000_DATM%QIA_SLND_SICE_DOCN%DOM_SROF_SGLC_SWAV.derecho_intel NLCOMP
FAIL SMS_Ln5.f19_f19_mg17.2000_DATM%QIA_SLND_SICE_DOCN%SOMAQP_SROF_SGLC_SWAV.derecho_intel NLCOMP
FAIL SMS_Ln5.f19_f19_mg17.HIST_DATM%QIA_SLND_SICE_DOCN%DOM_SROF_SGLC_SWAV.derecho_intel NLCOMP
FAIL SMS_Ln9_P1.T42_T42.2000_DATM%QIA_SLND_SICE_DOCN%DOM_SROF_SGLC_SWAV.derecho_intel.datm-scam NLCOMP

For the baseline failures
FAIL SMS_Ld5.f10_f10_mg37.HIST_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.HIST_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.SSP126_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.SSP126_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.SSP245_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.SSP370_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ld5.f10_f10_mg37.SSP585_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF
FAIL SMS_Ln5.f19_f19_mg17.HIST_DATM%QIA_SLND_SICE_DOCN%DOM_SROF_SGLC_SWAV.derecho_intel BASELINE fischer_cdeps1_0_86: DIFF

Just as Bill believed, co2prog is the only answer changes.
SMS_Ld5.f10_f10_mg37.HIST_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 2.8432E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.HIST_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 2.8432E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.SSP126_DATM%CRUJRA2024_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 3.9995E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.SSP126_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 3.9995E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.SSP245_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 3.9995E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.SSP370_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 3.9995E+02 NORMALIZED 2.0000E+00
SMS_Ld5.f10_f10_mg37.SSP585_DATM%GSWP3v1_SLND_SICE_SOCN_SROF_SGLC_SWAV_SESP.derecho_intel.GC.pr_373.cpl.hi.0001-01-06-00000.nc.cprnc.out: RMS atmImp_Sa_co2prog 3.9995E+02 NORMALIZED 2.0000E+00
SMS_Ln5.f19_f19_mg17.HIST_DATM%QIA_SLND_SICE_DOCN%DOM_SROF_SGLC_SWAV.derecho_intel.GC.pr_373.cpl.hi.0001-01-01-09000.nc.cprnc.out: RMS atmImp_Sa_co2prog 2.8432E+02 NORMALIZED 2.0000E+00

So I would say the tests look good.

@billsacks
Copy link
Member

I'm removing @jedwards4b as reviewer since he's out of the office this week, and he approved the earlier iteration of this (#369 )

@billsacks billsacks removed the request for review from jedwards4b January 8, 2026 20:59
@billsacks billsacks merged commit d9afc04 into ESCOMP:main Jan 8, 2026
1 check passed
@mvertens mvertens deleted the feature/escomp_new_datm_optional_streams2 branch January 9, 2026 17:35
billsacks added a commit to mvertens/CDEPS that referenced this pull request Jan 17, 2026
The line break after the last valid value (cplhist) led it to be
interpreted as "cplhist\n", so "cplhist" was determined to be not a
valid value. So apparently we can't have a newline after the last valid
value; I'm not sure about having newlines in other places, but it looked
funny to have newlines in other places and not after the last one, so
I'm just removing all newlines here.

This reverts a change that was made as part of
ESCOMP#373
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.

o3 not sent by datm even though flds_preso3 = .true.

2 participants