Skip to content

Commit

Permalink
Replace references of CDUMP with RUN
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidHuber-NOAA committed Jun 26, 2024
1 parent 4883ddd commit 4a4e5df
Show file tree
Hide file tree
Showing 43 changed files with 567 additions and 570 deletions.
2 changes: 0 additions & 2 deletions jobs/JGDAS_ENKF_ARCHIVE
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ source "${HOMEgfs}/ush/jjob_header.sh" -e "earc" -c "base earc"
##############################################
# Set variables used in the script
##############################################
export CDUMP=${RUN/enkf}

YMD=${PDY} HH=${cyc} declare_from_tmpl -rx COM_TOP
MEMDIR="ensstat" YMD=${PDY} HH=${cyc} declare_from_tmpl -rx \
COMIN_ATMOS_ANALYSIS_ENSSTAT:COM_ATMOS_ANALYSIS_TMPL \
Expand Down
1 change: 0 additions & 1 deletion jobs/JGDAS_ENKF_UPDATE
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ source "${HOMEgfs}/ush/jjob_header.sh" -e "eupd" -c "base anal eupd"
##############################################
# Set variables used in the script
##############################################
export CDUMP="${RUN/enkf}"


##############################################
Expand Down
1 change: 1 addition & 0 deletions jobs/JGDAS_GLOBAL_OCEAN_ANALYSIS_CHKPT
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ source "${HOMEgfs}/ush/jjob_header.sh" -e "ocnanalchkpt" -c "base ocnanal ocnana
##############################################
# Ignore possible spelling error (nothing is misspelled)
# shellcheck disable=SC2153
export CDUMP=${CDUMP:-${RUN:-"gfs"}}
GDATE=$(date --utc +%Y%m%d%H -d "${PDY} ${cyc} - ${assim_freq} hours")
export GDATE
export gPDY=${GDATE:0:8}
Expand Down
2 changes: 0 additions & 2 deletions jobs/JGLOBAL_ARCHIVE
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,6 @@ source "${HOMEgfs}/ush/jjob_header.sh" -e "arch" -c "base arch"
##############################################
# Set variables used in the script
##############################################
export CDUMP=${RUN/enkf}

YMD=${PDY} HH=${cyc} declare_from_tmpl -rx \
COMIN_ATMOS_ANALYSIS:COM_ATMOS_ANALYSIS_TMPL \
COMIN_ATMOS_BUFR:COM_ATMOS_BUFR_TMPL \
Expand Down
2 changes: 1 addition & 1 deletion jobs/JGLOBAL_STAGE_IC
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ source "${HOMEgfs}/ush/jjob_header.sh" -e "stage_ic" -c "base stage_ic"

# Restart conditions for GFS cycle come from GDAS
# shellcheck disable=SC2153
rCDUMP=${CDUMP}
rCDUMP=${RUN}
[[ ${CDUMP} = "gfs" ]] && export rCDUMP="gdas"
export rCDUMP

Expand Down
2 changes: 1 addition & 1 deletion parm/archive/arcdir.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@
ARCDIR ~ "/snowstat." ~ RUN ~ "." ~ cycle_YMDH ~ ".tgz"]) %}
{% endif %}

{% if AERO_ANL_CDUMP == RUN or AERO_ANL_CDUMP == "both" %}
{% if AERO_ANL_RUN == RUN or AERO_ANL_RUN == "both" %}
{% do det_anl_files.append([COMIN_CHEM_ANALYSIS ~ "/" ~ head ~ "aerostat",
ARCDIR ~ "/aerostat." ~ RUN ~ "." ~ cycle_YMDH ]) %}
{% endif %}
Expand Down
2 changes: 1 addition & 1 deletion parm/archive/gdas.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ gdas:
- "{{ COMIN_ATMOS_ANALYSIS | relpath(ROTDIR) }}/{{ head }}oznstat"
- "{{ COMIN_ATMOS_ANALYSIS | relpath(ROTDIR) }}/{{ head }}radstat"
{% endif %}
{% if AERO_ANL_CDUMP == "gdas" or AERO_ANL_CDUMP == "both" %}
{% if AERO_ANL_RUN == "gdas" or AERO_ANL_RUN == "both" %}
- "{{ COMIN_CHEM_ANALYSIS | relpath(ROTDIR) }}/{{ head }}aerostat"
{% endif %}
{% if DO_PREP_OBS_AERO %}
Expand Down
2 changes: 1 addition & 1 deletion parm/archive/gfsa.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ gfsa:
{% else %}
- "{{ COMIN_ATMOS_ANALYSIS | relpath(ROTDIR) }}/{{ head }}gsistat"
{% endif %}
{% if AERO_ANL_CDUMP == "gfs" or AERO_ANL_CDUMP == "both" %}
{% if AERO_ANL_RUN == "gfs" or AERO_ANL_RUN == "both" %}
- "{{ COMIN_CHEM_ANALYSIS | relpath(ROTDIR) }}/{{ head }}aerostat"
{% endif %}
{% if DO_PREP_OBS_AERO %}
Expand Down
2 changes: 1 addition & 1 deletion parm/archive/master_gfs.yaml.j2
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ datasets:
{% endfilter %}
{% endif %}

{% if AERO_FCST_CDUMP == "gfs" or AERO_FCST_CDUMP == "both" %}
{% if AERO_FCST_RUN == "gfs" or AERO_FCST_RUN == "both" %}
# Aerosol forecasts
{% filter indent(width=4) %}
{% include "chem.yaml.j2" %}
Expand Down
23 changes: 10 additions & 13 deletions parm/config/gefs/config.base
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,7 @@ export ATARDIR="@ATARDIR@"
# Commonly defined parameters in JJOBS
export envir=${envir:-"prod"}
export NET="gefs" # NET is defined in the job-card (ecf)
export RUN="gefs" # RUN is defined in the job-card (ecf); CDUMP is used at EMC as a RUN proxy
# TODO: determine where is RUN actually used in the workflow other than here
# TODO: is it possible to replace all instances of ${CDUMP} to ${RUN} to be
# consistent w/ EE2?
export RUN="gefs" # RUN is defined in the job-card (ecf)

# Get all the COM path templates
source "${EXPDIR}/config.com"
Expand Down Expand Up @@ -138,9 +135,9 @@ export DO_WAVE="NO"
export DO_OCN="NO"
export DO_ICE="NO"
export DO_AERO="NO"
export AERO_FCST_CDUMP="" # When to run aerosol forecast: gdas, gfs, or both
export AERO_ANL_CDUMP="" # When to run aerosol analysis: gdas, gfs, or both
export WAVE_CDUMP="" # When to include wave suite: gdas, gfs, or both
export AERO_FCST_RUN="" # When to run aerosol forecast: gdas, gfs, or both
export AERO_ANL_RUN="" # When to run aerosol analysis: gdas, gfs, or both
export WAVE_RUN="" # When to include wave suite: gdas, gfs, or both
export DOBNDPNT_WAVE="NO" # The GEFS buoys file does not currently have any boundary points
export DOIBP_WAV="NO" # Option to create point outputs from input boundary points
export FRAC_GRID=".true."
Expand Down Expand Up @@ -186,13 +183,13 @@ case "${APP}" in
;;
ATMA)
export DO_AERO="YES"
export AERO_ANL_CDUMP="both"
export AERO_FCST_CDUMP="gdas"
export AERO_ANL_RUN="both"
export AERO_FCST_RUN="gdas"
;;
ATMW)
export DO_COUPLED="YES"
export DO_WAVE="YES"
export WAVE_CDUMP="both"
export WAVE_RUN="both"
;;
NG-GODAS)
export DO_ATM="NO"
Expand All @@ -206,13 +203,13 @@ case "${APP}" in

if [[ "${APP}" =~ A$ ]]; then
export DO_AERO="YES"
export AERO_ANL_CDUMP="both"
export AERO_FCST_CDUMP="gdas"
export AERO_ANL_RUN="both"
export AERO_FCST_RUN="gdas"
fi

if [[ "${APP}" =~ ^S2SW ]]; then
export DO_WAVE="YES"
export WAVE_CDUMP="both"
export WAVE_RUN="both"
export cplwav2atm=".true."
fi
;;
Expand Down
4 changes: 2 additions & 2 deletions parm/config/gefs/config.fcst
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ export USE_ESMF_THREADING="YES" # Toggle to use ESMF-managed threading or tradi
export COPY_FINAL_RESTARTS="NO" # Toggle to copy restarts from the end of GFS/GEFS Run (GDAS is handled seperately)

# Turn off waves if not used for this RUN
case ${WAVE_CDUMP} in
case ${WAVE_RUN} in
both | "${RUN/enkf}" ) ;; # Don't change
*) DO_WAVE="NO" ;; # Turn waves off
esac

# Turn off aerosols if not used for this RUN
case ${AERO_FCST_CDUMP} in
case ${AERO_FCST_RUN} in
both | "${RUN/enkf}" ) ;; # Don't change
*) DO_AERO="NO" ;; # Turn waves off
esac
Expand Down
14 changes: 7 additions & 7 deletions parm/config/gefs/config.resources
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,11 @@ case ${step} in
"fcst" | "efcs")
export is_exclusive=True

_CDUMP_LIST=${CDUMP:-"gdas gfs"}
_RUN_LIST=${RUN:-"gdas gfs"}

# During workflow creation, we need resources for all CDUMPs and CDUMP is undefined
for _CDUMP in ${_CDUMP_LIST}; do
if [[ "${_CDUMP}" =~ "gfs" ]]; then
# During workflow creation, we need resources for all RUNs and RUN is undefined
for _RUN in ${_RUN_LIST}; do
if [[ "${_RUN}" =~ "gfs" ]]; then
export layout_x=${layout_x_gfs}
export layout_y=${layout_y_gfs}
export WRITE_GROUP=${WRITE_GROUP_GFS}
Expand Down Expand Up @@ -178,9 +178,9 @@ case ${step} in
fi
export ICEPETS ICETHREADS

echo "Total PETS for ${_CDUMP} = ${NTASKS_TOT}"
echo "Total PETS for ${_RUN} = ${NTASKS_TOT}"

if [[ "${_CDUMP}" =~ "gfs" ]]; then
if [[ "${_RUN}" =~ "gfs" ]]; then
declare -x "npe_${step}_gfs"="${NTASKS_TOT}"
declare -x "nth_${step}_gfs"="${UFS_THREADS}"
declare -x "npe_node_${step}_gfs"="${npe_node_max}"
Expand All @@ -207,7 +207,7 @@ case ${step} in
;;
esac

unset _CDUMP _CDUMP_LIST
unset _RUN _RUN_LIST
unset NTASKS_TOT
;;

Expand Down
4 changes: 2 additions & 2 deletions parm/config/gefs/config.wave
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,10 @@ echo "BEGIN: config.wave"
# Some others are also used across the workflow in wave component scripts

# General runtime labels
export CDUMPwave="${RUN}wave"
export RUNwave="${RUN}wave"

# In GFS/GDAS, restart files are generated/read from gdas runs
export CDUMPRSTwave="gdas"
export RUNRSTwave="gdas"

#grid dependent variable defaults
export waveGRDN='1' # grid number for ww3_multi
Expand Down
2 changes: 1 addition & 1 deletion parm/config/gfs/config.anal
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ if [[ ${DONST} = "YES" ]]; then
. ${EXPDIR}/config.nsst
fi

if [[ "${CDUMP}" = "gfs" ]] ; then
if [[ "${RUN}" = "gfs" ]] ; then
export USE_RADSTAT="NO" # This can be only used when bias correction is not-zero.
export GENDIAG="NO"
export SETUP='diag_rad=.false.,diag_pcp=.false.,diag_conv=.false.,diag_ozone=.false.,write_diag(3)=.false.,niter(2)=100,'
Expand Down
26 changes: 13 additions & 13 deletions parm/config/gfs/config.base
Original file line number Diff line number Diff line change
Expand Up @@ -135,9 +135,9 @@ export ATARDIR="@ATARDIR@"
# Commonly defined parameters in JJOBS
export envir=${envir:-"prod"}
export NET="gfs" # NET is defined in the job-card (ecf)
export RUN=${RUN:-${CDUMP:-"gfs"}} # RUN is defined in the job-card (ecf); CDUMP is used at EMC as a RUN proxy
export RUN=${RUN:-${RUN:-"gfs"}} # RUN is defined in the job-card (ecf)
# TODO: determine where is RUN actually used in the workflow other than here
# TODO: is it possible to replace all instances of ${CDUMP} to ${RUN} to be
# TODO: is it possible to replace all instances of ${RUN} to ${RUN} to be
# consistent w/ EE2?

# Get all the COM path templates
Expand Down Expand Up @@ -179,9 +179,9 @@ export DO_OCN="NO"
export DO_ICE="NO"
export DO_AERO="NO"
export DO_PREP_OBS_AERO="NO"
export AERO_FCST_CDUMP="" # When to run aerosol forecast: gdas, gfs, or both
export AERO_ANL_CDUMP="" # When to run aerosol analysis: gdas, gfs, or both
export WAVE_CDUMP="" # When to include wave suite: gdas, gfs, or both
export AERO_FCST_RUN="" # When to run aerosol forecast: gdas, gfs, or both
export AERO_ANL_RUN="" # When to run aerosol analysis: gdas, gfs, or both
export WAVE_RUN="" # When to include wave suite: gdas, gfs, or both
export DOBNDPNT_WAVE="NO"
export DOIBP_WAV="NO" # Option to create point outputs from input boundary points
export FRAC_GRID=".true."
Expand Down Expand Up @@ -232,13 +232,13 @@ case "${APP}" in
;;
ATMA)
export DO_AERO="YES"
export AERO_ANL_CDUMP="both"
export AERO_FCST_CDUMP="gdas"
export AERO_ANL_RUN="both"
export AERO_FCST_RUN="gdas"
;;
ATMW)
export DO_COUPLED="YES"
export DO_WAVE="YES"
export WAVE_CDUMP="both"
export WAVE_RUN="both"
;;
NG-GODAS)
export DO_ATM="NO"
Expand All @@ -252,13 +252,13 @@ case "${APP}" in

if [[ "${APP}" =~ A$ ]]; then
export DO_AERO="YES"
export AERO_ANL_CDUMP="both"
export AERO_FCST_CDUMP="gdas"
export AERO_ANL_RUN="both"
export AERO_FCST_RUN="gdas"
fi

if [[ "${APP}" =~ ^S2SW ]]; then
export DO_WAVE="YES"
export WAVE_CDUMP="both"
export WAVE_RUN="both"
fi
;;
*)
Expand All @@ -268,10 +268,10 @@ case "${APP}" in
esac

# Surface cycle update frequency
if [[ "${CDUMP}" =~ "gdas" ]] ; then
if [[ "${RUN}" =~ "gdas" ]] ; then
export FHCYC=1
export FTSFS=10
elif [[ "${CDUMP}" =~ "gfs" ]] ; then
elif [[ "${RUN}" =~ "gfs" ]] ; then
export FHCYC=24
fi

Expand Down
8 changes: 4 additions & 4 deletions parm/config/gfs/config.fcst
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@ export USE_ESMF_THREADING="YES" # Toggle to use ESMF-managed threading or tradi
export COPY_FINAL_RESTARTS="NO" # Toggle to copy restarts from the end of GFS/GEFS Run (GDAS is handled seperately)

# Turn off waves if not used for this RUN
case ${WAVE_CDUMP} in
case ${WAVE_RUN} in
both | "${RUN/enkf}" ) ;; # Don't change
*) DO_WAVE="NO" ;; # Turn waves off
esac

# Turn off aerosols if not used for this RUN
case ${AERO_FCST_CDUMP} in
case ${AERO_FCST_RUN} in
both | "${RUN/enkf}" ) ;; # Don't change
*) DO_AERO="NO" ;; # Turn aerosols off
esac
Expand Down Expand Up @@ -273,7 +273,7 @@ export FSICL="0"
export FSICS="0"

#---------------------------------------------------------------------
if [[ "${CDUMP}" =~ "gdas" ]] ; then # GDAS cycle specific parameters
if [[ "${RUN}" =~ "gdas" ]] ; then # GDAS cycle specific parameters

# Variables used in DA cycling
export DIAG_TABLE="${PARMgfs}/ufs/fv3/diag_table_da"
Expand All @@ -284,7 +284,7 @@ if [[ "${CDUMP}" =~ "gdas" ]] ; then # GDAS cycle specific parameters
# Turn on dry mass adjustment in GDAS
export adjust_dry_mass=".true."

elif [[ "${CDUMP}" =~ "gfs" ]] ; then # GFS cycle specific parameters
elif [[ "${RUN}" =~ "gfs" ]] ; then # GFS cycle specific parameters

# Write more variables to output
export DIAG_TABLE="${PARMgfs}/ufs/fv3/diag_table"
Expand Down
10 changes: 5 additions & 5 deletions parm/config/gfs/config.metp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export HOMEverif_global=${HOMEgfs}/sorc/verif-global.fd
export VERIF_GLOBALSH=${HOMEverif_global}/ush/run_verif_global_in_global_workflow.sh
## INPUT DATA SETTINGS
export model=${PSLOT}
export model_file_format="pgbf{lead?fmt=%2H}.${CDUMP}.{init?fmt=%Y%m%d%H}.grib2"
export model_file_format="pgbf{lead?fmt=%2H}.${RUN}.{init?fmt=%Y%m%d%H}.grib2"
export model_hpss_dir=${ATARDIR}/..
export model_dir=${ARCDIR}/..
export get_data_from_hpss="NO"
Expand All @@ -39,19 +39,19 @@ export log_MET_output_to_METplus="yes"
# GRID-TO-GRID STEP 1: gfsmetpg2g1
export g2g1_type_list="anom pres sfc"
export g2g1_anom_truth_name="self_anl"
export g2g1_anom_truth_file_format="pgbanl.${CDUMP}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_anom_truth_file_format="pgbanl.${RUN}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_anom_fhr_min=${FHMIN_GFS}
export g2g1_anom_fhr_max=${FHMAX_GFS}
export g2g1_anom_grid="G002"
export g2g1_anom_gather_by="VSDB"
export g2g1_pres_truth_name="self_anl"
export g2g1_pres_truth_file_format="pgbanl.${CDUMP}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_pres_truth_file_format="pgbanl.${RUN}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_pres_fhr_min=${FHMIN_GFS}
export g2g1_pres_fhr_max=${FHMAX_GFS}
export g2g1_pres_grid="G002"
export g2g1_pres_gather_by="VSDB"
export g2g1_sfc_truth_name="self_f00"
export g2g1_sfc_truth_file_format="pgbf00.${CDUMP}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_sfc_truth_file_format="pgbf00.${RUN}.{valid?fmt=%Y%m%d%H}.grib2"
export g2g1_sfc_fhr_min=${FHMIN_GFS}
export g2g1_sfc_fhr_max=${FHMAX_GFS}
export g2g1_sfc_grid="G002"
Expand Down Expand Up @@ -87,7 +87,7 @@ export g2o1_mv_database_desc="Grid-to-obs METplus data for global workflow exper
export precip1_type_list="ccpa_accum24hr"
export precip1_ccpa_accum24hr_model_bucket="06"
export precip1_ccpa_accum24hr_model_var="APCP"
export precip1_ccpa_accum24hr_model_file_format="pgbf{lead?fmt=%2H}.${CDUMP}.{init?fmt=%Y%m%d%H}.grib2"
export precip1_ccpa_accum24hr_model_file_format="pgbf{lead?fmt=%2H}.${RUN}.{init?fmt=%Y%m%d%H}.grib2"
export precip1_ccpa_accum24hr_fhr_min=${FHMIN_GFS}
export precip1_ccpa_accum24hr_fhr_max="180"
export precip1_ccpa_accum24hr_grid="G211"
Expand Down
Loading

0 comments on commit 4a4e5df

Please sign in to comment.