From c47ecab31b3517ac9a362ed6e18ca178d435d7e7 Mon Sep 17 00:00:00 2001 From: Daniel Sarmiento Date: Wed, 18 Mar 2026 03:12:00 +0000 Subject: [PATCH 1/3] Add MOM6 logging updates --- .gitmodules | 2 +- .../ufs/cdeps_share/shr_is_restart_fh_mod.F90 | 54 +++++++++++++++---- MOM6-interface/CMakeLists.txt | 14 ++++- MOM6-interface/MOM6 | 2 +- MOM6-interface/mom6_files.cmake | 6 +-- 5 files changed, 59 insertions(+), 19 deletions(-) diff --git a/.gitmodules b/.gitmodules index 769f63a796..e625fbe2b0 100644 --- a/.gitmodules +++ b/.gitmodules @@ -25,7 +25,7 @@ [submodule "MOM6"] path = MOM6-interface/MOM6 url = https://github.com/NOAA-EMC/MOM6 - branch = dev/emc + branch = GFSV17 [submodule "CICE"] path = CICE-interface/CICE url = https://github.com/NOAA-EMC/CICE diff --git a/CDEPS-interface/ufs/cdeps_share/shr_is_restart_fh_mod.F90 b/CDEPS-interface/ufs/cdeps_share/shr_is_restart_fh_mod.F90 index 71a305f7ff..234040e0f1 100644 --- a/CDEPS-interface/ufs/cdeps_share/shr_is_restart_fh_mod.F90 +++ b/CDEPS-interface/ufs/cdeps_share/shr_is_restart_fh_mod.F90 @@ -122,49 +122,81 @@ end subroutine is_restart_fh !! !> @details Write a log file for a named component when a restart file is written !! - !! @param[in] nextTime the ESMF time at the end of a ModelAdvance - !! @param[in] startTime the ESMF time at the Model Start - !! @param[in] complog the named component + !! @param[in] nextTime the ESMF time at the end of a ModelAdvance + !! @param[in] startTime the ESMF time at the Model Start + !! @param[in] complog the named component + !! @param[in] prefixtime optional, if true log filename has time prefix + !! @param[in] lastrestart optional, if present, write the time of the last restart + !! @param[in] lastoutput optional, if present, write the filename written at this FH !! @param[out] rc return code !! !> @authorDenise.Worthen@noaa.gov !> @date 04-14-2025 - subroutine log_restart_fh(nextTime, startTime, complog, rc) + subroutine log_restart_fh(myTime, startTime, complog, prefixtime, lastrestart, lastoutput, rc) use ESMF, only : ESMF_SUCCESS, ESMF_MAXSTR, ESMF_Time, ESMF_TimeInterval use ESMF, only : ESMF_TimeGet, ESMF_TimeIntervalGet use ESMF, only : operator(==), operator(-) - type(ESMF_Time), intent(in) :: nextTime, startTime - character(len=*), intent(in) :: complog - integer, intent(out) :: rc + type(ESMF_Time), intent(in) :: myTime, startTime + character(len=*), intent(in) :: complog + logical, intent(in), optional :: prefixtime + type(ESMF_Time), intent(in), optional :: lastrestart + character(len=*), intent(in), optional :: lastoutput + integer, intent(out) :: rc ! local variables type(ESMF_TimeInterval) :: elapsedTime real(ESMF_KIND_R8) :: fhour character(ESMF_MAXSTR) :: filename character(ESMF_MAXSTR) :: nexttimestring + character(ESMF_MAXSTR) :: timestring integer :: fh_logunit integer :: yr,mon,day,hour,minute,sec ! time units + logical :: lprefix + character(ESMF_MAXSTR) :: lastout character(len=*), parameter :: subname='(log_restart_fh)' !----------------------------------------------------------------------- call ESMF_LogWrite(trim(subname)//": called", ESMF_LOGMSG_INFO) rc = ESMF_SUCCESS - elapsedTime = nextTime - startTime + lprefix = .false. + if (present(prefixtime)) then + lprefix = prefixtime + end if + lastout = '' + if (present(lastoutput)) then + lastout = trim(lastoutput) + end if + + elapsedTime = myTime - startTime call ESMF_TimeIntervalGet(elapsedTime, h_r8=fhour,rc=rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return - - call ESMF_TimeGet(nexttime, yy=yr, mm=mon, dd=day, h=hour, m=minute, s=sec, rc=rc) + call ESMF_TimeGet(myTime, yy=yr, mm=mon, dd=day, h=hour, m=minute, s=sec, rc=rc) if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return write(nexttimestring,'(6i8)')yr,mon,day,hour,minute,sec + if (lprefix) then + write(filename,'(i4.4,2(i2.2),A,3(i2.2),A)') yr, mon, day,'.', hour, minute, sec,'.'//trim(complog) + else + write(filename,'(a,i4.4)')'log.'//trim(complog)//'.f',int(fhour) + end if + if (present(lastrestart)) then + call ESMF_TimeGet(lastrestart, yy=yr, mm=mon, dd=day, h=hour, m=minute, s=sec, rc=rc) + if (ESMF_LogFoundError(rcToCheck=rc, msg=ESMF_LOGERR_PASSTHRU, line=__LINE__, file=__FILE__)) return + write(timestring,'(6i8)')yr,mon,day,hour,minute,sec + end if - write(filename,'(a,i4.4)')'log.'//trim(complog)//'.f',int(fhour) open(newunit=fh_logunit,file=trim(filename)) write(fh_logunit,'(a)')'completed: '//trim(complog) write(fh_logunit,'(a,f10.3)')'forecast hour:',fhour write(fh_logunit,'(a)')'valid time: '//trim(nexttimestring) + if (len_trim(lastout) > 0) then + write(fh_logunit,'(a)')'last output: '//trim(lastout) + end if + if (present(lastrestart)) then + write(fh_logunit,'(a)')'last restart: '//trim(timestring) + end if close(fh_logunit) end subroutine log_restart_fh diff --git a/MOM6-interface/CMakeLists.txt b/MOM6-interface/CMakeLists.txt index 99c325392a..f02344848d 100644 --- a/MOM6-interface/CMakeLists.txt +++ b/MOM6-interface/CMakeLists.txt @@ -1,6 +1,7 @@ ### MOM6 Fortran compiler flags if(CMAKE_Fortran_COMPILER_ID MATCHES "GNU") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -g -fbacktrace") + list(APPEND CDEPS_SHARE_DEFS "CPRGNU") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -fdefault-real-8 -fdefault-double-8") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -Waliasing -fcray-pointer -fconvert=big-endian -ffree-line-length-none -fno-range-check -fbacktrace") set(CMAKE_Fortran_FLAGS_RELEASE "-O2") @@ -16,6 +17,7 @@ elseif(CMAKE_Fortran_COMPILER_ID MATCHES "^(Intel)$") set(CMAKE_Fortran_FLAGS_RELEASE "-O2 -debug minimal -fp-model source") endif() set(CMAKE_Fortran_FLAGS_DEBUG "-O0 -check all -check noarg_temp_created -check nopointer -fpe0 -ftrapuv -init=snan,arrays") + list(APPEND CDEPS_SHARE_DEFS "CPRINTEL") set(CMAKE_Fortran_LINK_FLAGS "") elseif(CMAKE_Fortran_COMPILER_ID MATCHES "^(IntelLLVM)$") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -g -traceback") @@ -28,6 +30,7 @@ elseif(CMAKE_Fortran_COMPILER_ID MATCHES "^(IntelLLVM)$") endif() set(CMAKE_Fortran_FLAGS_DEBUG "-O0 -check all -check noarg_temp_created -check nopointer -fpe0 -ftrapuv -init=snan,arrays") set(CMAKE_Fortran_LINK_FLAGS "") + list(APPEND CDEPS_SHARE_DEFS "CPRINTEL") else() message(WARNING "Fortran compiler with ID ${CMAKE_Fortran_COMPILER_ID} will be used with CMake default options") endif() @@ -43,6 +46,9 @@ include("mom6_files.cmake") add_library(mom6_obj OBJECT ${mom6_src_files}) set_target_properties(mom6_obj PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/mod) target_include_directories(mom6_obj PRIVATE $) +target_compile_definitions(mom6_obj PRIVATE ${CDEPS_SHARE_DEFS} "DISABLE_FoX") +target_include_directories(mom6_obj PRIVATE $) +add_dependencies(mom6_obj cdeps) if(REGIONAL_MOM6) target_include_directories(mom6_obj PRIVATE $ @@ -54,7 +60,8 @@ endif() target_link_libraries(mom6_obj PRIVATE fms ESMF::ESMF stochastic_physics - NetCDF::NetCDF_Fortran) + NetCDF::NetCDF_Fortran + cdeps::cdeps) # OpenMP is disabled in MOM6 #if(OpenMP_Fortran_FOUND) # target_link_libraries(mom6_obj PRIVATE OpenMP::OpenMP_Fortran) @@ -63,6 +70,8 @@ target_link_libraries(mom6_obj PRIVATE fms add_library(mom6_nuopc_obj OBJECT ${mom6_nuopc_src_files}) set_target_properties(mom6_nuopc_obj PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/mod) target_include_directories(mom6_nuopc_obj PRIVATE $) +target_include_directories(mom6_nuopc_obj PRIVATE $) +add_dependencies(mom6_nuopc_obj cdeps) if(REGIONAL_MOM6) target_include_directories(mom6_nuopc_obj PRIVATE $ $) @@ -89,7 +98,8 @@ target_include_directories(mom6 PUBLIC $ Date: Fri, 20 Mar 2026 15:01:29 +0000 Subject: [PATCH 2/3] MOM6 filename changes --- tests/default_vars.sh | 2 +- tests/parm/diag_table/diag_table_cpld.IN | 96 ++++----- tests/parm/ufs.configure.datm_cdeps.IN | 5 +- .../ufs.configure.hafs_atm_ocn_wav_mom6.IN | 3 + tests/parm/ufs.configure.s2s.IN | 3 + tests/parm/ufs.configure.s2s_aoflux.IN | 3 + tests/parm/ufs.configure.s2sa.IN | 3 + tests/parm/ufs.configure.s2sw.IN | 3 + tests/parm/ufs.configure.s2sw_fast.IN | 3 + tests/parm/ufs.configure.s2swa.IN | 3 + tests/parm/ufs.configure.s2swa_fast.IN | 3 + tests/parm/ufs.configure.s2swl_fast.IN | 201 ++++++++++++++++++ tests/tests/cpld_control_gfsv17_iau | 2 +- 13 files changed, 279 insertions(+), 51 deletions(-) create mode 100644 tests/parm/ufs.configure.s2swl_fast.IN diff --git a/tests/default_vars.sh b/tests/default_vars.sh index 9f5e9b84a2..905b4b769d 100644 --- a/tests/default_vars.sh +++ b/tests/default_vars.sh @@ -1647,7 +1647,7 @@ export_mom6() { export DT_THERM_MOM6=3600 export MOM6_INPUT=MOM_input_100.IN export MOM6_OUTPUT_DIR=./MOM6_OUTPUT - export MOM6_OUTPUT_FH=6 + export MOM6_HISTFREQ_N=6 export MOM6_RESTART_DIR=./RESTART/ export MOM6_RESTART_SETTING=n export MOM6_RIVER_RUNOFF=False diff --git a/tests/parm/diag_table/diag_table_cpld.IN b/tests/parm/diag_table/diag_table_cpld.IN index 002b47673e..567eae89c0 100644 --- a/tests/parm/diag_table/diag_table_cpld.IN +++ b/tests/parm/diag_table/diag_table_cpld.IN @@ -4,65 +4,65 @@ "fv3_history", 0, "hours", 1, "hours", "time" "fv3_history2d", 0, "hours", 1, "hours", "time" ###################### -"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", 6, "hours", 1, "hours", "time", 6, "hours", "@[SYEAR] @[SMONTH] @[SDAY] @[CHOUR] 0 0" -"@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy", 1, "days", 1, "days", "time", 1, "days", "@[SYEAR] @[SMONTH] @[SDAY] @[CHOUR] 0 0" +"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", @[MOM6_HISTFREQ_N], "hours", 1, "hours", "time", @[MOM6_HISTFREQ_N], "hours", "@[SYEAR] @[SMONTH] @[SDAY] @[CHOUR] 0 0" +"@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy%2hr%2mi", 1, "days", 1, "days", "time", 1, "days", "@[SYEAR] @[SMONTH] @[SDAY] @[CHOUR] 0 0" ############################################## # static fields - "ocean_model", "geolon", "geolon", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolat", "geolat", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolon_c", "geolon_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolat_c", "geolat_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolon_u", "geolon_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolat_u", "geolat_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolon_v", "geolon_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "geolat_v", "geolat_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 -# "ocean_model", "depth_ocean", "depth_ocean", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 -# "ocean_model", "wet", "wet", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "wet_c", "wet_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "wet_u", "wet_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "wet_v", "wet_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "sin_rot", "sin_rot", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 - "ocean_model", "cos_rot", "cos_rot", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr", "all", .false., "none", 2 + "ocean_model", "geolon", "geolon", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolat", "geolat", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolon_c", "geolon_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolat_c", "geolat_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolon_u", "geolon_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolat_u", "geolat_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolon_v", "geolon_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolat_v", "geolat_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 +# "ocean_model", "depth_ocean", "depth_ocean", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 +# "ocean_model", "wet", "wet", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "wet_c", "wet_c", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "wet_u", "wet_u", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "wet_v", "wet_v", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "sin_rot", "sin_rot", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "cos_rot", "cos_rot", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 # ocean output TSUV and others - "ocean_model", "SSH", "SSH", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "SST", "SST", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "SSS", "SSS", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "speed", "speed", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "SSU", "SSU", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "SSV", "SSV", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "frazil", "frazil", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "ePBL_h_ML", "ePBL", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "MLD_003", "MLD_003", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "MLD_0125", "MLD_0125", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "tob", "tob", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 + "ocean_model", "SSH", "SSH", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "SST", "SST", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "SSS", "SSS", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "speed", "speed", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "SSU", "SSU", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "SSV", "SSV", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "frazil", "frazil", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "ePBL_h_ML", "ePBL", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "MLD_003", "MLD_003", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "MLD_0125", "MLD_0125", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "tob", "tob", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 # save daily SST - "ocean_model", "geolon", "geolon", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy", "all", .false., "none", 2 - "ocean_model", "geolat", "geolat", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy", "all", .false., "none", 2 - "ocean_model", "SST", "sst", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy", "all", .true., "none", 2 + "ocean_model", "geolon", "geolon", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "geolat", "geolat", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy%2hr%2mi", "all", .false., "none", 2 + "ocean_model", "SST", "sst", "@[MOM6_OUTPUT_DIR]/SST%4yr%2mo%2dy%2hr%2mi", "all", .true., "none", 2 # Z-Space Fields Provided for CMIP6 (CMOR Names): #=============================================== - "ocean_model_z","uo","uo" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model_z","vo","vo" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model_z","so","so" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model_z","temp","temp" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 + "ocean_model_z","uo","uo" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model_z","vo","vo" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model_z","so","so" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model_z","temp","temp" ,"@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 # forcing - "ocean_model", "taux", "taux", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "tauy", "tauy", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "latent", "latent", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "sensible", "sensible", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "SW", "SW", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "LW", "LW", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "evap", "evap", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "lprec", "lprec", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "lrunoff", "lrunoff", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 -# "ocean_model", "frunoff", "frunoff", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "fprec", "fprec", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "LwLatSens", "LwLatSens", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 - "ocean_model", "Heat_PmE", "Heat_PmE", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr","all",.true.,"none",2 + "ocean_model", "taux", "taux", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "tauy", "tauy", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "latent", "latent", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "sensible", "sensible", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "SW", "SW", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "LW", "LW", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "evap", "evap", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "lprec", "lprec", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "lrunoff", "lrunoff", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 +# "ocean_model", "frunoff", "frunoff", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "fprec", "fprec", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "LwLatSens", "LwLatSens", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 + "ocean_model", "Heat_PmE", "Heat_PmE", "@[MOM6_OUTPUT_DIR]/ocn%4yr%2mo%2dy%2hr%2mi","all",.true.,"none",2 # ### # FV3 variabls needed for NGGPS evaluation diff --git a/tests/parm/ufs.configure.datm_cdeps.IN b/tests/parm/ufs.configure.datm_cdeps.IN index d451370ec2..6d81980869 100644 --- a/tests/parm/ufs.configure.datm_cdeps.IN +++ b/tests/parm/ufs.configure.datm_cdeps.IN @@ -45,6 +45,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # @@ -103,7 +106,7 @@ MED_attributes:: history_n = 1 history_option = nhours history_ymd = -999 - coupling_mode = ufs.nfrac.aoflux + coupling_mode = @[CPLMODE] mapuv_with_cart3d = @[MAPUV3D] pio_typename = @[CMEPS_PIO_FORMAT] pio_numiotasks = @[CMEPS_PIO_IOTASKS] diff --git a/tests/parm/ufs.configure.hafs_atm_ocn_wav_mom6.IN b/tests/parm/ufs.configure.hafs_atm_ocn_wav_mom6.IN index 85ffdf942a..dab98c84bd 100644 --- a/tests/parm/ufs.configure.hafs_atm_ocn_wav_mom6.IN +++ b/tests/parm/ufs.configure.hafs_atm_ocn_wav_mom6.IN @@ -67,6 +67,9 @@ OCN_attributes:: set_missing_stks_to_zero = true eps_imesh = 2.5e-1 mesh_ocn = @[MESH_OCN] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # WAV # diff --git a/tests/parm/ufs.configure.s2s.IN b/tests/parm/ufs.configure.s2s.IN index ba1950a9e7..c7e9aa3222 100644 --- a/tests/parm/ufs.configure.s2s.IN +++ b/tests/parm/ufs.configure.s2s.IN @@ -41,6 +41,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2s_aoflux.IN b/tests/parm/ufs.configure.s2s_aoflux.IN index bb96b16d12..5fab4fcf20 100644 --- a/tests/parm/ufs.configure.s2s_aoflux.IN +++ b/tests/parm/ufs.configure.s2s_aoflux.IN @@ -41,6 +41,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2sa.IN b/tests/parm/ufs.configure.s2sa.IN index 6c3317e1d3..87fe9a2c4c 100644 --- a/tests/parm/ufs.configure.s2sa.IN +++ b/tests/parm/ufs.configure.s2sa.IN @@ -49,6 +49,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2sw.IN b/tests/parm/ufs.configure.s2sw.IN index f8551e47e1..5509ed6d33 100644 --- a/tests/parm/ufs.configure.s2sw.IN +++ b/tests/parm/ufs.configure.s2sw.IN @@ -41,6 +41,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2sw_fast.IN b/tests/parm/ufs.configure.s2sw_fast.IN index 4954230d7c..349ace7002 100644 --- a/tests/parm/ufs.configure.s2sw_fast.IN +++ b/tests/parm/ufs.configure.s2sw_fast.IN @@ -41,6 +41,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2swa.IN b/tests/parm/ufs.configure.s2swa.IN index 25f9dbf0d0..daf227f85c 100644 --- a/tests/parm/ufs.configure.s2swa.IN +++ b/tests/parm/ufs.configure.s2swa.IN @@ -49,6 +49,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2swa_fast.IN b/tests/parm/ufs.configure.s2swa_fast.IN index e25094da79..27a55cdda7 100644 --- a/tests/parm/ufs.configure.s2swa_fast.IN +++ b/tests/parm/ufs.configure.s2swa_fast.IN @@ -49,6 +49,9 @@ OCN_attributes:: mesh_ocn = @[MESH_OCN] use_coldstart = @[use_coldstart] use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] :: # ICE # diff --git a/tests/parm/ufs.configure.s2swl_fast.IN b/tests/parm/ufs.configure.s2swl_fast.IN new file mode 100644 index 0000000000..fdb687bb6e --- /dev/null +++ b/tests/parm/ufs.configure.s2swl_fast.IN @@ -0,0 +1,201 @@ +############################################# +#### UFS Run-Time Configuration File ###### +############################################# + +# ESMF # +logKindFlag: ESMF_LOGKIND_MULTI +globalResourceControl: @[ESMF_THREADING] + +# EARTH # +EARTH_component_list: MED ATM OCN ICE WAV LND +EARTH_attributes:: + Verbosity = 0 +:: + +# MED # +MED_model: @[med_model] +MED_petlist_bounds: @[med_petlist_bounds] +MED_omp_num_threads: @[med_omp_num_threads] + +# ATM # +ATM_model: @[atm_model] +ATM_petlist_bounds: @[atm_petlist_bounds] +ATM_omp_num_threads: @[atm_omp_num_threads] +ATM_attributes:: + Verbosity = 0 + DumpFields = false + ProfileMemory = false + OverwriteSlice = true +:: + +# OCN # +OCN_model: @[ocn_model] +OCN_petlist_bounds: @[ocn_petlist_bounds] +OCN_omp_num_threads: @[ocn_omp_num_threads] +OCN_attributes:: + Verbosity = 0 + DumpFields = false + ProfileMemory = false + OverwriteSlice = true + mesh_ocn = @[MESH_OCN] + use_coldstart = @[use_coldstart] + use_mommesh = @[use_mommesh] + mom6_output_dir = @[MOM6_OUTPUT_DIR] + mom6_output_fh = @[MOM6_HISTFREQ_N] + mom6_restart_dir = @[MOM6_RESTART_DIR] +:: + +# ICE # +ICE_model: @[ice_model] +ICE_petlist_bounds: @[ice_petlist_bounds] +ICE_omp_num_threads: @[ice_omp_num_threads] +ICE_attributes:: + Verbosity = 0 + DumpFields = false + ProfileMemory = false + OverwriteSlice = true + mesh_ice = @[MESH_ICE] + eps_imesh = @[eps_imesh] + stop_n = @[RESTART_N] + stop_option = nhours + stop_ymd = -999 +:: + +# WAV # +WAV_model: @[wav_model] +WAV_petlist_bounds: @[wav_petlist_bounds] +WAV_omp_num_threads: @[wav_omp_num_threads] +WAV_attributes:: + Verbosity = 0 + OverwriteSlice = false + mesh_wav = @[MESH_WAV] + user_histname = @[WW3_user_histname] + use_historync = @[WW3_historync] + use_restartnc = @[WW3_restartnc] + restart_from_binary = @[WW3_restart_from_binary] + pio_typename = @[WW3_PIO_FORMAT] + pio_numiotasks = @[WW3_PIO_IOTASKS] + pio_stride = @[WW3_PIO_STRIDE] + pio_rearranger = @[WW3_PIO_REARR] + pio_root = @[WW3_PIO_ROOT] +:: + +# LND # +LND_model: @[lnd_model] +LND_petlist_bounds: @[lnd_petlist_bounds] +LND_omp_num_threads: @[lnd_omp_num_threads] +LND_attributes:: + Verbosity = 1 + Diagnostic = 0 + mosaic_file = @[mosaic_file] + input_dir = @[lnd_input_dir] + fixed_dir = @[lnd_fixed_dir] + ic_type = @[lnd_ic_type] + layout = @[layout_x]:@[layout_y] # need to be consistent with number of PEs + num_soil_levels = 4 + forcing_height = 10 + soil_level_thickness = 0.10:0.30:0.60:1.00 + soil_level_nodes = 0.05:0.25:0.70:1.50 + dynamic_vegetation_option = 4 + canopy_stomatal_resistance_option = 2 + soil_wetness_option = 1 + runoff_option = 1 + surface_exchange_option = 3 + supercooled_soilwater_option = 1 + frozen_soil_adjust_option = 1 + radiative_transfer_option = 3 + snow_albedo_option = @[snow_albedo_option] + precip_partition_option = @[precip_partition_option] + soil_temp_lower_bdy_option = 2 + soil_temp_time_scheme_option = 3 + surface_evap_resistance_option = 1 # not used, it is fixed to 4 in sfc_noahmp_drv.F90 + glacier_option = 1 + surface_thermal_roughness_option = 2 + output_freq = 3600 + restart_freq = -1 + calc_snet = @[CALC_SNET] + initial_albedo = @[initial_albedo] +:: + +# CMEPS warm run sequence +runSeq:: +@@[coupling_interval_slow_sec] + MED med_phases_prep_ocn_avg + MED -> OCN :remapMethod=redist + OCN + @@[coupling_interval_fast_sec] + MED med_phases_prep_atm + MED med_phases_prep_ice + MED med_phases_prep_wav_accum + MED med_phases_prep_wav_avg + MED med_phases_prep_lnd + MED -> ATM :remapMethod=redist + MED -> ICE :remapMethod=redist + MED -> WAV :remapMethod=redist + MED -> LND :remapMethod=redist + ATM + ICE + WAV + LND + ATM -> MED :remapMethod=redist + MED med_phases_post_atm + ICE -> MED :remapMethod=redist + MED med_phases_post_ice + WAV -> MED :remapMethod=redist + MED med_phases_post_wav + LND -> MED :remapMethod=redist + MED med_phases_post_lnd + MED med_phases_ocnalb_run + MED med_phases_prep_ocn_accum + @ + OCN -> MED :remapMethod=redist + MED med_phases_post_ocn + MED med_phases_restart_write +@ +:: + +# CMEPS variables + +DRIVER_attributes:: +:: + +MED_attributes:: + ATM_model = @[atm_model] + ICE_model = @[ice_model] + OCN_model = @[ocn_model] + WAV_model = @[wav_model] + LND_model = @[lnd_model] + coupling_mode = @[CPLMODE] + pio_typename = @[CMEPS_PIO_FORMAT] + pio_numiotasks = @[CMEPS_PIO_IOTASKS] + pio_stride = @[CMEPS_PIO_STRIDE] + pio_rearranger = @[CMEPS_PIO_REARR] + pio_root = @[CMEPS_PIO_ROOT] + ocean_albedo_limit = @[ocean_albedo_limit] + mapuv_with_cart3d = @[MAPUV3D] +:: + +ALLCOMP_attributes:: + ScalarFieldCount = 3 + ScalarFieldIdxGridNX = 1 + ScalarFieldIdxGridNY = 2 + ScalarFieldIdxGridNTile = 3 + ScalarFieldName = cpl_scalars + start_type = @[RUNTYPE] + restart_dir = @[CMEPS_RESTART_DIR] + case_name = ufs.cpld + restart_n = @[RESTART_N] + restart_option = nhours + restart_ymd = -999 + write_restart_at_endofrun = @[WRITE_ENDOFRUN_RESTART] + dbug_flag = @[cap_dbug_flag] + stop_n = @[FHMAX] + stop_option = nhours + stop_ymd = -999 + orb_eccen = 1.e36 + orb_iyear = 2000 + orb_iyear_align = 2000 + orb_mode = fixed_year + orb_mvelp = 1.e36 + orb_obliq = 1.e36 +:: diff --git a/tests/tests/cpld_control_gfsv17_iau b/tests/tests/cpld_control_gfsv17_iau index 865806a036..d614bd68a2 100644 --- a/tests/tests/cpld_control_gfsv17_iau +++ b/tests/tests/cpld_control_gfsv17_iau @@ -46,7 +46,7 @@ export LIST_FILES="sfcf024.nc \ RESTART/iced.2021-03-23-43200.nc \ RESTART/ufs.cpld.cpl.r.2021-03-23-43200.nc \ ufs.cpld.ww3.r.2021-03-23-43200.nc \ - MOM6_OUTPUT/ocn_2021_03_23_09.nc \ + MOM6_OUTPUT/ocn_2021_03_23_09_00.nc \ history/iceh_06h.2021-03-23-43200.nc \ 20210323.120000.out_pnt.ww3.nc \ 20210323.120000.out_grd.ww3 " From fb5a3f2895641bd7ebe53eb474922173b8adc90e Mon Sep 17 00:00:00 2001 From: Daniel Sarmiento Date: Tue, 31 Mar 2026 14:31:44 +0000 Subject: [PATCH 3/3] Update UFSATM hash :: IAU FH00 fix --- UFSATM | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/UFSATM b/UFSATM index f5abfc07ba..f354fe651e 160000 --- a/UFSATM +++ b/UFSATM @@ -1 +1 @@ -Subproject commit f5abfc07ba78b86d1fd885a817e17821b8b8b3fb +Subproject commit f354fe651e888e26532d391e14f88d02b83f2a7f