Skip to content

Commit ec342bd

Browse files
authored
Merge pull request #31 from ekluzek/upnupopc
Bring updates needed for NUOPC
2 parents 1fbd6fd + c032088 commit ec342bd

7 files changed

Lines changed: 30 additions & 852 deletions

File tree

cime_config/buildlib

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,8 @@ def _build_mosart():
4141
paths = [ os.path.join(caseroot,"SourceMods","src.mosart"),
4242
os.path.join(srcroot,"components","mosart","src","riverroute"),
4343
os.path.join(srcroot,"components","mosart","src","cpl",driver)]
44+
if driver == 'nuopc':
45+
paths.append(os.path.join(srcroot,"cime","src","drivers","nuopc","nuopc_cap_share"))
4446

4547
with open(filepath_file, "w") as filepath:
4648
filepath.write("\n".join(paths))

cime_config/namelist_definition_mosart.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -167,7 +167,7 @@
167167
<values>
168168
<value rof_grid="r05" >$DIN_LOC_ROOT/rof/mosart/MOSART_routing_Global_0.5x0.5_c170601.nc</value>
169169
<value rof_grid="r8th" >$DIN_LOC_ROOT/rof/mosart/MOSART_Global_8th_20191007.nc</value>
170-
<value rof_grid="0.125nldas2">$DIN_LOC_ROOT/rof/mosart/MOSART_routing_0.125nldas2_c190415cdf5.nc</value>
170+
<value rof_grid="0.125nldas2">$DIN_LOC_ROOT/rof/mosart/MOSART_routing_0.125nldas2_cdf5_c200727.nc</value>
171171
</values>
172172
<desc>
173173
Full pathname of input datafile for RTM.

docs/ChangeLog

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,16 @@
1+
===============================================================
2+
Tag name: mosart1_0_37
3+
Originator(s): mvertens, erik, jedwards
4+
Date: August 06, 2020
5+
One-line Summary: Bring updates needed for NUOPC
6+
7+
Some more changes from @mvertens with updates for the NUOPC cap.
8+
There's a new nuopc_cap_share directory added. SetVM is made public
9+
in rof_comp_nuopc.F90 and some of the logging is slightly changed.
10+
RtmIO is now using ROFID rather than instance name.
11+
12+
Also convert the nldas2 file into NetCDF5 format from Jim Edwards.
13+
114
===============================================================
215
Tag name: mosart1_0_36
316
Originator(s): mvertens, sacks

src/cpl/nuopc/rof_comp_nuopc.F90

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ module rof_comp_nuopc
88
use NUOPC , only : NUOPC_CompDerive, NUOPC_CompSetEntryPoint, NUOPC_CompSpecialize
99
use NUOPC , only : NUOPC_CompFilterPhaseMap, NUOPC_CompAttributeGet, NUOPC_CompAttributeSet
1010
use NUOPC_Model , only : model_routine_SS => SetServices
11+
use NUOPC_Model , only : SetVM
1112
use NUOPC_Model , only : model_label_Advance => label_Advance
1213
use NUOPC_Model , only : model_label_DataInitialize => label_DataInitialize
1314
use NUOPC_Model , only : model_label_SetRunClock => label_SetRunClock
@@ -27,14 +28,15 @@ module rof_comp_nuopc
2728
use perf_mod , only : t_startf, t_stopf, t_barrierf
2829
use rof_import_export , only : advertise_fields, realize_fields
2930
use rof_import_export , only : import_fields, export_fields
30-
use rof_shr_methods , only : chkerr, state_setscalar, state_getscalar, state_diagnose, alarmInit
31-
use rof_shr_methods , only : set_component_logging, get_component_instance, log_clock_advance
31+
use nuopc_shr_methods , only : chkerr, state_setscalar, state_getscalar, state_diagnose, alarmInit
32+
use nuopc_shr_methods , only : set_component_logging, get_component_instance, log_clock_advance
3233

3334
implicit none
3435
private ! except
3536

3637
! Module routines
3738
public :: SetServices
39+
public :: SetVM
3840
private :: InitializeP0
3941
private :: InitializeAdvertise
4042
private :: InitializeRealize
@@ -715,13 +717,12 @@ subroutine ModelAdvance(gcomp, rc)
715717
if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=u_FILE_u)) return
716718
end if
717719

718-
if (masterproc) then
719-
call ESMF_ClockPrint(clock, options="currTime", preString="------>Advancing ROF from: ", rc=rc)
720-
if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=u_FILE_u)) return
721-
call ESMF_ClockPrint(clock, options="stopTime", preString="--------------------------------> to: ", rc=rc)
722-
if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=u_FILE_u)) return
720+
if (debug > 1) then
721+
call log_clock_advance(clock, 'MOSART', iulog, rc)
722+
if (ChkErr(rc,__LINE__,u_FILE_u)) return
723723
endif
724724

725+
725726
!--------------------------------
726727
! Reset shr logging to my original values
727728
!--------------------------------

src/cpl/nuopc/rof_import_export.F90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ module rof_import_export
99
use NUOPC_Model , only : NUOPC_ModelGet
1010
use shr_kind_mod , only : r8 => shr_kind_r8
1111
use shr_sys_mod , only : shr_sys_abort
12-
use rof_shr_methods , only : chkerr
12+
use nuopc_shr_methods , only : chkerr
1313
use RunoffMod , only : rtmCTL, TRunoff
1414
use RtmVar , only : iulog, nt_rtm, rtm_tracers
1515
use RtmSpmd , only : masterproc

0 commit comments

Comments
 (0)