Skip to content

Commit

Permalink
Update stage IC to handle ocean perturbations (#2364)
Browse files Browse the repository at this point in the history
This PR adds the option to stage ocean perturbation files for ensemble
forecasts. These perturbation files are used in GEFS forecasts.
A new variable is introduced in config.base to use the ocean
perturbation files.
This PR does not include using these perturbation files. A future PR
will address this.
  • Loading branch information
NeilBarton-NOAA authored Mar 1, 2024
1 parent 8efe05f commit 23c2552
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
4 changes: 4 additions & 0 deletions parm/config/gefs/config.base.emc.dyn
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,10 @@ export NMEM_ENS=@NMEM_ENS@
export ENSMEM=${ENSMEM:-"000"}
export MEMDIR="mem${ENSMEM}"

# initialize ocean ensemble members with perturbations
# if true, only occurs for members greater than zero
export OCN_ENS_PERTURB_FILES=false

export DOIAU="NO" # While we are not doing IAU, we may want to warm start w/ IAU in the future
# Check if cycle is cold starting
if [[ "${EXP_WARM_START}" = ".false." ]]; then
Expand Down
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
11 changes: 11 additions & 0 deletions scripts/exglobal_stage_ic.sh
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,17 @@ for MEMDIR in "${MEMDIR_ARRAY[@]}"; do
;;
esac

# Ocean Perturbation Files
# Extra zero on MEMDIR ensure we have a number even if the string is empty
if (( 0${MEMDIR:3} > 0 )) && [[ "${OCN_ENS_PERTURB_FILES:-false}" == "true" ]]; then
src="${BASE_CPLIC}/${CPL_OCNIC:-}/${PDY}${cyc}/${MEMDIR}/ocean/${PDY}.${cyc}0000.mom6_increment.nc"
tgt="${COM_OCEAN_RESTART_PREV}/${PDY}.${cyc}0000.mom6_increment.nc"
${NCP} "${src}" "${tgt}"
rc=${?}
((rc != 0)) && error_message "${src}" "${tgt}" "${rc}"
err=$((err + rc))
fi

# TODO: Do mediator restarts exists in a ATMW configuration?
# TODO: No mediator is presumably involved in an ATMA configuration
if [[ ${EXP_WARM_START:-".false."} = ".true." ]]; then
Expand Down

0 comments on commit 23c2552

Please sign in to comment.