Skip to content

Commit f84ee6d

Browse files
committed
Merge tag 'alpha-ctsm5.4.CMIP7.19.ctsm5.3.085' into WhatsNewinCTSM54_release_notes
Update ctsm5.4 alpha branch to ctsm5.3.085 This just updates the ctsm5.4 alpha branch to the latest master. This is the last planned update on the branch before moving to master, as ctsm5.4.0000.
2 parents c24c69b + 3cfe210 commit f84ee6d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

44 files changed

+2245
-280
lines changed

.github/workflows/docs-build-and-deploy.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,10 @@ concurrency:
3333
jobs:
3434

3535
build-and-deploy:
36+
37+
# Only run on upstream repository
38+
if: ${{ github.repository == 'ESCOMP/CTSM' }}
39+
3640
environment:
3741
name: github-pages
3842
url: ${{ steps.deployment.outputs.page_url }}

.gitmodules

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
[submodule "fates"]
2929
path = src/fates
3030
url = https://github.com/NGEET/fates
31-
fxtag = sci.1.87.2_api.41.0.0
31+
fxtag = sci.1.88.0_api.42.0.0
3232
fxrequired = AlwaysRequired
3333
# Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed
3434
fxDONOTUSEurl = https://github.com/NGEET/fates
@@ -100,7 +100,7 @@ fxDONOTUSEurl = https://github.com/ESCOMP/CDEPS.git
100100
[submodule "share"]
101101
path = share
102102
url = https://github.com/ESCOMP/CESM_share
103-
fxtag = share1.1.9
103+
fxtag = share1.1.15
104104
fxrequired = ToplevelRequired
105105
# Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed
106106
fxDONOTUSEurl = https://github.com/ESCOMP/CESM_share

bld/CLMBuildNamelist.pm

Lines changed: 62 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3770,48 +3770,94 @@ sub setup_logic_c_isotope {
37703770
$log->warning("use_c14 is ONLY scientifically validated with the bgc=BGC configuration" );
37713771
}
37723772
}
3773+
my $use_c14_bombspike = $nl->get_value('use_c14_bombspike');
3774+
my $stream_fldfilename_atm_c14 = $nl->get_value('stream_fldfilename_atm_c14');
3775+
my $atm_c14_filename = $nl->get_value('atm_c14_filename');
37733776
if ( &value_is_true($use_c14) ) {
37743777
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'use_c14_bombspike', 'use_c14'=>$use_c14 );
3775-
my $use_c14_bombspike = $nl->get_value('use_c14_bombspike');
3778+
$use_c14_bombspike = $nl->get_value('use_c14_bombspike');
37763779
if ( &value_is_true($use_c14_bombspike) ) {
3777-
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'atm_c14_filename',
3778-
'use_c14'=>$use_c14, 'use_cn'=>$nl_flags->{'use_cn'}, 'use_c14_bombspike'=>$nl->get_value('use_c14_bombspike'),
3779-
'ssp_rcp'=>$nl_flags->{'ssp_rcp'} );
3780+
if ( defined($stream_fldfilename_atm_c14) ) {
3781+
setup_logic_c14_streams($opts, $nl_flags, $definition, $defaults, $nl);
3782+
} else {
3783+
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'atm_c14_filename',
3784+
'use_c14'=>$use_c14, 'use_cn'=>$nl_flags->{'use_cn'}, 'use_c14_bombspike'=>$nl->get_value('use_c14_bombspike'),
3785+
'ssp_rcp'=>$nl_flags->{'ssp_rcp'} );
3786+
}
3787+
$stream_fldfilename_atm_c14 = $nl->get_value('stream_fldfilename_atm_c14');
3788+
$atm_c14_filename = $nl->get_value('atm_c14_filename');
3789+
if ( defined($stream_fldfilename_atm_c14) && defined($atm_c14_filename) ) {
3790+
$log->fatal_error("Both stream_fldfilename_atm_c14 and atm_c14_filename set, only one should be set");
3791+
}
37803792
}
37813793
} else {
3782-
if ( defined($nl->get_value('use_c14_bombspike')) ||
3783-
defined($nl->get_value('atm_c14_filename')) ) {
3784-
$log->fatal_error("use_c14 is FALSE and use_c14_bombspike or atm_c14_filename set");
3794+
if ( defined($use_c14_bombspike) ||
3795+
defined($stream_fldfilename_atm_c14) ||
3796+
defined($atm_c14_filename) ) {
3797+
$log->fatal_error("use_c14 is FALSE and use_c14_bombspike, stream_fldfilename_atm_c14 or atm_c14_filename set");
37853798
}
37863799
}
3800+
my $use_c13_timeseries = $nl->get_value('use_c13_timeseries');
3801+
my $stream_fldfilename_atm_c13 = $nl->get_value('stream_fldfilename_atm_c13');
3802+
my $atm_c13_filename = $nl->get_value('atm_c13_filename');
37873803
if ( &value_is_true($use_c13) ) {
37883804
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'use_c13_timeseries', 'use_c13'=>$use_c13 );
3789-
my $use_c13_timeseries = $nl->get_value('use_c13_timeseries');
3805+
$use_c13_timeseries = $nl->get_value('use_c13_timeseries');
37903806
if ( &value_is_true($use_c13_timeseries) ) {
3791-
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'atm_c13_filename',
3792-
'use_c13'=>$use_c13, 'use_cn'=>$nl_flags->{'use_cn'}, 'use_c13_timeseries'=>$nl->get_value('use_c13_timeseries'),
3793-
'ssp_rcp'=>$nl_flags->{'ssp_rcp'} );
3807+
if ( defined($stream_fldfilename_atm_c13) ) {
3808+
setup_logic_c13_streams($opts, $nl_flags, $definition, $defaults, $nl);
3809+
} else {
3810+
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'atm_c13_filename',
3811+
'use_c13'=>$use_c13, 'use_cn'=>$nl_flags->{'use_cn'}, 'use_c13_timeseries'=>$nl->get_value('use_c13_timeseries'),
3812+
'ssp_rcp'=>$nl_flags->{'ssp_rcp'} );
3813+
}
3814+
$stream_fldfilename_atm_c13 = $nl->get_value('stream_fldfilename_atm_c13');
3815+
$atm_c13_filename = $nl->get_value('atm_c13_filename');
3816+
if ( defined($stream_fldfilename_atm_c13) && defined($atm_c13_filename) ) {
3817+
$log->fatal_error("Both stream_fldfilename_atm_c13 and atm_c13_filename set, only one should be set");
3818+
}
37943819
}
37953820
} else {
37963821
if ( defined($nl->get_value('use_c13_timeseries')) ||
3822+
defined($nl->get_value('stream_fldfilename_atm_c13')) ||
37973823
defined($nl->get_value('atm_c13_filename')) ) {
3798-
$log->fatal_error("use_c13 is FALSE and use_c13_timeseries or atm_c13_filename set");
3824+
$log->fatal_error("use_c13 is FALSE and use_c13_timeseries, stream_fldfilename_atm_c13 or atm_c13_filename set");
37993825
}
38003826
}
38013827
} else {
38023828
if ( &value_is_true($use_c13) ||
38033829
&value_is_true($use_c14) ||
38043830
&value_is_true($nl->get_value('use_c14_bombspike')) ||
38053831
defined($nl->get_value('atm_c14_filename')) ||
3832+
defined($nl->get_value('stream_fldfilename_atm_c14')) ||
38063833
&value_is_true($nl->get_value('use_c13_timeseries')) ||
3807-
defined($nl->get_value('atm_c13_filename')) ) {
3834+
defined($nl->get_value('atm_c13_filename')) ||
3835+
defined($nl->get_value('stream_fldfilename_atm_c13')) ) {
38083836
$log->fatal_error("bgc=sp and C isotope namelist variables were set, both can't be used at the same time");
38093837
}
38103838
}
38113839
}
38123840

38133841
#-------------------------------------------------------------------------------
38143842

3843+
sub setup_logic_c13_streams {
3844+
my ($opts, $nl_flags, $definition, $defaults, $nl) = @_;
3845+
#
3846+
# C13 stream file settings
3847+
#
3848+
}
3849+
3850+
#-------------------------------------------------------------------------------
3851+
3852+
sub setup_logic_c14_streams {
3853+
my ($opts, $nl_flags, $definition, $defaults, $nl) = @_;
3854+
#
3855+
# C14 stream file settings
3856+
#
3857+
}
3858+
3859+
#-------------------------------------------------------------------------------
3860+
38153861
sub setup_logic_nitrogen_deposition {
38163862
my ($opts, $nl_flags, $definition, $defaults, $nl) = @_;
38173863

@@ -5334,6 +5380,9 @@ sub write_output_files {
53345380
push @groups, "clm_canopy_inparm";
53355381
push @groups, "prigentroughness";
53365382
push @groups, "zendersoilerod";
5383+
if ( &value_is_true($nl_flags->{'use_cn'}) ) {
5384+
push @groups, "carbon_isotope_streams";
5385+
}
53375386
if (remove_leading_and_trailing_quotes($nl->get_value('snow_cover_fraction_method')) eq 'SwensonLawrence2012') {
53385387
push @groups, "scf_swenson_lawrence_2012_inparm";
53395388
}

bld/namelist_files/namelist_definition_ctsm.xml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1806,6 +1806,51 @@ Mapping method from Nitrogen deposition input file to the model resolution
18061806
none = no interpolation
18071807
</entry>
18081808

1809+
<!-- ========================================================================================
1810+
Carbon isotope streams Namelist (only used when use_c13/use_c14 is on and bgc=cn or bgc)
1811+
(Atmospheric C13 and C14 ratios in terms of a delta)
1812+
======================================================================================== -->
1813+
1814+
<entry id="stream_year_first_atm_c14" type="integer" category="datasets"
1815+
group="carbon_isotope_streams" valid_values="" >
1816+
First year to loop over for atmospheric C14 isotope delta data
1817+
</entry>
1818+
1819+
<entry id="stream_year_last_atm_c14" type="integer" category="datasets"
1820+
group="carbon_isotope_streams" valid_values="" >
1821+
Last year to loop over for data atmospheric C14 isotope delta data
1822+
</entry>
1823+
1824+
<entry id="stream_model_year_align_atm_c14" type="integer" category="datasets"
1825+
group="carbon_isotope_streams" valid_values="" >
1826+
Simulation year that aligns with stream_year_first_atm_c14 value
1827+
</entry>
1828+
1829+
<entry id="stream_fldfilename_atm_c14" type="char*512" category="datasets"
1830+
input_pathname="abs" group="carbon_isotope_streams" valid_values="" >
1831+
Filename of input stream data for atmospheric C14 isotope delta data
1832+
</entry>
1833+
1834+
<entry id="stream_year_first_atm_c13" type="integer" category="datasets"
1835+
group="carbon_isotope_streams" valid_values="" >
1836+
First year to loop over for atmospheric C13 isotope delta data
1837+
</entry>
1838+
1839+
<entry id="stream_year_last_atm_c13" type="integer" category="datasets"
1840+
group="carbon_isotope_streams" valid_values="" >
1841+
Last year to loop over for data atmospheric C13 isotope delta data
1842+
</entry>
1843+
1844+
<entry id="stream_model_year_align_atm_c13" type="integer" category="datasets"
1845+
group="carbon_isotope_streams" valid_values="" >
1846+
Simulation year that aligns with stream_year_first_atm_c13 value
1847+
</entry>
1848+
1849+
<entry id="stream_fldfilename_atm_c13" type="char*512" category="datasets"
1850+
input_pathname="abs" group="carbon_isotope_streams" valid_values="" >
1851+
Filename of input stream data for atmospheric C13 isotope delta data
1852+
</entry>
1853+
18091854
<!-- ======================================================================================== -->
18101855
<!-- Prigent roughness stream -->
18111856
<!-- ======================================================================================== -->

bld/unit_testers/build-namelist_test.pl

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ sub cat_and_create_namelistinfile {
163163
#
164164
# Figure out number of tests that will run
165165
#
166-
my $ntests = 3396;
166+
my $ntests = 3402;
167167

168168
if ( defined($opts{'compare'}) ) {
169169
$ntests += 2061;
@@ -821,6 +821,30 @@ sub cat_and_create_namelistinfile {
821821
namelst=>"use_c14_bombspike=.true.",
822822
phys=>"clm5_0",
823823
},
824+
"bombspike file and stream" =>{ options=>"-bgc bgc -envxml_dir .",
825+
namelst=>"use_c14=TRUE use_c14_bombspike=.true. stream_fldfilename_atm_c14='/dev/null', atm_c14_filename='/dev/null'",
826+
phys=>"clm6_0",
827+
},
828+
"c13 file and stream" =>{ options=>"-bgc bgc -envxml_dir .",
829+
namelst=>"use_c13_timeseries=.true. stream_fldfilename_atm_c13='/dev/null', atm_c13_filename='/dev/null'",
830+
phys=>"clm6_0",
831+
},
832+
"c13 off, but stream" =>{ options=>"-bgc bgc -envxml_dir .",
833+
namelst=>"use_c13=.false. stream_fldfilename_atm_c13='/dev/null'",
834+
phys=>"clm6_0",
835+
},
836+
"c14 off, but stream" =>{ options=>"-bgc bgc -envxml_dir .",
837+
namelst=>"use_c14=.false. stream_fldfilename_atm_c14='/dev/null'",
838+
phys=>"clm6_0",
839+
},
840+
"sp, but c13 stream" =>{ options=>"-bgc sp -envxml_dir .",
841+
namelst=>"stream_fldfilename_atm_c13='/dev/null'",
842+
phys=>"clm6_0",
843+
},
844+
"sp, but c14 stream" =>{ options=>"-bgc sp -envxml_dir .",
845+
namelst=>"stream_fldfilename_atm_c14='/dev/null'",
846+
phys=>"clm6_0",
847+
},
824848
"lightres no cn" =>{ options=>"-bgc sp -envxml_dir . -light_res 360x720",
825849
namelst=>"",
826850
phys=>"clm5_0",

cime_config/testdefs/ExpectedTestFails.xml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -247,6 +247,15 @@
247247

248248
<!-- fates test suite failures -->
249249

250+
<!-- This is commented out because cime currently does NOT allow longnames in the XML in the XSD for this file
251+
<test name="ERS_D_Ld30.f45_f45_mg37.HIST_DATM%CRUv7_CLM50%FATES_SICE_SOCN_SROF_SGLC_SWAV_SESP.izumi_nag.clm-FatesColdLandUse">
252+
<phase name="RUN">
253+
<status>FAIL</status>
254+
<issue>#3500</issue>
255+
</phase>
256+
</test>
257+
-->
258+
250259
<test name="ERS_D_Ld30.f45_f45_mg37.I2000Clm50FatesCruRsGs.izumi_nag.clm-FatesColdLUH2">
251260
<phase name="RUN">
252261
<status>FAIL</status>

cime_config/testdefs/testlist_clm.xml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,25 @@
195195
<option name="comment">Testing that a initial condition file with an missing urban landunit will be filled with another urban landunit</option>
196196
</options>
197197
</test>
198+
199+
<test name="SMS_Ly3" grid="f10_f10_mt232" compset="IHistClm60BgcCropCrujra" testmods="clm-ciso_monthly_2013Start">
200+
<machines>
201+
<machine name="derecho" compiler="intel" category="aux_clm"/>
202+
</machines>
203+
<options>
204+
<option name="wallclock">01:40:00</option>
205+
<option name="comment">Testing a few years with CMIP6 carbon isotopes</option>
206+
</options>
207+
</test>
208+
<test name="SMS_Ly3" grid="f10_f10_mt232" compset="IHistClm60BgcCropCrujra" testmods="clm-ciso_cmip7_monthly_2013Start">
209+
<machines>
210+
<machine name="derecho" compiler="intel" category="aux_clm"/>
211+
</machines>
212+
<options>
213+
<option name="wallclock">01:40:00</option>
214+
<option name="comment">Testing a few years with CMIP7 carbon isotopes</option>
215+
</options>
216+
</test>
198217
<test name="ERS_D_Ld9" grid="ne30pg3_t232" compset="I1850Clm60BgcCropG" testmods="clm/clm60cam7LndTuningMode">
199218
<machines>
200219
<machine name="derecho" compiler="intel" category="aux_clm"/>
@@ -4445,6 +4464,7 @@
44454464
<test name="FUNITCTSM_P1x1" grid="f10_f10_mg37" compset="I2000Clm50Sp">
44464465
<machines>
44474466
<machine name="derecho" compiler="intel" category="aux_clm"/>
4467+
<machine name="derecho" compiler="intel" category="prealpha"/>
44484468
<machine name="izumi" compiler="intel" category="aux_clm"/>
44494469
</machines>
44504470
<options>
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../ciso_monthly_2013Start
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
stream_fldfilename_atm_c13 = '$DIN_LOC_ROOT/lnd/clm2/isotopes/ctsmforc.Graven.atm_delta_C13_CMIP7_global_1700-2023_yearly_v3.0_c251013.nc'
2+
stream_fldfilename_atm_c14 = '$DIN_LOC_ROOT/lnd/clm2/isotopes/ctsmforc.Graven.atm_delta_C14_CMIP7_4x1_global_1700-2023_yearly_v3.0_c251013.nc'
3+
stream_year_first_atm_c14 = 2013
4+
stream_model_year_align_atm_c14 = 2013
5+
stream_year_first_atm_c13 = 2013
6+
stream_model_year_align_atm_c13 = 2013
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../ciso_monthly

0 commit comments

Comments
 (0)