Skip to content

Commit

Permalink
initial changes for EP5a ICs
Browse files Browse the repository at this point in the history
  • Loading branch information
NeilBarton-NOAA committed Feb 7, 2024
1 parent 7d68b0b commit ecd7d73
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 17 deletions.
6 changes: 6 additions & 0 deletions parm/config/gefs/config.stage_ic
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ echo "BEGIN: config.stage_ic"
source "${EXPDIR}/config.resources" stage_ic

case "${CASE}" in
"C384")
export CPL_ATMIC=""
export CPL_ICEIC=""
export CPL_OCNIC=""
export CPL_WAVIC=""
;;
"C48")
export CPL_ATMIC="gefs_test"
export CPL_ICEIC="gefs_test"
Expand Down
2 changes: 2 additions & 0 deletions parm/config/gefs/yaml/defaults.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,5 @@ base:
DO_JEDILANDDA: "NO"
DO_MERGENSST: "NO"
FHMAX_GFS: 120
BASE_CPLIC: "/scratch2/NCEPDEV/stmp3/Neil.Barton/ICs"

23 changes: 13 additions & 10 deletions scripts/exglobal_stage_ic.sh
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,10 @@ for MEMDIR in "${MEMDIR_ARRAY[@]}"; do
if [[ "${DO_OCN:-}" = "YES" ]]; then
RUN=${rCDUMP} YMD=${gPDY} HH=${gcyc} generate_com COM_OCEAN_RESTART_PREV:COM_OCEAN_RESTART_TMPL
[[ ! -d "${COM_OCEAN_RESTART_PREV}" ]] && mkdir -p "${COM_OCEAN_RESTART_PREV}"
src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/${PDY}.${cyc}0000.MOM.res.nc"
tgt="${COM_OCEAN_RESTART_PREV}/${PDY}.${cyc}0000.MOM.res.nc"
#src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/${PDY}.${cyc}0000.MOM.res.nc"
#tgt="${COM_OCEAN_RESTART_PREV}/${PDY}.${cyc}0000.MOM.res.nc"
src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/ORAS5.mx${OCNRES}.ic.nc"
tgt="${COM_OCEAN_RESTART_PREV}/ORAS5.mx${OCNRES}.ic.nc"
${NCP} "${src}" "${tgt}"
rc=$?
((rc != 0)) && error_message "${src}" "${tgt}" "${rc}"
Expand All @@ -88,14 +90,15 @@ for MEMDIR in "${MEMDIR_ARRAY[@]}"; do
# Nothing more to do for these resolutions
;;
"025" )
for nn in $(seq 1 3); do
src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/${PDY}.${cyc}0000.MOM.res_${nn}.nc"
tgt="${COM_OCEAN_RESTART_PREV}/${PDY}.${cyc}0000.MOM.res_${nn}.nc"
${NCP} "${src}" "${tgt}"
rc=$?
((rc != 0)) && error_message "${src}" "${tgt}" "${rc}"
err=$((err + rc))
done
# Nothing to do for ORAS5 initialization
#for nn in $(seq 1 3); do
# src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/${PDY}.${cyc}0000.MOM.res_${nn}.nc"
# tgt="${COM_OCEAN_RESTART_PREV}/${PDY}.${cyc}0000.MOM.res_${nn}.nc"
# ${NCP} "${src}" "${tgt}"
# rc=$?
# ((rc != 0)) && error_message "${src}" "${tgt}" "${rc}"
# err=$((err + rc))
#done
;;
*)
echo "FATAL ERROR: Unsupported ocean resolution ${OCNRES}"
Expand Down
15 changes: 8 additions & 7 deletions workflow/rocoto/gefs_tasks.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,15 +30,16 @@ def stage_ic(self):
if self.app_config.do_ocean:
ocn_res = f"{self._base.get('OCNRES', '025'):03d}"
prefix = f"{cpl_ic['BASE_CPLIC']}/{cpl_ic['CPL_OCNIC']}/@Y@m@d@H/mem000/ocean"
data = f"{prefix}/@Y@m@[email protected]"
#data = f"{prefix}/@Y@m@[email protected]"
data = f"{prefix}/ORAS5.mx{ocn_res}.ic.nc"
dep_dict = {'type': 'data', 'data': data}
deps.append(rocoto.add_dependency(dep_dict))
if ocn_res in ['025']:
# 0.25 degree ocean model also has these additional restarts
for res in [f'res_{res_index}' for res_index in range(1, 4)]:
data = f"{prefix}/@Y@m@[email protected].{res}.nc"
dep_dict = {'type': 'data', 'data': data}
deps.append(rocoto.add_dependency(dep_dict))
#if ocn_res in ['025']:
# # 0.25 degree ocean model also has these additional restarts
# for res in [f'res_{res_index}' for res_index in range(1, 4)]:
# data = f"{prefix}/@Y@m@[email protected].{res}.nc"
# dep_dict = {'type': 'data', 'data': data}
# deps.append(rocoto.add_dependency(dep_dict))

# Ice ICs
if self.app_config.do_ice:
Expand Down

0 comments on commit ecd7d73

Please sign in to comment.