Skip to content

Commit 6ccea3e

Browse files
Use nuopc labels in fv3cap. Refactor ModelAdvance in fv3cap (ufs-community#654)
* Update fv3atm to use NUOPC semantic labels in fv3cap, and refactor ModelAdvance. * Update NEMS. Removed NEMS grid component (no need to set PE_MEMBER01: in model_configure anymore) * Cleanup CMakeLists.txt
1 parent 766f511 commit 6ccea3e

21 files changed

+2201
-2251
lines changed

CMakeLists.txt

+3-34
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ if(INLINE_POST)
131131
endif()
132132

133133
# See https://github.com/NOAA-EMC/NCEPLIBS-nemsio/pull/22
134-
target_link_libraries(nemsio::nemsio INTERFACE w3emc::w3emc_d bacio::bacio_4)
134+
target_link_libraries(nemsio::nemsio INTERFACE w3nco::w3nco_d bacio::bacio_4)
135135

136136
# Configure Python
137137
find_package(Python 3 REQUIRED COMPONENTS Interpreter)
@@ -217,21 +217,16 @@ endif()
217217
###############################################################################
218218
### UFS Library [NEMS]
219219
###############################################################################
220-
list(APPEND _nems_srcs NEMS/src/module_NEMS_UTILS.F90
221-
NEMS/src/module_EARTH_GRID_COMP.F90
222-
NEMS/src/module_NEMS_GRID_COMP.F90
220+
list(APPEND _nems_srcs NEMS/src/module_EARTH_GRID_COMP.F90
223221
NEMS/src/module_NEMS_Rusage.F90
224222
NEMS/src/nems_c_rusage.c)
225223

226224
add_library(ufs ${_nems_srcs})
227225
set_target_properties(ufs PROPERTIES Fortran_MODULE_DIRECTORY
228226
${CMAKE_CURRENT_BINARY_DIR}/mod)
229-
target_include_directories(ufs PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/NEMS/src)
230227
target_include_directories(ufs INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_BINARY_DIR}/mod>
231228
$<INSTALL_INTERFACE:mod>)
232229

233-
list(APPEND _ufs_defs_private ESMF_VERSION_MAJOR=${ESMF_VERSION_MAJOR})
234-
235230
if(JEDI_DRIVER)
236231
list(APPEND _ufs_defs_private JEDI_DRIVER=ON)
237232
endif()
@@ -255,11 +250,6 @@ if(STOCH_PHYS)
255250
list(APPEND _ufs_libs_public stochastic_physics)
256251
endif()
257252

258-
if(FMS)
259-
add_dependencies(ufs fms)
260-
list(APPEND _ufs_defs_private FRONT_FMS)
261-
endif()
262-
263253
if(NEMSdatm)
264254
add_dependencies(ufs datatm)
265255
list(APPEND _ufs_defs_private FRONT_NEMS_DATM=datm)
@@ -304,28 +294,7 @@ target_link_libraries(ufs PUBLIC "${_ufs_libs_public}")
304294
###############################################################################
305295
add_executable(ufs_model NEMS/src/MAIN_NEMS.F90)
306296
add_dependencies(ufs_model ufs)
307-
308-
list(APPEND _ufs_model_defs_private ESMF_VERSION_MAJOR=${ESMF_VERSION_MAJOR})
309-
310-
set_target_properties(ufs_model PROPERTIES Fortran_MODULE_DIRECTORY
311-
${CMAKE_CURRENT_BINARY_DIR}/mod)
312-
313-
target_include_directories(ufs_model PRIVATE ${CMAKE_CURRENT_BINARY_DIR}/NEMS/src)
314-
315-
if(WW3)
316-
list(APPEND _ufs_model_defs_private FRONT_WW3=WMESMFMD)
317-
target_include_directories(ufs_model PRIVATE ${CMAKE_CURRENT_SOURCE_DIR}/WW3/model/mod)
318-
endif()
319-
320-
target_compile_definitions(ufs_model PRIVATE "${_ufs_model_defs_private}")
321-
322-
if(NEMSdatm OR CDEPS)
323-
target_link_libraries(ufs_model PUBLIC ufs w3nco::w3nco_d)
324-
endif()
325-
326-
target_link_libraries(ufs_model PRIVATE ufs
327-
esmf
328-
NetCDF::NetCDF_Fortran)
297+
target_link_libraries(ufs_model ufs esmf w3nco::w3nco_d)
329298

330299
###############################################################################
331300
### Install

tests/RegressionTests_cheyenne.gnu.log

+89-89
Large diffs are not rendered by default.

tests/RegressionTests_cheyenne.intel.log

+304-304
Large diffs are not rendered by default.

tests/RegressionTests_gaea.intel.log

+298-298
Large diffs are not rendered by default.

tests/RegressionTests_hera.gnu.log

+99-99
Large diffs are not rendered by default.

tests/RegressionTests_hera.intel.log

+313-313
Large diffs are not rendered by default.

tests/RegressionTests_jet.intel.log

+291-291
Large diffs are not rendered by default.

tests/RegressionTests_orion.intel.log

+310-310
Large diffs are not rendered by default.

tests/RegressionTests_wcoss_cray.log

+175-175
Large diffs are not rendered by default.

tests/RegressionTests_wcoss_dell_p3.log

+310-310
Large diffs are not rendered by default.

tests/parm/datm_cdeps_configure.IN

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
print_esmf: .true.
2-
total_member: 1
3-
PE_MEMBER01: @[TASKS]
42
start_year: @[SYEAR]
53
start_month: @[SMONTH]
64
start_day: @[SDAY]

tests/parm/datm_configure.IN

+2-5
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,15 @@
1-
total_member: 1
21
print_esmf: .true.
3-
PE_MEMBER01: @[TASKS]
42
start_year: @[SYEAR]
53
start_month: @[SMONTH]
64
start_day: @[SDAY]
75
start_hour: @[SHOUR]
86
start_minute: 0
97
start_second: 0
108
nhours_fcst: @[FHMAX]
11-
RUN_CONTINUE: .false.
12-
ENS_SPS: .false.
13-
calendar: 'julian'
149
fhrot: @[FHROT]
1510

11+
calendar: 'julian'
12+
1613
dt_atmos: @[DT_ATMOS]
1714
atm_coupling_interval_sec: @[coupling_interval_fast_sec]
1815

tests/parm/esg_HAFS_v0_hwrf-model_configure.IN

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
total_member: 1
2-
PE_MEMBER01: 80
1+
print_esmf: .false.
32
start_year: 2020
43
start_month: 08
54
start_day: 10
@@ -38,5 +37,3 @@ nfhout: 3
3837
nfhmax_hf: 12
3938
nfhout_hf: 1
4039
nsout: -1
41-
42-
print_esmf: .false.

tests/parm/gsd_sar-model_configure.IN

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
total_member: 1
2-
PE_MEMBER01: 24
1+
print_esmf: .false.
32
start_year: 2019
43
start_month: 05
54
start_day: 20
@@ -13,7 +12,6 @@ restart_interval: 0
1312
output_1st_tstep_rst: .false.
1413

1514
quilting: .true.
16-
print_esmf: .false.
1715
write_groups: 1
1816
write_tasks_per_group: 4
1917
num_files: 2

tests/parm/model_configure.IN

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
total_member: @[ENS_NUM]
21
print_esmf: .true.
3-
PE_MEMBER01: @[TASKS]
42
start_year: @[SYEAR]
53
start_month: @[SMONTH]
64
start_day: @[SDAY]
75
start_hour: @[SHOUR]
86
start_minute: 0
97
start_second: 0
108
nhours_fcst: @[FHMAX]
9+
fhrot: @[FHROT]
1110

1211
dt_atmos: @[DT_ATMOS]
1312
calendar: 'julian'
1413
restart_interval: @[RESTART_INTERVAL]
15-
fhrot: @[FHROT]
1614
output_1st_tstep_rst: .false.
1715
atm_coupling_interval_sec: @[coupling_interval_fast_sec]
1816

tests/parm/model_configure_hafs.IN

+1-4
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,12 @@
11
print_esmf: .true.
2-
3-
total_member: 1
4-
PE_MEMBER01: @[TASKS]
5-
62
start_year: 2018
73
start_month: 10
84
start_day: 15
95
start_hour: 00
106
start_minute: 0
117
start_second: 0
128
nhours_fcst: 24
9+
1310
dt_atmos: 225
1411
calendar: 'julian'
1512
restart_interval: 0

tests/parm/model_configure_regional.IN

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
print_esmf: .true.
2-
PE_MEMBER01: @[TASKS]
3-
42
start_year: 2018
53
start_month: 10
64
start_day: 15

tests/parm/stretched-nest-quilt-model_configure.IN

-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
total_member: 1
21
print_esmf: .true.
3-
PE_MEMBER01: 108
42
start_year: 2018
53
start_month: 10
64
start_day: 15

tests/rt.sh

+1-1
Original file line numberDiff line numberDiff line change
@@ -414,7 +414,7 @@ if [[ $TESTS_FILE =~ '35d' ]]; then
414414
TEST_35D=true
415415
fi
416416

417-
BL_DATE=20210714
417+
BL_DATE=20210716
418418
if [[ $MACHINE_ID = hera.* ]] || [[ $MACHINE_ID = orion.* ]] || [[ $MACHINE_ID = cheyenne.* ]] || [[ $MACHINE_ID = gaea.* ]] || [[ $MACHINE_ID = jet.* ]]; then
419419
RTPWD=${RTPWD:-$DISKNM/NEMSfv3gfs/develop-${BL_DATE}/${RT_COMPILER^^}}
420420
else

0 commit comments

Comments
 (0)