Skip to content

Commit

Permalink
Define the recenter cycles so the recenter tasks don't run for all th…
Browse files Browse the repository at this point in the history
…e EnKF cycles (NOAA-EMC#421)
  • Loading branch information
chunhuazhou authored Aug 30, 2022
1 parent 4c19262 commit e072e1b
Show file tree
Hide file tree
Showing 5 changed files with 40 additions and 8 deletions.
6 changes: 3 additions & 3 deletions scripts/exregional_run_recenter.sh
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,9 @@ for imem in $(seq 1 $nens)
dynvarfile=${bkpath}/fv_core.res.tile1.nc
tracerfile=${bkpath}/fv_tracer.res.tile1.nc
if [ -r "${dynvarfile}" ] && [ -r "${tracerfile}" ] ; then
ln -sf ${bkpath}/fv_core.res.tile1.nc ./fv3sar_tile1_mem${memberstring}_dynvar
ln -sf ${bkpath}/fv_tracer.res.tile1.nc ./fv3sar_tile1_mem${memberstring}_tracer
ln -sf ${bkpath}/sfc_data.nc ./fv3sar_tile1_mem${memberstring}_sfcvar
cp_vrfy ${bkpath}/fv_core.res.tile1.nc ./fv3sar_tile1_mem${memberstring}_dynvar
cp_vrfy ${bkpath}/fv_tracer.res.tile1.nc ./fv3sar_tile1_mem${memberstring}_tracer
cp_vrfy ${bkpath}/sfc_data.nc ./fv3sar_tile1_mem${memberstring}_sfcvar
ln -sf ${bkpath}/fv_core.res.tile1.nc ./rec_fv3sar_tile1_mem${memberstring}_dynvar
ln -sf ${bkpath}/fv_tracer.res.tile1.nc ./rec_fv3sar_tile1_mem${memberstring}_tracer
ln -sf ${bkpath}/sfc_data.nc ./rec_fv3sar_tile1_mem${memberstring}_sfcvar
Expand Down
8 changes: 5 additions & 3 deletions ush/config.sh.RRFS_CONUS_3km_ens.2022HWT.CYCL
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,13 @@ BOUNDARY_LEN_HRS="6"
# avaialble retro period:
# 20210511-20210531; 20210718-20210801
DATE_FIRST_CYCL="20220620"
DATE_LAST_CYCL="20220730"
DATE_LAST_CYCL="20220830"
CYCL_HRS=( "00" "12" )
CYCL_HRS=( "18" )
CYCL_HRS_SPINSTART=("03" "15")
CYCL_HRS_PRODSTART=("09" "21")
CYCL_HRS_PRODSTART=("18")
CYCL_HRS_RECENTER=("19")
#CYCLEMONTH="5"
#CYCLEDAY="11-12"

Expand All @@ -95,8 +96,9 @@ INITIAL_CYCLEDEF="${DATE_FIRST_CYCL}1800 ${DATE_LAST_CYCL}2300 24:00:00"
BOUNDARY_CYCLEDEF="${DATE_FIRST_CYCL}1800 ${DATE_LAST_CYCL}2300 24:00:00"
#PROD_CYCLEDEF="${DATE_FIRST_CYCL}2100 ${DATE_LAST_CYCL}2300 01:00:00"
#POSTPROC_CYCLEDEF="${DATE_FIRST_CYCL}2100 ${DATE_LAST_CYCL}2300 01:00:00"
PROD_CYCLEDEF="00 18-23 * 6-7 2022 *"
POSTPROC_CYCLEDEF="00 18-23 * 6-7 2022 *"
PROD_CYCLEDEF="00 18-23 * 6-8 2022 *"
RECENTER_CYCLEDEF="00 19 * 6-8 2022 *"
POSTPROC_CYCLEDEF="00 18-23 * 6-8 2022 *"
#POSTPROC_LONG_CYCLEDEF="${DATE_FIRST_CYCL}0900 ${DATE_LAST_CYCL}2300 03:00:00"
ARCHIVE_CYCLEDEF="${DATE_FIRST_CYCL}1500 ${DATE_LAST_CYCL}2300 24:00:00"
if [[ $DO_SPINUP == "TRUE" ]] ; then
Expand Down
9 changes: 9 additions & 0 deletions ush/config_defaults.sh
Original file line number Diff line number Diff line change
Expand Up @@ -479,6 +479,9 @@ WFLOW_LAUNCH_LOG_FN="log.launch_FV3LAM_wflow"
# An array containing the hours of the day at which the product cycle starts,
# from cold start input or from spin-up cycle forcast
#
# CYCL_HRS_RECENTER:
# An array containing the hours of the day at which the ensemble recenter is on
#
# BOUNDARY_LEN_HRS
# The length of boundary condition for normal forecast, in integer hours.
#
Expand Down Expand Up @@ -518,6 +521,7 @@ DATE_LAST_CYCL="YYYYMMDD"
CYCL_HRS=( "HH1" "HH2" )
CYCL_HRS_SPINSTART=( "HH1" "HH2" )
CYCL_HRS_PRODSTART=( "HH1" "HH2" )
CYCL_HRS_RECENTER=( "HH1" "HH2" )
BOUNDARY_LEN_HRS="0"
BOUNDARY_LONG_LEN_HRS="0"
POSTPROC_LEN_HRS="1"
Expand Down Expand Up @@ -569,6 +573,10 @@ CYCL_HRS_HYB_FV3LAM_ENS=( "99" )
# cycle definition for product cycle group
# This group runs: anal_gsi_input and data process, run_fcst, python_skewt, run_clean
#
# RECENTER_CYCLEDEF:
# cycle definition for recenter cycle group
# This group runs: recenter
#
# POSTPROC_CYCLEDEF:
# cycle definition for "postproc" group
# This group runs: run_post, run_ncl, run_ncl_zip
Expand All @@ -591,6 +599,7 @@ BOUNDARY_CYCLEDEF="00 01 01 01 2100 *"
BOUNDARY_LONG_CYCLEDEF="00 01 01 01 2100 *"
SPINUP_CYCLEDEF="00 01 01 01 2100 *"
PROD_CYCLEDEF="00 01 01 01 2100 *"
RECENTER_CYCLEDEF="00 01 01 01 2100 *"
POSTPROC_CYCLEDEF="00 01 01 01 2100 *"
POSTPROC_LONG_CYCLEDEF="00 01 01 01 2100 *"
ARCHIVE_CYCLEDEF="00 01 01 01 2100 *"
Expand Down
2 changes: 2 additions & 0 deletions ush/generate_FV3LAM_wflow.sh
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@ settings="\
'cycl_hrs': [ $( printf "\'%s\', " "${CYCL_HRS[@]}" ) ]
'cycl_hrs_spinstart': [ $( printf "\'%s\', " "${CYCL_HRS_SPINSTART[@]}" ) ]
'cycl_hrs_prodstart': [ $( printf "\'%s\', " "${CYCL_HRS_PRODSTART[@]}" ) ]
'cycl_hrs_recenter': [ $( printf "\'%s\', " "${CYCL_HRS_RECENTER[@]}" ) ]
'cycl_hrs_hyb_fv3lam_ens': [ $( printf "\'%s\', " "${CYCL_HRS_HYB_FV3LAM_ENS[@]}" ) ]
'restart_hrs_prod': ${RESTART_INTERVAL}
'cycl_freq': !!str 12:00:00
Expand All @@ -419,6 +420,7 @@ settings="\
'boundary_long_cycledef': ${BOUNDARY_LONG_CYCLEDEF}
'spinup_cycledef': ${SPINUP_CYCLEDEF}
'prod_cycledef': ${PROD_CYCLEDEF}
'recenter_cycledef': ${RECENTER_CYCLEDEF}
'postproc_long_cycledef': ${POSTPROC_LONG_CYCLEDEF}
'archive_cycledef': ${ARCHIVE_CYCLEDEF}
#
Expand Down
23 changes: 21 additions & 2 deletions ush/templates/FV3LAM_wflow.xml
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ tasks; and the "FCST" type is used for the RUN_FCST_TN task.

<cycledef group="spinupcyc"> {{ spinup_cycledef }} </cycledef>
<cycledef group="prodcyc"> {{ prod_cycledef }} </cycledef>
<cycledef group="recentercyc"> {{ recenter_cycledef }} </cycledef>

<cycledef group="postproc_normal"> {{ prod_cycledef }} </cycledef>
<cycledef group="postproc_long"> {{ postproc_long_cycledef }} </cycledef>
Expand Down Expand Up @@ -1254,7 +1255,25 @@ MODULES_RUN_TASK_FP script.
<taskdep task="&PREP_CYC_TN;_#type#{{ uscore_ensmem_name }}"/>
</and>
{%- if do_recenter %}
<datadep age="01:30"><cyclestr>&CYCLE_BASEDIR;/@Y@m@d@H/recenter/fcst_fv3lam/INPUT/recenter_complete.txt</cyclestr></datadep>
<or>
<and>
<or>
{%- for h in cycl_hrs_recenter %}
<streq><left>{{ h }}</left><right><cyclestr>@H</cyclestr></right></streq>
{%- endfor %}
</or>
<datadep age="01:30"><cyclestr>&CYCLE_BASEDIR;/@Y@m@d@H/recenter/fcst_fv3lam/INPUT/recenter_complete.txt</cyclestr></datadep>
</and>
<and>
{%- for h in cycl_hrs_recenter %}
<strneq><left>{{ h }}</left><right><cyclestr>@H</cyclestr></right></strneq>
{%- endfor %}
{%- for h in cycl_hrs_prodstart %}
<strneq><left>{{ h }}</left><right><cyclestr>@H</cyclestr></right></strneq>
{%- endfor %}
<taskdep task="&CLDANL_NONVAR_TN;_#type#{{ uscore_ensmem_name }}"/>
</and>
</or>
{%- elif do_nonvar_cldanal%}
<taskdep task="&CLDANL_NONVAR_TN;_#type#{{ uscore_ensmem_name }}"/>
{%- elif do_enkf_radar_ref %}
Expand Down Expand Up @@ -1990,7 +2009,7 @@ MODULES_RUN_TASK_FP script.
************************************************************************
-->

<task name="&RUN_RECENTER_TN;" cycledefs="prodcyc" maxtries="{{ maxtries_recenter }}">
<task name="&RUN_RECENTER_TN;" cycledefs="recentercyc" maxtries="{{ maxtries_recenter }}">
&RSRV_ENKF;
&WALL_LIMIT_RECENTER;
<command>&LOAD_MODULES_RUN_TASK_FP; "&RUN_RECENTER_TN;" &JOBSDIR;/JREGIONAL_RUN_RECENTER</command>
Expand Down

0 comments on commit e072e1b

Please sign in to comment.