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

ctsm5.3.027: Migrate FATES parameter file switches to the namelist #2904

Merged
merged 30 commits into from
Mar 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
922a317
add fates daylength factor switch
glemieux Dec 10, 2024
949c668
add FATES switch to enable photosynthetic temp acclimation
glemieux Dec 10, 2024
59fef8c
add FATES namelist switch for stomatal conductance
glemieux Dec 10, 2024
9edf742
add FATES namelist switch for stomatal assimilation
glemieux Dec 10, 2024
59eb9f4
add FATES namelist switch for leaf respiration model
glemieux Dec 10, 2024
11a1708
add FATES switch to select carbon starvation model
glemieux Dec 10, 2024
3f2ed72
add FATES seed regeneration model switch to namelist
glemieux Dec 10, 2024
adf7d56
add FATES hydro solver selection switch to namelist
glemieux Dec 10, 2024
47fd489
add FATES radiation model switch to the namelist
glemieux Dec 11, 2024
02bc32a
change fates photosynthethic acclimation switch from logical to named
glemieux Jan 15, 2025
660ed58
add year to model switch for fates_stomatal_model namelist option
glemieux Jan 15, 2025
f990b24
fix fates_hydro_solver option name check
glemieux Jan 15, 2025
13a16e5
Merge tag 'ctsm5.3.019' into fates-switch-migration
glemieux Jan 15, 2025
5a04385
Merge remote-tracking branch 'glemieux/fates-api37.1' into fates-swit…
glemieux Feb 20, 2025
fa63e28
update fates gitmodules tag
glemieux Feb 20, 2025
2d0a541
Merge tag 'ctsm5.3.025' into fates-switch-migration
glemieux Feb 22, 2025
877e986
update default fates parameter file
glemieux Feb 23, 2025
9af9f32
update fates twostream tests per switch migration
glemieux Feb 23, 2025
ef27e7d
fix namelist definition valid values
glemieux Feb 23, 2025
527a4e0
correct fates API check for radation model
glemieux Feb 23, 2025
aea8a4e
correct default fates hydro solver
glemieux Feb 24, 2025
7d13840
update fates commit
glemieux Feb 24, 2025
e2a786a
add the fates electron transport model switch
glemieux Feb 26, 2025
6d26981
update default parameter file
glemieux Feb 26, 2025
8fe2323
Merge tag 'ctsm5.3.026' into fates-switch-migration
glemieux Feb 27, 2025
4c69e5e
update fates gitmodule commit hash
glemieux Feb 27, 2025
4a38054
update ctsm5.3.027 changelog and changesum
glemieux Mar 2, 2025
42d14dc
update missing test results from ctsm5.3.025
glemieux Mar 2, 2025
dfe3749
update izumi aux_clm results in changelog for ctsm5.3.027
glemieux Mar 2, 2025
8020236
update build-namelist test
glemieux Mar 3, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
[submodule "fates"]
path = src/fates
url = https://github.com/NGEET/fates
fxtag = sci.1.81.0_api.37.1.0
fxtag = sci.1.81.1_api.38.0.0
fxrequired = AlwaysRequired
# Standard Fork to compare to with "git fleximod test" to ensure personal forks aren't committed
fxDONOTUSEurl = https://github.com/NCAR/fates-release
Expand Down
12 changes: 10 additions & 2 deletions bld/CLMBuildNamelist.pm
Original file line number Diff line number Diff line change
Expand Up @@ -808,7 +808,11 @@ sub setup_cmdl_fates_mode {
"use_fates_cohort_age_tracking","use_fates_inventory_init","use_fates_fixed_biogeog",
"use_fates_nocomp","use_fates_sp","fates_inventory_ctrl_filename","fates_harvest_mode",
"fates_parteh_mode","use_fates_tree_damage","fates_seeddisp_cadence","use_fates_luh","fluh_timeseries",
"flandusepftdat","use_fates_potentialveg","use_fates_lupft","fates_history_dimlevel" );
"flandusepftdat","use_fates_potentialveg","use_fates_lupft","fates_history_dimlevel",
"use_fates_daylength_factor", "fates_photosynth_acclimation", "fates_stomatal_model",
"fates_stomatal_assimilation", "fates_leafresp_model", "fates_cstarvation_model",
"fates_regeneration_model", "fates_hydro_solver", "fates_radiation_model", "fates_electron_transport_model"
);

# dis-allow fates specific namelist items with non-fates runs
foreach my $var ( @list ) {
Expand Down Expand Up @@ -4707,7 +4711,11 @@ sub setup_logic_fates {
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, 'fates_paramfile', 'phys'=>$nl_flags->{'phys'});
my @list = ( "fates_spitfire_mode", "use_fates_planthydro", "use_fates_ed_st3", "use_fates_ed_prescribed_phys",
"use_fates_inventory_init","fates_seeddisp_cadence","fates_history_dimlevel",
"fates_harvest_mode","fates_parteh_mode", "use_fates_cohort_age_tracking","use_fates_tree_damage" );
"fates_harvest_mode","fates_parteh_mode", "use_fates_cohort_age_tracking","use_fates_tree_damage",
"use_fates_daylength_factor", "fates_photosynth_acclimation", "fates_stomatal_model",
"fates_stomatal_assimilation", "fates_leafresp_model", "fates_cstarvation_model",
"fates_regeneration_model", "fates_hydro_solver", "fates_radiation_model", "fates_electron_transport_model"
);

foreach my $var ( @list ) {
add_default($opts, $nl_flags->{'inputdata_rootdir'}, $definition, $defaults, $nl, $var, 'use_fates'=>$nl_flags->{'use_fates'},
Expand Down
62 changes: 36 additions & 26 deletions bld/namelist_files/namelist_defaults_ctsm.xml
Original file line number Diff line number Diff line change
Expand Up @@ -532,7 +532,7 @@ attributes from the config_cache.xml file (with keys converted to upper-case).
<!-- FATES default parameter file -->
<!-- ================================================================== -->

<fates_paramfile>lnd/clm2/paramdata/fates_params_api.37.1.0_14pft_c250214.nc</fates_paramfile>
<fates_paramfile>lnd/clm2/paramdata/fates_params_api.38.0.0_14pft_c250226.nc</fates_paramfile>


<!-- ================================================================== -->
Expand Down Expand Up @@ -2387,31 +2387,41 @@ lnd/clm2/surfdata_esmf/NEON/ctsm5.3.0/surfdata_1x1_NEON_TOOL_hist_2000_78pfts_c2
<use_nitrif_denitrif >.true.</use_nitrif_denitrif>

<!-- ===== FATES DEFAULTS =========== -->
<fates_spitfire_mode use_fates=".true.">0</fates_spitfire_mode>
<fates_harvest_mode use_fates=".true.">no_harvest</fates_harvest_mode>
<use_fates_planthydro use_fates=".true.">.false.</use_fates_planthydro>
<use_fates_tree_damage use_fates=".true.">.false.</use_fates_tree_damage>
<use_fates_cohort_age_tracking use_fates=".true.">.false.</use_fates_cohort_age_tracking>
<use_fates_ed_st3 use_fates=".true.">.false.</use_fates_ed_st3>
<use_fates_ed_prescribed_phys use_fates=".true.">.false.</use_fates_ed_prescribed_phys>
<use_fates_inventory_init use_fates=".true.">.false.</use_fates_inventory_init>
<use_fates_sp use_fates=".true.">.false.</use_fates_sp>
<use_fates_lupft use_fates=".true.">.false.</use_fates_lupft>
<use_fates_potentialveg use_fates=".true.">.false.</use_fates_potentialveg>
<use_fates_luh use_fates=".true." fates_harvest_mode="luhdata_area" >.true.</use_fates_luh>
<use_fates_luh use_fates=".true." fates_harvest_mode="luhdata_mass" >.true.</use_fates_luh>
<use_fates_luh use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_luh>
<use_fates_luh use_fates=".true." use_fates_potentialveg=".true.">.true.</use_fates_luh>
<use_fates_luh use_fates=".true." >.false.</use_fates_luh>
<fates_parteh_mode use_fates=".true.">1</fates_parteh_mode>
<fates_seeddisp_cadence use_fates=".true.">0</fates_seeddisp_cadence>
<use_fates_nocomp use_fates=".true." use_fates_sp=".true." >.true.</use_fates_nocomp>
<use_fates_nocomp use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_nocomp>
<use_fates_nocomp use_fates=".true." >.false.</use_fates_nocomp>
<use_fates_fixed_biogeog use_fates=".true." use_fates_sp=".true." >.true.</use_fates_fixed_biogeog>
<use_fates_fixed_biogeog use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_fixed_biogeog>
<use_fates_fixed_biogeog use_fates=".true." >.false.</use_fates_fixed_biogeog>
<fates_history_dimlevel use_fates=".true.">2,2</fates_history_dimlevel>
<fates_electron_transport_model use_fates=".true.">FvCB1980</fates_electron_transport_model>
<fates_photosynth_acclimation use_fates=".true.">nonacclimating</fates_photosynth_acclimation>
<fates_spitfire_mode use_fates=".true.">0</fates_spitfire_mode>
<fates_harvest_mode use_fates=".true.">no_harvest</fates_harvest_mode>
<fates_stomatal_model use_fates=".true.">ballberry1987</fates_stomatal_model>
<fates_stomatal_assimilation use_fates=".true.">net</fates_stomatal_assimilation>
<fates_leafresp_model use_fates=".true.">ryan1991</fates_leafresp_model>
<fates_cstarvation_model use_fates=".true.">linear</fates_cstarvation_model>
<fates_regeneration_model use_fates=".true.">default</fates_regeneration_model>
<fates_radiation_model use_fates=".true.">norman</fates_radiation_model>
<fates_hydro_solver use_fates=".true.">2D_Picard</fates_hydro_solver>
<use_fates_planthydro use_fates=".true.">.false.</use_fates_planthydro>
<use_fates_tree_damage use_fates=".true.">.false.</use_fates_tree_damage>
<use_fates_cohort_age_tracking use_fates=".true.">.false.</use_fates_cohort_age_tracking>
<use_fates_daylength_factor use_fates=".true.">.true.</use_fates_daylength_factor>
<use_fates_ed_st3 use_fates=".true.">.false.</use_fates_ed_st3>
<use_fates_ed_prescribed_phys use_fates=".true.">.false.</use_fates_ed_prescribed_phys>
<use_fates_inventory_init use_fates=".true.">.false.</use_fates_inventory_init>
<use_fates_sp use_fates=".true.">.false.</use_fates_sp>
<use_fates_lupft use_fates=".true.">.false.</use_fates_lupft>
<use_fates_potentialveg use_fates=".true.">.false.</use_fates_potentialveg>
<use_fates_luh use_fates=".true." fates_harvest_mode="luhdata_area" >.true.</use_fates_luh>
<use_fates_luh use_fates=".true." fates_harvest_mode="luhdata_mass" >.true.</use_fates_luh>
<use_fates_luh use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_luh>
<use_fates_luh use_fates=".true." use_fates_potentialveg=".true.">.true.</use_fates_luh>
<use_fates_luh use_fates=".true." >.false.</use_fates_luh>
<fates_parteh_mode use_fates=".true.">1</fates_parteh_mode>
<fates_seeddisp_cadence use_fates=".true.">0</fates_seeddisp_cadence>
<use_fates_nocomp use_fates=".true." use_fates_sp=".true." >.true.</use_fates_nocomp>
<use_fates_nocomp use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_nocomp>
<use_fates_nocomp use_fates=".true." >.false.</use_fates_nocomp>
<use_fates_fixed_biogeog use_fates=".true." use_fates_sp=".true." >.true.</use_fates_fixed_biogeog>
<use_fates_fixed_biogeog use_fates=".true." use_fates_lupft=".true.">.true.</use_fates_fixed_biogeog>
<use_fates_fixed_biogeog use_fates=".true." >.false.</use_fates_fixed_biogeog>
<fates_history_dimlevel use_fates=".true.">2,2</fates_history_dimlevel>


<!-- ========================================= -->
Expand Down
58 changes: 58 additions & 0 deletions bld/namelist_files/namelist_definition_ctsm.xml
Original file line number Diff line number Diff line change
Expand Up @@ -780,6 +780,64 @@ Allowed values are:
This option is older than the luhdata options and may be depricated at some point in the future.
</entry>

<entry id="fates_electron_transport_model" type="char*256" category="physics"
group="elm_inparm" valid_values="FvCB1980,JohnsonBerry2021" value="FvCB1980">
Set the FATES electron transport model to either Johnson-Berry 2021 or
Farquhar von Caemmerer and Berry 1980 (FvCB1980).

</entry>

<entry id="fates_radiation_model" type="char*256" category="physics"
group="clm_inparm" valid_values="norman,twostream" value="norman">
Set the FATES radiation model
</entry>

<entry id="fates_hydro_solver" type="char*256" category="physics"
group="clm_inparm" valid_values="1D_Taylor,2D_Picard,2D_Newton" value="1D_Taylor">
Set the FATES hydro solver method
</entry>

<entry id="fates_regeneration_model" type="char*256" category="physics"
group="clm_inparm" valid_values="default,trs,trs_no_seed_dyn" value="default">
Set the FATES seed regeneration model
Valid values:
default: default scheme
trs: Tree Recruitment Scheme (Hanbury-Brown et al., 2022)
trs_no_seed_dyn: Tree Recruitment Scheme (Hanbury-Brown et al., 2022) without seed dynamics
</entry>

<entry id="fates_cstarvation_model" type="char*256" category="physics"
group="clm_inparm" valid_values="linear,exponential" value="linear">
Set the FATES carbon starvation model
</entry>

<entry id="fates_leafresp_model" type="char*256" category="physics"
group="clm_inparm" valid_values="ryan1991,atkin2017" value="ryan1991">
Set the FATES leaf maintenance respiration model
</entry>

<entry id="fates_stomatal_assimilation" type="char*256" category="physics"
group="clm_inparm" valid_values="net,gross" value="net">
Set net or gross asslimiation for the FATES stomatal model
</entry>

<entry id="fates_stomatal_model" type="char*256" category="physics"
group="clm_inparm" valid_values="ballberry1987,medlyn2011" value="ballberry1987">
Set the FATES stomatal conductance model
</entry>

<entry id="fates_photosynth_acclimation" type="char*256" category="physics"
group="clm_inparm" valid_values="nonacclimating,kumarathunge2019" value="nonacclimating">
Set the FATES photosynthesis temperature acclimation model.
(Only relevant if FATES is on)
</entry>

<entry id="use_fates_daylength_factor" type="logical" category="physics"
group="clm_inparm" valid_values="" value=".true.">
If TRUE, enable FATES to utilize the day length factor from the host land model.
(Only relevant if FATES is on)
</entry>

<entry id="use_fates_planthydro" type="logical" category="physics"
group="clm_inparm" valid_values="" value=".false.">
Toggle to turn on plant hydraulics
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
fates_paramfile = '$CASEROOT/fates_params_twostream.nc'
fates_radiation_model = 'twostream'

This file was deleted.

Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
fates_paramfile = '$CASEROOT/fates_params_twostream.nc'
use_fates_fixed_biogeog=.true.
use_fates_fixed_biogeog=.true.
fates_radiation_model = 'twostream'
95 changes: 93 additions & 2 deletions doc/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,4 +1,95 @@
===============================================================
Tag name: ctsm5.3.027
Originator(s): glemieux (Gregory Lemieux, LBNL, [email protected])
Date: Sun Mar 2 15:27:01 PST 2025
One-line Summary: FATES parameter file switch migration

Purpose and description of changes
----------------------------------

Move global FATES switches from the FATES parameter file to the namelist.


Significant changes to scientifically-supported configurations
--------------------------------------------------------------

Does this tag change answers significantly for any of the following physics configurations?
(Details of any changes will be given in the "Answer changes" section below.)

[Put an [X] in the box for any configuration with significant answer changes.]

[ ] clm6_0

[ ] clm5_0

[ ] ctsm5_0-nwp

[ ] clm4_5

Notes of particular relevance for users
---------------------------------------

Changes to CTSM's user interface (e.g., new/renamed XML or namelist variables):

The following FATES namelist options are now available:
- use_fates_daylength_factor
- fates_photosynth_acclimation
- fates_stomatal_model
- fates_stomatal_assimilation
- fates_leafresp_model
- fates_cstarvation_model
- fates_regeneration_model
- fates_hydro_solver
- fates_radiation_model

The following FATES namelist option is available, but not yet implemented in FATES:
- fates_electron_transport_model

Notes of particular relevance for developers:
---------------------------------------------
Changes to tests or testing:

The FATES two stream tests no longer generation a FATES NetCDF parameter file on-the-fly.
The need to do so is removed as the fates_radiation_model option is controlled by the
namelist.


Testing summary:
----------------

build-namelist tests (if CLMBuildNamelist.pm has changed):

derecho - PASS

regular tests (aux_clm: https://github.com/ESCOMP/CTSM/wiki/System-Testing-Guide#pre-merge-system-testing):

derecho ----- OK
izumi ------- OK

fates tests: (give name of baseline if different from CTSM tagname, normally fates baselines are fates-<FATES TAG>-<CTSM TAG>)
derecho ----- OK
izumi ------- OK


Answer changes
--------------

Changes answers relative to baseline: No

Other details
-------------

List any git submodules updated (cime, rtm, mosart, cism, fates, etc.):
fates: sci.1.81.0_api.37.1.0 -> sci.1.81.1_api.38.0.0

Pull Requests that document the changes (include PR ids):
(https://github.com/ESCOMP/ctsm/pull)
https://github.com/ESCOMP/CTSM/pull/2904
https://github.com/NGEET/fates/pull/1300
https://github.com/NGEET/fates/pull/1344

===============================================================
===============================================================
Tag name: ctsm5.3.026
Originator(s): erik (Erik Kluzek,UCAR/TSS,303-497-1326)
Date: Wed 26 Feb 2025 09:55:48 AM MST
Expand Down Expand Up @@ -138,8 +229,8 @@ Testing summary:

regular tests (aux_clm: https://github.com/ESCOMP/CTSM/wiki/System-Testing-Guide#pre-merge-system-testing):

derecho -----
izumi -------
derecho ----- OK
izumi ------- OK

fates tests: (give name of baseline if different from CTSM tagname, normally fates baselines are fates-<FATES TAG>-<CTSM TAG>)
derecho ----- OK
Expand Down
1 change: 1 addition & 0 deletions doc/ChangeSum
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Tag Who Date Summary
============================================================================================================================
ctsm5.3.027 glemieux 03/02/2025 FATES parameter file switch migration
ctsm5.3.026 samrabin 02/26/2025 Merge b4b-dev to master: run_tower updates, reduce log noise
ctsm5.3.025 glemieux 02/20/2025 FATES default parameter file update
ctsm5.3.024 xinchang 02/11/2025 Change choice of pressure in CLMU building energy model
Expand Down
11 changes: 11 additions & 0 deletions src/main/clm_varctl.F90
Original file line number Diff line number Diff line change
Expand Up @@ -331,13 +331,24 @@ module clm_varctl
! see bld/namelist_files/namelist_definition_clm4_5.xml for details
logical, public :: use_fates_tree_damage = .false. ! true => turn on tree damage module
character(len=256), public :: fates_harvest_mode = '' ! five different harvest modes; see namelist definition
character(len=256), public :: fates_stomatal_model = '' ! stomatal conductance model, Ball-berry or Medlyn
character(len=256), public :: fates_stomatal_assimilation = '' ! net or gross assimilation modes
character(len=256), public :: fates_leafresp_model = '' ! Leaf maintenance respiration model, Ryan or Atkin
character(len=256), public :: fates_cstarvation_model = '' ! linear or exponential function
character(len=256), public :: fates_regeneration_model = '' ! default, TRS, or TRS without seed dynamics
character(len=256), public :: fates_radiation_model = '' ! Norman or two-stream radiation model
character(len=256), public :: fates_hydro_solver = '' ! 1D Taylor, 2D Picard, 2D Newton
character(len=256), public :: fates_photosynth_acclimation = '' ! nonacclimating, kumarathunge2019
character(len=256), public :: fates_electron_transport_model = '' ! Johnson-Berry 2021 or Farquhar von Caemmerer and Berry 1980
logical, public :: use_fates_planthydro = .false. ! true => turn on fates hydro
logical, public :: use_fates_cohort_age_tracking = .false. ! true => turn on cohort age tracking
logical, public :: use_fates_ed_st3 = .false. ! true => static stand structure
logical, public :: use_fates_ed_prescribed_phys = .false. ! true => prescribed physiology
logical, public :: use_fates_inventory_init = .false. ! true => initialize fates from inventory
logical, public :: use_fates_fixed_biogeog = .false. ! true => use fixed biogeography mode
logical, public :: use_fates_nocomp = .false. ! true => use no comopetition mode
logical, public :: use_fates_daylength_factor = .false. ! true => enable fates to use host land model daylength factor


! FATES history dimension level
! fates can produce history at either the daily timescale (dynamics)
Expand Down
Loading