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

Preparing alpha-ctsm5.2.mksrf.16_ctsm5.1.dev123 tag #2016

Merged
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
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
957 changes: 108 additions & 849 deletions bld/namelist_files/namelist_defaults_ctsm.xml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
flanduse_timeseries = '$DIN_LOC_ROOT/lnd/clm2/surfdata_map/landuse.timeseries_4x5_hist_simyr1850-2015_200311.nc'
flanduse_timeseries = '$DIN_LOC_ROOTlnd/clm2/surfdata_esmf/ctsm5.2.0/landuse.timeseries_10x15_hist_78_CMIP6_1850-2000_c230517.nc'
Copy link
Contributor Author

@slevis-lmwg slevis-lmwg Jun 5, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Notes to self:

  • Typo: Need /lnd instead of lnd

do_harvest = .true.
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,18 @@ exercising the collapse2gencrop branch ability to collapse the full crop data
to clm's generic crops.

According to the file
/glade/work/slevis/git/collapse_pfts/bld/namelist_files/namelist_defaults_clm4_5.xml
bld/namelist_files/namelist_defaults_ctsm.xml
the following two files used in this test
are default files for the following options:

fsurdat = '/glade/p/cesmdata/cseg/inputdata/lnd/clm2/surfdata_map/surfdata_10x15_78pfts_CMIP6_simyr1850_c170824.nc'
fsurdat = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/surfdata_10x15_hist_78pfts_CMIP6_1850_c230517.nc'
hgrid="10x15" sim_year="1850" use_crop=".false." irrigate=".true."
hgrid="10x15" sim_year="1850" use_crop=".true."

flanduse_timeseries = '/glade/p/cesmdata/cseg/inputdata/lnd/clm2/surfdata_map/landuse.timeseries_10x15_hist_78pfts_CMIP6_simyr1850-2015_c170824.nc'
hgrid="10x15" sim_year_range="1850-2000" use_crop=".true."
hgrid="10x15" rcp="8.5" sim_year_range="1850-2100" use_crop=".true."
hgrid="10x15" rcp="6" sim_year_range="1850-2100" use_crop=".true."
hgrid="10x15" rcp="4.5" sim_year_range="1850-2100" use_crop=".true."
hgrid="10x15" rcp="2.6" sim_year_range="1850-2100" use_crop=".true."
flanduse_timeseries = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/landuse.timeseries_10x15_hist_78_CMIP6_1850-2015_c230601.nc'
hgrid="10x15" sim_year_range="1850-2000" irrigate=".true." use_vichydro=".true."
hgrid="10x15" sim_year_range="1850-2000" irrigate=".true."
hgrid="10x15" sim_year_range="1850-2000" use_vichydro=".false."

This test includes the settings of the decStart test so as to also test the
end-of-year transition since it's an IHist case and transient vegetation gets
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
fsurdat = '/glade/p/cesmdata/cseg/inputdata/lnd/clm2/surfdata_map/surfdata_10x15_78pfts_CMIP6_simyr1850_c170824.nc'
flanduse_timeseries = '/glade/p/cesmdata/cseg/inputdata/lnd/clm2/surfdata_map/landuse.timeseries_10x15_hist_78pfts_CMIP6_simyr1850-2015_c170824.nc'
fsurdat = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/surfdata_10x15_hist_78pfts_CMIP6_1850_c230517.nc'
flanduse_timeseries = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/landuse.timeseries_10x15_hist_78_CMIP6_1850-2015_c230601.nc'
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
! Specify a dataset that has non-zero Gross Unrepresented Land Use change fields on it
! And turn it on
flanduse_timeseries = '$DIN_LOC_ROOT/lnd/clm2/surfdata_map/ctsm5.1.dev052/landuse.timeseries_0.9x1.25_hist_78pfts_CMIP6_simyr1700-2021_c220825.nc'
fsurdat = '$DIN_LOC_ROOT/lnd/clm2/surfdata_map/ctsm5.1.dev052/surfdata_0.9x1.25_hist_78pfts_CMIP6_simyr1700_c220825.nc'
flanduse_timeseries = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/landuse.timeseries_0.9x1.25_hist_78_CMIP6_1850-2015_c230601.nc'
fsurdat = '$DIN_LOC_ROOT/lnd/clm2/surfdata_esmf/ctsm5.2.0/surfdata_0.9x1.25_hist_78pfts_CMIP6_1850_c230517.nc'
do_grossunrep = .true.
1 change: 0 additions & 1 deletion python/ctsm/modify_input_files/modify_fsurdat.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,6 @@ def set_idealized(self):
self.setvar_lev0("SLOPE", slope)
self.setvar_lev0("zbedrock", zbedrock)
self.setvar_lev0("SOIL_COLOR", soil_color)
self.setvar_lev0("PFTDATA_MASK", pftdata_mask)
self.setvar_lev0("LANDFRAC_PFT", landfrac_pft)
self.setvar_lev0("PCT_WETLAND", pct_not_nat_veg)
self.setvar_lev0("PCT_CROP", pct_not_nat_veg)
Expand Down
8 changes: 4 additions & 4 deletions python/ctsm/test/test_sys_fsurdat_modifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def setUp(self):
self._testinputs_path = testinputs_path
self._fsurdat_in = os.path.join(
testinputs_path,
"surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214.nc",
"surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517.nc",
)
self._tempdir = tempfile.mkdtemp()
self._cfg_file_path = os.path.join(self._tempdir, "modify_fsurdat.cfg")
Expand Down Expand Up @@ -77,7 +77,7 @@ def test_short_config(self):
sys.argv = ["fsurdat_modifier", self._cfg_file_path]
parser = fsurdat_modifier_arg_process()
fsurdat_out = (
"ctsm/test/testinputs/surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214_out.nc"
"ctsm/test/testinputs/surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517_out.nc"
)
if os.path.exists(fsurdat_out):
os.remove(fsurdat_out)
Expand Down Expand Up @@ -134,14 +134,14 @@ def test_opt_sections(self):
self._cfg_file_path = os.path.join(self._testinputs_path, "modify_fsurdat_opt_sections.cfg")
outfile = os.path.join(
self._tempdir,
"surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214_output_urban.nc",
"surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517_output_urban.nc",
)
sys.argv = [
"fsurdat_modifier",
self._cfg_file_path,
"-i",
os.path.join(
self._testinputs_path, "surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214.nc"
self._testinputs_path, "surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517.nc"
),
"-o",
outfile,
Expand Down
12 changes: 6 additions & 6 deletions python/ctsm/test/testinputs/default_data.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ precname = CLMGSWP3v1.Precip
tpqwname = CLMGSWP3v1.TPQW

[surfdat]
dir = lnd/clm2/surfdata_map/release-clm5.0.18
surfdat_16pft = surfdata_0.9x1.25_hist_16pfts_Irrig_CMIP6_simyr2000_c190214.nc
surfdat_78pft = surfdata_0.9x1.25_hist_78pfts_CMIP6_simyr2000_c190214.nc
dir = lnd/clm2/surfdata_esmf/ctsm5.2.0
surfdat_16pft = surfdata_0.9x1.25_hist_16pfts_CMIP6_2000_c230517.nc
surfdat_78pft = surfdata_0.9x1.25_hist_78pfts_CMIP6_2000_c230517.nc

[landuse]
dir = lnd/clm2/surfdata_map/release-clm5.0.18
landuse_16pft = landuse.timeseries_0.9x1.25_hist_16pfts_Irrig_CMIP6_simyr1850-2015_c190214.nc
landuse_78pft = landuse.timeseries_0.9x1.25_hist_78pfts_CMIP6_simyr1850-2015_c190214.nc
dir = lnd/clm2/surfdata_esmf/ctsm5.2.0
landuse_16pft = landuse.timeseries_0.9x1.25_hist_78_CMIP6_1850-2015_c230601.nc
landuse_78pft = landuse.timeseries_0.9x1.25_hist_78_CMIP6_1850-2015_c230601.nc

[domain]
file = share/domains/domain.lnd.fv0.9x1.25_gx1v7.151020.nc
4 changes: 2 additions & 2 deletions python/ctsm/test/testinputs/modify_fsurdat_short.cfg
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[modify_fsurdat_basic_options]

fsurdat_in = ctsm/test/testinputs/surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214.nc
fsurdat_out = ctsm/test/testinputs/surfdata_5x5_amazon_16pfts_Irrig_CMIP6_simyr2000_c171214_out.nc
fsurdat_in = ctsm/test/testinputs/surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517.nc
fsurdat_out = ctsm/test/testinputs/surfdata_5x5_amazon_hist_78pfts_CMIP6_2000_c230517_out.nc

idealized = False
process_subgrid_section = False
Expand Down
10 changes: 5 additions & 5 deletions tools/mksurfdata_esmf/README
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ Building the executable (working in tools/mksurfdata_esmf)
=======================
Running for a single submission:
=======================
# Work in the ctsm_py environment, which requires the following steps:
# Work in the ctsm_pylib environment, which requires the following steps:
> module unload python; module load conda
> cd ../..; ./py_env_create
> conda activate ctsm_py; cd tools/mksurfdata_esmf
Expand All @@ -93,10 +93,10 @@ Running for a single submission:
=======================
Running for the generation of multiple datasets
=======================
# Notes:
# - gen_mksurfdata_jobscript_multi.py runs ./gen_mksurfdata_namelist.py for you
# - The regional grid 5x5_amazon may fail with 24 nodes.
# Task geometry that worked: #PBS -l select=4:ncpus=36:mpiprocs=4
# Work in the ctsm_pylib environment, as explained in earlier section.
# gen_mksurfdata_jobscript_multi.py runs ./gen_mksurfdata_namelist.py for you
# The regional grid 5x5_amazon may fail with 24 nodes.
# Task geometry that worked: #PBS -l select=4:ncpus=36:mpiprocs=4
> ./gen_mksurfdata_jobscript_multi.py --help
> ./gen_mksurfdata_jobscript_multi.py --number-of-nodes 24 --scenario all
> qsub mksurfdata_jobscript_multi
Expand Down
64 changes: 31 additions & 33 deletions tools/mksurfdata_esmf/gen_mksurfdata_jobscript_multi.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,15 @@
"global-present-nldas",
"tropics",
"crop-tropics-present",
"crop-tropics-historical",
"crop-tropics-transient",
"crop",
"crop-global-present",
"crop-global-present-ne16np4",
"crop-global-present-ne120np4",
"crop-global-present-0.125",
"crop-global-present-f05",
"crop-global-historical",
"crop-global-historical-f05",
"crop-global-historical-ne120np4",
"crop-global-transient",
"crop-global-transient-ne120np4",
"crop-global-transient-f05",
"crop-global-1850",
"crop-global-1850-ne120np4",
"crop-global-hist",
"crop-global-future",
"crop-global-SSP1-2.6",
"crop-global-SSP3-7.0",
Expand All @@ -38,7 +33,8 @@
"crop-global-SSP1-1.9",
"crop-global-SSP4-3.4",
"crop-global-SSP4-6.0",
"crop-global-SSP5-8.5"]
"crop-global-SSP5-8.5",
"crop-global-SSP5-8.5-neres"]

def get_parser():
"""
Expand Down Expand Up @@ -122,8 +118,8 @@ def main ():
"crop-global-present",
"crop-global-present-ne16np4",
"crop-global-present-ne120np4",
"crop-global-historical",
"crop-global-transient",
"crop-global-1850",
"crop-global-hist",
"crop-tropics-present",
"crop-global-SSP1-2.6",
"crop-global-SSP3-7.0",
Expand All @@ -132,7 +128,8 @@ def main ():
"crop-global-SSP1-1.9",
"crop-global-SSP4-3.4",
"crop-global-SSP4-6.0",
"crop-global-SSP5-8.5"]
"crop-global-SSP5-8.5",
"crop-global-SSP5-8.5-neres"]
elif scenario == 'standard':
target_list = ["global-present",
"global-present-T42",
Expand All @@ -141,8 +138,8 @@ def main ():
target_list = ["crop-global-present",
"crop-global-present-ne16np4",
"crop-global-present-ne120np4",
"crop-global-historical",
"crop-global-transient"]
"crop-global-1850",
"crop-global-hist"]
elif scenario == "crop-global-future":
target_list = ["crop-global-SSP1-2.6",
"crop-global-SSP3-7.0",
Expand All @@ -151,7 +148,8 @@ def main ():
"crop-global-SSP1-1.9",
"crop-global-SSP4-3.4",
"crop-global-SSP4-6.0",
"crop-global-SSP5-8.5"]
"crop-global-SSP5-8.5",
"crop-global-SSP5-8.5-neres"]
elif scenario == "tropics":
target_list = ["crop-tropics-present"]
else:
Expand All @@ -161,13 +159,13 @@ def main ():
# Determine resolution sets that are referenced in commands
# --------------------------
resolution_dict = {
"standard_res_no_crop" : ["0.9x1.25","1.9x2.5","10x15"],
"standard_res" : ['0.9x1.25','1.9x2.5','10x15','4x5','C96',
"standard_res_no_crop" : ["0.9x1.25","1.9x2.5","10x15","4x5"],
"most_res" : ['0.9x1.25','1.9x2.5','10x15','4x5','C96',
'ne30np4','ne30np4.pg2','ne30np4.pg3','ne30np4.pg4','ne120np4.pg3',
'ne0np4.ARCTICGRIS.ne30x8','ne0np4.ARCTIC.ne30x4', 'ne0np4CONUS.ne30x8'],
"future_res" : ["0.9x1.25","1.9x2.5","10x15"],
"trans_res" : ['0.9x1.25','1.9x2.5','10x15','ne30np4',
'ne0np4.ARCTICGRIS.ne30x8','ne0np4.ARCTIC.ne30x4','ne0np4CONUS.ne30x8','ne120np4'],
"standard_res" : ["0.9x1.25","1.9x2.5","10x15"],
"future_ne_res" : ['ne30np4','ne0np4.ARCTICGRIS.ne30x8',
'ne0np4.ARCTIC.ne30x4','ne0np4CONUS.ne30x8','ne120np4'],
"T42_res" : ['T42'],
"nldas_res" : ['0.125nldas2'],
"5x5_amazon_res" : ['5x5_amazon'],
Expand All @@ -182,22 +180,22 @@ def main ():
"global-present-T42" : ("--start-year 2000 --end-year 2000 --nocrop --vic --res", "T42_res"),
"global-present-nldas" : ("--start-year 2000 --end-year 2000 --nocrop --vic --res", "nldas_res"),
"crop-tropics-present" : ("--start-year 2000 --end-year 2000 --res", "5x5_amazon_res"),
"crop-global-present" : ("--start-year 2000 --end-year 2000 --res", "standard_res"),
"crop-global-present" : ("--start-year 2000 --end-year 2000 --res", "most_res"),
"crop-global-present-ne16np4" : ("--start-year 2000 --end-year 2000 --res", "ne16np4_res"),
"crop-global-present-ne120np4" : ("--start-year 2000 --end-year 2000 --res", "ne120np4_res"),
"crop-global-present-0.125" : ("--start-year 2000 --end-year 2000 --hirespft --res", "nldas_res"),
"crop-global-historical" : ("--start-year 1850 --end-year 1850 --ssp-rcp SSP5-8.5 --res", "standard_res"),
"crop-global-historical-ne120np4" : ("--start-year 1850 --end-year 1850 --ssp-rcp SSP5-8.5 --res", "ne120np4_res"),
"crop-global-transient" : ("--start-year 1850 --end-year 2000 --nosurfdata --res", "trans_res"),
"crop-global-transient-ne120np4" : ("--start-year 1850 --end-year 2000 --nosurfdata --res", "ne120np4_res"),
"crop-global-SSP1-1.9" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP1-1.9 --res", "future_res"),
"crop-global-SSP1-2.6" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP1-2.6 --res", "future_res"),
"crop-global-SSP2-4.5" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP2-4.5 --res", "future_res"),
"crop-global-SSP3-7.0" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP3-7.0 --res", "future_res"),
"crop-global-SSP4-3.4" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP4-3.4 --res", "future_res"),
"crop-global-SSP4-6.0" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP4-6.0 --res", "future_res"),
"crop-global-SSP5-3.4" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP5-3.4 --res", "future_res"),
"crop-global-SSP5-8.5" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP5-8.5 --res", "future_res")
"crop-global-1850" : ("--start-year 1850 --end-year 1850 --res", "most_res"),
"crop-global-1850-ne120np4" : ("--start-year 1850 --end-year 1850 --res", "ne120np4_res"),
"crop-global-hist" : ("--start-year 1850 --end-year 2015 --nosurfdata --res", "standard_res"),
"crop-global-SSP1-1.9" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP1-1.9 --res", "standard_res"),
"crop-global-SSP1-2.6" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP1-2.6 --res", "standard_res"),
"crop-global-SSP2-4.5" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP2-4.5 --res", "standard_res"),
"crop-global-SSP3-7.0" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP3-7.0 --res", "standard_res"),
"crop-global-SSP4-3.4" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP4-3.4 --res", "standard_res"),
"crop-global-SSP4-6.0" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP4-6.0 --res", "standard_res"),
"crop-global-SSP5-3.4" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP5-3.4 --res", "standard_res"),
"crop-global-SSP5-8.5" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP5-8.5 --res", "standard_res"),
"crop-global-SSP5-8.5-neres" : ("--start-year 1850 --end-year 2100 --nosurfdata --ssp-rcp SSP5-8.5 --res", "future_ne_res")
}

# --------------------------
Expand Down