@@ -52,10 +52,11 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
52
52
config ["mask_grid" ] = case .get_value ("MASK_GRID" )
53
53
for val in ("HIST" , "REST" , "STOP" ):
54
54
config [val .lower ()+ "_option" ] = case .get_value (val + "_OPTION" )
55
-
55
+
56
56
57
57
config ["comp_ocn" ] = case .get_value ("COMP_OCN" )
58
58
59
+
59
60
atm_grid = case .get_value ("ATM_GRID" )
60
61
lnd_grid = case .get_value ("LND_GRID" )
61
62
ice_grid = case .get_value ("ICE_GRID" )
@@ -113,7 +114,7 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
113
114
config ["COMP_ROF" ] = case .get_value ("COMP_ROF" )
114
115
config ["COMP_WAV" ] = case .get_value ("COMP_WAV" )
115
116
config ["CAMDEV" ] = "True" if "CAM70" in case .get_value ("COMPSET" ) else "False"
116
-
117
+
117
118
if (
118
119
(
119
120
case .get_value ("COMP_ROF" ) == "mosart"
@@ -135,6 +136,12 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
135
136
136
137
config ['wav_ice_coupling' ] = 'ww3' in config ['COMP_WAV' ] and config ['COMP_ICE' ] == 'cice'
137
138
139
+ if config ["COMP_OCN" ] == "blom" :
140
+ if "ecosys" in case .get_value ("BLOM_TRACER_MODULES" ):
141
+ config ["dms_from_ocn" ] = "on"
142
+ else :
143
+ config ["dms_from_ocn" ] = "off"
144
+
138
145
# ----------------------------------------------------
139
146
# Initialize namelist defaults
140
147
# ----------------------------------------------------
@@ -156,7 +163,7 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
156
163
add_gusts = literal_to_python_value (nmlgen .get_value ("add_gusts" ), type_ = "logical" )
157
164
if add_gusts :
158
165
expect ("CAM70" in case .get_value ("COMPSET" ),"ERROR: add_gusts can only be set if CAM70 in compset {}" .format (case .get_value ("COMPSET" )))
159
-
166
+
160
167
# --------------------------------
161
168
# Overwrite: set component coupling frequencies
162
169
# --------------------------------
@@ -206,7 +213,7 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
206
213
mindt = min (mindt , cpl_dt )
207
214
208
215
# Here we convert "nsteps" to "nseconds", this simplifies the fortran
209
-
216
+
210
217
for val in ("REST" , "HIST" , "STOP" ):
211
218
if case .get_value (val + "_OPTION" ) == "nsteps" :
212
219
nsteps = case .get_value (val + "_N" )
@@ -217,7 +224,7 @@ def _create_drv_namelists(case, infile, confdir, nmlgen, files):
217
224
else :
218
225
nmlgen .set_value ("stop_n" , value = mindt * nsteps )
219
226
220
-
227
+
221
228
# sanity check
222
229
comp_atm = case .get_value ("COMP_ATM" )
223
230
if comp_atm is not None and comp_atm not in ("datm" , "xatm" , "satm" ):
@@ -640,7 +647,7 @@ def buildnml(case, caseroot, component):
640
647
major = line [- 2 ] if "MAJOR" in line else major
641
648
minor = line [- 2 ] if "MINOR" in line else minor
642
649
logger .debug ("ESMF version major {} minor {}" .format (major , minor ))
643
- expect (int (major ) >= 8 and int (minor ) >= 6 , "ESMF version should be 8.6 .1 or newer" )
650
+ expect (int (major ) >= 8 and int (minor ) >= 4 , "ESMF version should be 8.4 .1 or newer" )
644
651
645
652
confdir = os .path .join (case .get_value ("CASEBUILD" ), "cplconf" )
646
653
if not os .path .isdir (confdir ):
@@ -682,7 +689,7 @@ def buildnml(case, caseroot, component):
682
689
create_namelist_infile (case , user_nl_file , namelist_infile , infile_text )
683
690
infile = [namelist_infile ]
684
691
685
-
692
+
686
693
# create the files nuopc.runconfig, nuopc.runseq, drv_in and drv_flds_in
687
694
_create_drv_namelists (case , infile , confdir , nmlgen , files )
688
695
0 commit comments