-
Notifications
You must be signed in to change notification settings - Fork 296
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
Modularize snow cover fraction method #769
Changes from 36 commits
cde7257
d8d2a2d
18cd14a
6c34aa7
40abe78
d198fe8
20b6dca
7d57070
474ecf3
58fb33d
2f9efe8
8bb9ea3
9c80612
638d636
95b6212
dedbb90
176c92c
be00046
4de1302
7d44d44
e68492a
c2193c6
e0ef720
c9bfca8
0026717
b53b911
bb3dc6e
fcaae88
d17ba01
fe169f7
8a38027
8cf07e8
dbd3264
7ea3798
54d8ed0
46e7cb7
b655a70
3daf306
ebe1c1e
24ffe4e
eaec48a
3d0137e
cb560be
9ca0439
03cb6d4
b3d3b1a
6c91dff
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
""" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Just checking, this seems unrelated to the snow fraction refactor. I'm OK with having it in place, I'm just checking to make sure I understand. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes, this is unrelated. |
||
Implementation of the CIME LWISO (Land Water Isotope) test. | ||
|
||
This is a CTSM specific test: | ||
Verifies turning on water isotopes doesn't change answers | ||
(1) do a run with water isotopes on | ||
(2) do a run with water isotopes off | ||
|
||
The reason for having water isotopes on in the first case (rather than the other way | ||
around) is that this results in having water isotope quantities present in the baselines. | ||
|
||
""" | ||
|
||
from CIME.SystemTests.system_tests_compare_two import SystemTestsCompareTwo | ||
from CIME.XML.standard_module_setup import * | ||
from CIME.SystemTests.test_utils.user_nl_utils import append_to_user_nl_files | ||
|
||
logger = logging.getLogger(__name__) | ||
|
||
class LWISO(SystemTestsCompareTwo): | ||
|
||
def __init__(self, case): | ||
SystemTestsCompareTwo.__init__(self, case, | ||
separate_builds = False, | ||
run_two_suffix = 'nowiso', | ||
run_one_description = 'water isotopes on', | ||
run_two_description = 'water isotopes off', | ||
ignore_fieldlist_diffs = True) | ||
|
||
def _case_one_setup(self): | ||
# BUG(wjs, 2019-07-30, ESCOMP/ctsm#495) We currently can't turn on actual water | ||
# isotopes in a multi-timestep test, so we're setting | ||
# enable_water_tracer_consistency_checks rather than enable_water_isotopes; | ||
# eventually, though, we should change this to the latter. (See | ||
# <https://github.com/ESCOMP/ctsm/issues/495#issuecomment-516619853>.) | ||
append_to_user_nl_files(caseroot = self._get_caseroot(), | ||
component = "clm", | ||
contents = "enable_water_tracer_consistency_checks=.true.") | ||
|
||
def _case_two_setup(self): | ||
append_to_user_nl_files(caseroot = self._get_caseroot(), | ||
component = "clm", | ||
contents = "enable_water_tracer_consistency_checks=.false.") | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -143,6 +143,10 @@ | |
<alias>I2000Clm50BgcCropQianRsGs</alias> | ||
<lname>2000_DATM%QIA_CLM50%BGC-CROP_SICE_SOCN_SROF_SGLC_SWAV</lname> | ||
</compset> | ||
<compset> | ||
<alias>I2000Clm45BgcCropQianRsGs</alias> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I added this to facilitate quick-turnaround testing on my mac (and elsewhere) |
||
<lname>2000_DATM%QIA_CLM45%BGC-CROP_SICE_SOCN_SROF_SGLC_SWAV</lname> | ||
</compset> | ||
|
||
<compset> | ||
<alias>I2000Clm50BgcCruGs</alias> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
The purpose of this testmod is to exercise the newer snow cover fraction | ||
method along with having use_subgrid_fluxes = .false. | ||
|
||
Note that we also need h2osfcflag = 0 in this testmod, because | ||
h2osfcflag = 1 is incompatible with use_subgrid_fluxes = .false. Also, | ||
this needs to be used in a clm45 configuration for compatibility with | ||
other options (or else would need to set some other flags: | ||
lower_boundary_condition and possibly others) |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../default |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
h2osfcflag = 0 | ||
use_subgrid_fluxes = .false. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../default | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I changed this testmod a bit so it would actually produce output |
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,4 @@ | ||
hist_ndens = 1,1 | ||
oldfflag = 1 | ||
snow_cover_fraction_method = 'ny07' | ||
h2osfcflag = 0 | ||
origflag = 1 | ||
subgridflag = 0 | ||
use_subgrid_fluxes = .false. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should "clm5" really be in the name here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry that I wasn't more clear about this: I used "clm5" somewhat as a placeholder just because that was the tentative name used in the discussion in #503 , and I was waiting for a better name. @swensosc has now suggested the name "sl12" (for Swenson & Lawrence 2012), and I will switch the references to clm5 to sl12 throughout this PR.