diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 4703c58749..d42357f57f 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -12,10 +12,5 @@ jobs:
- run: |
cd ufs-srweather-app
./manage_externals/checkout_externals
- module use modulefiles
- module load build_cheyenne_intel
- mdkir build
- cd build
- cmake -DCMAKE_INSTALL_PREFIX=.. ..
- make -j 4
+ ./devbuild.sh -p=cheyenne -c=intel
- run: echo "🍏 This job's status is ${{ job.status }}."
diff --git a/.github/workflows/python_func_tests.yaml b/.github/workflows/python_func_tests.yaml
index 80a3f191fc..c35291fe11 100644
--- a/.github/workflows/python_func_tests.yaml
+++ b/.github/workflows/python_func_tests.yaml
@@ -3,7 +3,7 @@ on:
push:
paths:
- ush/*retrieve_data.py
- - ush/templates/data_locations.yml
+ - parm/data_locations.yml
pull_request:
env:
diff --git a/.github/workflows/python_unittests.yaml b/.github/workflows/python_unittests.yaml
index b67039c923..7c76288a8d 100644
--- a/.github/workflows/python_unittests.yaml
+++ b/.github/workflows/python_unittests.yaml
@@ -1,5 +1,8 @@
name: Python unittests
on: [push, pull_request, workflow_dispatch]
+defaults:
+ run:
+ shell: bash
jobs:
python_unittests:
@@ -15,13 +18,17 @@ jobs:
run: |
sudo apt-get update
sudo apt-get install python3 python3-pip netcdf-bin
- sudo pip3 install pyyaml jinja2 f90nml
+ sudo pip3 install pyyaml jinja2==2.11 f90nml
sudo pip3 install numpy matplotlib basemap
# Run python unittests
- name: Run python unittests
run: |
+ ./manage_externals/checkout_externals ufs-weather-model
cd ush
python3 -m unittest -b python_utils/test_python_utils.py
- python3 -m unittest -b *.py
+ # exclude test_retrieve_data that is tested in functional test
+ files=$(find . -maxdepth 1 -name '*.py' -a ! -name 'test_retrieve_data.py' -exec basename {} \;)
+ files=$(echo $(echo "${files[@]}"))
+ python3 -m unittest -b ${files[@]}
diff --git a/devbuild.sh b/devbuild.sh
index d9326388c6..e6e1999767 100755
--- a/devbuild.sh
+++ b/devbuild.sh
@@ -38,7 +38,7 @@ OPTIONS
--install-dir=INSTALL_DIR
installation prefix
--bin-dir=BIN_DIR
- installation binary directory name ("bin" by default; any name is available)
+ installation binary directory name ("exec" by default; any name is available)
--build-type=BUILD_TYPE
build type; defaults to RELEASE
(e.g. DEBUG | RELEASE | RELWITHDEBINFO)
@@ -102,7 +102,7 @@ SRW_DIR=$(cd "$(dirname "$(readlink -f -n "${BASH_SOURCE[0]}" )" )" && pwd -P)
MACHINE_SETUP=${SRW_DIR}/src/UFS_UTILS/sorc/machine-setup.sh
BUILD_DIR="${SRW_DIR}/build"
INSTALL_DIR=${SRW_DIR}
-BIN_DIR="bin" #change this to "exec" for NCO mode later
+BIN_DIR="exec"
COMPILER=""
APPLICATION=""
CCPP_SUITES=""
diff --git a/docs/UsersGuide/source/ConfigWorkflow.rst b/docs/UsersGuide/source/ConfigWorkflow.rst
index a8d6069a0a..04fc0402c4 100644
--- a/docs/UsersGuide/source/ConfigWorkflow.rst
+++ b/docs/UsersGuide/source/ConfigWorkflow.rst
@@ -117,7 +117,7 @@ Cron is a job scheduler accessed through the command-line on UNIX-like operating
Directory Parameters
====================
``EXPT_BASEDIR``: (Default: "")
- The full path to the base directory inside of which the experiment directory (``EXPT_SUBDIR``) will be created. If this is not specified or if it is set to an empty string, it will default to ``${HOMErrfs}/../../expt_dirs``, where ``${HOMErrfs}`` contains the full path to the ``regional_workflow`` directory.
+ The full path to the base directory inside of which the experiment directory (``EXPT_SUBDIR``) will be created. If this is not specified or if it is set to an empty string, it will default to ``${HOMEdir}/../../expt_dirs``, where ``${HOMEdir}`` contains the full path to the ``regional_workflow`` directory.
``EXPT_SUBDIR``: (Default: "")
A descriptive name of the user's choice for the experiment directory (*not* its full path). The full path to the experiment directory, which will be contained in the variable ``EXPTDIR``, will be:
diff --git a/docs/UsersGuide/source/Graphics.rst b/docs/UsersGuide/source/Graphics.rst
index f435eee6d7..205882cea6 100644
--- a/docs/UsersGuide/source/Graphics.rst
+++ b/docs/UsersGuide/source/Graphics.rst
@@ -196,28 +196,28 @@ At a minimum, the account should be set appropriately prior to job submission:
Depending on the platform, users may also need to adjust the settings to use the correct Python environment and path to the shapefiles.
When working with these batch scripts, several environment variables must be set prior to submission.
-If plotting output from a single cycle, the variables to set are ``$HOMErrfs`` and ``$EXPTDIR``.
+If plotting output from a single cycle, the variables to set are ``$HOMEdir`` and ``$EXPTDIR``.
If the user's login shell is bash, these variables can be set as follows:
.. code-block:: console
- export HOMErrfs=/path-to/ufs-srweather-app/regional_workflow
+ export HOMEdir=/path-to/ufs-srweather-app/regional_workflow
export EXPTDIR=/path-to/experiment/directory
If the user's login shell is csh/tcsh, they can be set as follows:
.. code-block:: console
- setenv HOMErrfs /path-to/ufs-srweather-app/regional_workflow
+ setenv HOMEdir /path-to/ufs-srweather-app/regional_workflow
setenv EXPTDIR /path-to/experiment/directory
If plotting the difference between the same cycle from two different experiments, the variables
-to set are ``$HOMErrfs``, ``$EXPTDIR1``, and ``$EXPTDIR2``. If the user's login shell
+to set are ``$HOMEdir``, ``$EXPTDIR1``, and ``$EXPTDIR2``. If the user's login shell
is bash, these variables can be set as follows:
.. code-block:: console
- export HOMErrfs=/path-to/ufs-srweather-app/regional_workflow
+ export HOMEdir=/path-to/ufs-srweather-app/regional_workflow
export EXPTDIR1=/path-to/experiment/directory1
export EXPTDIR2=/path-to/experiment/directory2
@@ -225,7 +225,7 @@ If the user's login shell is csh/tcsh, they can be set as follows:
.. code-block:: console
- setenv HOMErrfs /path-to/ufs-srweather-app/regional_workflow
+ setenv HOMEdir /path-to/ufs-srweather-app/regional_workflow
setenv EXPTDIR1 /path-to/experiment/directory1
setenv EXPTDIR2 /path-to/experiment/directory2
diff --git a/jobs/JREGIONAL_GET_EXTRN_MDL_FILES b/jobs/JREGIONAL_GET_EXTRN_MDL_FILES
index 31c2963866..a6b1902a14 100755
--- a/jobs/JREGIONAL_GET_EXTRN_MDL_FILES
+++ b/jobs/JREGIONAL_GET_EXTRN_MDL_FILES
@@ -29,7 +29,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -38,7 +39,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -67,8 +68,6 @@ This is the J-job script for the task that copies or fetches external
model files from disk, HPSS, or URL, and stages them for downstream use
to generate initial or lateral boundary conditions for the FV3 model.
========================================================================"
-
-
#
#-----------------------------------------------------------------------
#
@@ -92,12 +91,12 @@ check_var_valid_value "ICS_OR_LBCS" "valid_vals_ICS_OR_LBCS"
#-----------------------------------------------------------------------
#
if [ "${ICS_OR_LBCS}" = "ICS" ]; then
- time_offset_hrs=${EXTRN_MDL_ICS_OFFSET_HRS:-0}
- extrn_mdl_name=${EXTRN_MDL_NAME_ICS}
+ export TIME_OFFSET_HRS=${EXTRN_MDL_ICS_OFFSET_HRS:-0}
+ export EXTRN_MDL_NAME=${EXTRN_MDL_NAME_ICS}
elif [ "${ICS_OR_LBCS}" = "LBCS" ]; then
- time_offset_hrs=${EXTRN_MDL_LBCS_OFFSET_HRS:-0}
- extrn_mdl_name=${EXTRN_MDL_NAME_LBCS}
+ export TIME_OFFSET_HRS=${EXTRN_MDL_LBCS_OFFSET_HRS:-0}
+ export EXTRN_MDL_NAME=${EXTRN_MDL_NAME_LBCS}
fi
#
@@ -108,16 +107,16 @@ fi
#-----------------------------------------------------------------------
#
-hh=${CDATE:8:2}
-yyyymmdd=${CDATE:0:8}
-extrn_mdl_cdate=$( $DATE_UTIL --utc --date "${yyyymmdd} ${hh} UTC - ${time_offset_hrs} hours" "+%Y%m%d%H" )
+yyyymmdd=${PDY}
+hh=${cyc}
+export EXTRN_MDL_CDATE=$( $DATE_UTIL --utc --date "${yyyymmdd} ${hh} UTC - ${TIME_OFFSET_HRS} hours" "+%Y%m%d%H" )
#
#-----------------------------------------------------------------------
#
# Check whether output files from the specified external model
-# (extrn_mdl_name) are available on the specified cycle date and time
-# (extrn_mdl_cdate).
+# (EXTRN_MDL_NAME) are available on the specified cycle date and time
+# (EXTRN_MDL_CDATE).
#
#-----------------------------------------------------------------------
#
@@ -133,37 +132,37 @@ function data_unavailable() {
if [ ${min_max} = max ]; then
msg="\
-Output from the specified external model (extrn_mdl_name) is not availa-
-ble for the specified cycle date and time (extrn_mdl_cdate) because the latter is
+Output from the specified external model (EXTRN_MDL_NAME) is not availa-
+ble for the specified cycle date and time (EXTRN_MDL_CDATE) because the latter is
later than the last forecast date and time (cdate_max) with this model:
- extrn_mdl_name = \"${name}\"
+ EXTRN_MDL_NAME = \"${name}\"
CDATE_max = \"${end_date}\"
- extrn_mdl_cdate = \"${cdate}\""
+ EXTRN_MDL_CDATE = \"${cdate}\""
elif [ ${min_max} = min ]; then
msg="\
-Output from the specified external model (extrn_mdl_name) is not availa-
-ble for the specified cycle date and time (extrn_mdl_cdate) because the latter is
+Output from the specified external model (EXTRN_MDL_NAME) is not availa-
+ble for the specified cycle date and time (EXTRN_MDL_CDATE) because the latter is
earlier than the implementation date of this model:
- extrn_mdl_name = \"${name}\"
+ EXTRN_MDL_NAME = \"${name}\"
CDATE_min = \"${end_date}\"
- extrn_mdl_cdate = \"${cdate}\""
+ EXTRN_MDL_CDATE = \"${cdate}\""
fi
echo ${msg}
}
-case ${extrn_mdl_name} in
+case ${EXTRN_MDL_NAME} in
"GSMGFS")
# The transition date from the GSMGFS to the FV3GFS was 2019061212, i.e.
# this was the first official forecast with the FV3GFS. So we set the
# last CDATE for the GSMGFS to the one 6 hours before this.
cdate_max="2019061206"
- if [ "$extrn_mdl_cdate" -gt "$cdate_max" ]; then
+ if [ "$EXTRN_MDL_CDATE" -gt "$cdate_max" ]; then
print_err_msg_exit "\
- $(data_unavailable $extrn_mdl_name $extrn_mdl_cdate $cdate_max max)"
+ $(data_unavailable $EXTRN_MDL_NAME $EXTRN_MDL_CDATE $cdate_max max)"
fi
;;
@@ -171,12 +170,12 @@ case ${extrn_mdl_name} in
# The transition date from the GSMGFS to the FV3GFS was 2019061212, i.e.
# this was the first official forecast with the FV3GFS. However, paral-
# lel runs with the FV3GFS go back to 2018121500. So we set the first
-# extrn_mdl_cdate for the FV3GFS to this date and time.
+# EXTRN_MDL_CDATE for the FV3GFS to this date and time.
# CDATE_min="2019061212"
CDATE_min="2018121500"
- if [ "$extrn_mdl_cdate" -lt "$CDATE_min" ]; then
+ if [ "$EXTRN_MDL_CDATE" -lt "$CDATE_min" ]; then
print_err_msg_exit "\
- $(data_unavailable $extrn_mdl_name $extrn_mdl_cdate $cdate_min min)"
+ $(data_unavailable $EXTRN_MDL_NAME $EXTRN_MDL_CDATE $cdate_min min)"
fi
;;
@@ -184,9 +183,9 @@ case ${extrn_mdl_name} in
# Examination of the HPSS archives shows that the RAPX data goes back to
# July 01, 2015.
CDATE_min="2015070100"
- if [ "$extrn_mdl_cdate" -lt "$CDATE_min" ]; then
+ if [ "$EXTRN_MDL_CDATE" -lt "$CDATE_min" ]; then
print_err_msg_exit "\
- $(data_unavailable $extrn_mdl_name $extrn_mdl_cdate $cdate_min min)"
+ $(data_unavailable $EXTRN_MDL_NAME $EXTRN_MDL_CDATE $cdate_min min)"
fi
;;
@@ -195,9 +194,9 @@ case ${extrn_mdl_name} in
# implementation of the first version of the operational HRRR was
# September 30, 2014.
CDATE_min="2014103000"
- if [ "$extrn_mdl_cdate" -lt "$CDATE_min" ]; then
+ if [ "$EXTRN_MDL_CDATE" -lt "$CDATE_min" ]; then
print_err_msg_exit "\
- $(data_unavailable $extrn_mdl_name $extrn_mdl_cdate $cdate_min min)"
+ $(data_unavailable $EXTRN_MDL_NAME $EXTRN_MDL_CDATE $cdate_min min)"
fi
;;
@@ -209,9 +208,14 @@ esac
#
#-----------------------------------------------------------------------
#
-extrn_mdl_staging_dir="${CYCLE_DIR}/${extrn_mdl_name}/for_${ICS_OR_LBCS}"
-mkdir_vrfy -p "${extrn_mdl_staging_dir}"
-cd_vrfy "${extrn_mdl_staging_dir}"
+if [ $RUN_ENVIR = "nco" ]; then
+ export EXTRN_MDL_STAGING_DIR="${COMIN}"
+ mkdir_vrfy -p "${EXTRN_MDL_STAGING_DIR}"
+else
+ export EXTRN_MDL_STAGING_DIR="${COMIN}/${EXTRN_MDL_NAME}/for_${ICS_OR_LBCS}"
+ mkdir_vrfy -p "${EXTRN_MDL_STAGING_DIR}"
+ cd_vrfy "${EXTRN_MDL_STAGING_DIR}"
+fi
#
#-----------------------------------------------------------------------
#
@@ -219,25 +223,17 @@ cd_vrfy "${extrn_mdl_staging_dir}"
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_get_extrn_mdl_files.sh \
- extrn_mdl_cdate="${extrn_mdl_cdate}" \
- extrn_mdl_name="${extrn_mdl_name}" \
- extrn_mdl_staging_dir="${extrn_mdl_staging_dir}" \
- time_offset_hrs=${time_offset_hrs} ||
+$SCRIPTSdir/exregional_get_extrn_mdl_files.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_GET_OBS_CCPA b/jobs/JREGIONAL_GET_OBS_CCPA
index bd1760ee0d..aaf527a477 100755
--- a/jobs/JREGIONAL_GET_OBS_CCPA
+++ b/jobs/JREGIONAL_GET_OBS_CCPA
@@ -20,7 +20,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -29,7 +30,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -67,21 +68,17 @@ for verification purposes.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_get_ccpa_files.sh || \
+$SCRIPTSdir/exregional_get_obs_ccpa.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_GET_OBS_MRMS b/jobs/JREGIONAL_GET_OBS_MRMS
index f5d6349745..4dc80c30bb 100755
--- a/jobs/JREGIONAL_GET_OBS_MRMS
+++ b/jobs/JREGIONAL_GET_OBS_MRMS
@@ -16,7 +16,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -25,7 +26,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -67,22 +68,18 @@ echo "VAR=${VAR}"
for field in ${VAR[@]}; do
export field
echo "Field=${field}"
- $SCRIPTSDIR/exregional_get_mrms_files.sh || \
+ $SCRIPTSdir/exregional_get_obs_mrms.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
done
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_GET_OBS_NDAS b/jobs/JREGIONAL_GET_OBS_NDAS
index ab44e21b8f..836c367378 100755
--- a/jobs/JREGIONAL_GET_OBS_NDAS
+++ b/jobs/JREGIONAL_GET_OBS_NDAS
@@ -16,7 +16,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -25,7 +26,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -63,21 +64,17 @@ for verification purposes.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_get_ndas_files.sh || \
+$SCRIPTSdir/exregional_get_obs_ndas.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_MAKE_GRID b/jobs/JREGIONAL_MAKE_GRID
index bbf22e0241..c4c68da734 100755
--- a/jobs/JREGIONAL_MAKE_GRID
+++ b/jobs/JREGIONAL_MAKE_GRID
@@ -106,7 +106,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -115,7 +116,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -145,12 +146,32 @@ This is the J-job script for the task that generates grid files.
#
#-----------------------------------------------------------------------
#
+# Create the (cycle-independent) subdirectories under the experiment
+# directory (EXPTDIR) that are needed by the various steps and substeps
+# in this script.
+#
+#-----------------------------------------------------------------------
+#
+check_for_preexist_dir_file "${GRID_DIR}" "${PREEXISTING_DIR_METHOD}"
+mkdir_vrfy -p "${GRID_DIR}"
+#
+#-----------------------------------------------------------------------
+#
+# Create a work directory.
+#
+#-----------------------------------------------------------------------
+#
+DATA="${DATA:-${GRID_DIR}/tmp}"
+mkdir_vrfy -p "$DATA"
+#
+#-----------------------------------------------------------------------
+#
# Call the ex-script for this J-job and pass to it the necessary varia-
# bles.
#
#-----------------------------------------------------------------------
#
-${SCRIPTSDIR}/exregional_make_grid.sh || \
+${SCRIPTSdir}/exregional_make_grid.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
@@ -176,19 +197,15 @@ Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-touch "$LOGDIR/make_grid_task_complete.txt"
+touch "$GRID_DIR/make_grid_task_complete.txt"
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_MAKE_ICS b/jobs/JREGIONAL_MAKE_ICS
index a5e5894f10..525720b14a 100755
--- a/jobs/JREGIONAL_MAKE_ICS
+++ b/jobs/JREGIONAL_MAKE_ICS
@@ -8,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -17,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -54,8 +55,21 @@ for the FV3 (in NetCDF format).
#
#-----------------------------------------------------------------------
#
-ics_dir="${CYCLE_DIR}${SLASH_ENSMEM_SUBDIR}/INPUT"
-mkdir_vrfy -p "${ics_dir}"
+if [ $RUN_ENVIR = "nco" ]; then
+ export INPUT_DATA="${COMIN}"
+else
+ export INPUT_DATA="${COMIN}${SLASH_ENSMEM_SUBDIR}/INPUT"
+fi
+mkdir_vrfy -p "${INPUT_DATA}"
+#
+#-----------------------------------------------------------------------
+#
+# Set the run directory
+#
+#-----------------------------------------------------------------------
+#
+DATA="${DATA:-${COMIN}${SLASH_ENSMEM_SUBDIR}}"
+mkdir_vrfy -p "${DATA}"
#
#-----------------------------------------------------------------------
#
@@ -63,22 +77,17 @@ mkdir_vrfy -p "${ics_dir}"
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_make_ics.sh \
- ics_dir="${ics_dir}" || \
+$SCRIPTSdir/exregional_make_ics.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_MAKE_LBCS b/jobs/JREGIONAL_MAKE_LBCS
index bc7afbaf71..e92ca94354 100755
--- a/jobs/JREGIONAL_MAKE_LBCS
+++ b/jobs/JREGIONAL_MAKE_LBCS
@@ -8,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -17,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -54,8 +55,21 @@ hour zero).
#
#-----------------------------------------------------------------------
#
-lbcs_dir="${CYCLE_DIR}${SLASH_ENSMEM_SUBDIR}/INPUT"
-mkdir_vrfy -p "${lbcs_dir}"
+if [ $RUN_ENVIR = "nco" ]; then
+ export INPUT_DATA="${COMIN}"
+else
+ export INPUT_DATA="${COMIN}${SLASH_ENSMEM_SUBDIR}/INPUT"
+fi
+mkdir_vrfy -p "${INPUT_DATA}"
+#
+#-----------------------------------------------------------------------
+#
+# Set the run directory
+#
+#-----------------------------------------------------------------------
+#
+DATA="${DATA:-${COMIN}${SLASH_ENSMEM_SUBDIR}}"
+mkdir_vrfy -p "${DATA}"
#
#-----------------------------------------------------------------------
#
@@ -63,22 +77,17 @@ mkdir_vrfy -p "${lbcs_dir}"
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_make_lbcs.sh \
- lbcs_dir="${lbcs_dir}" || \
+$SCRIPTSdir/exregional_make_lbcs.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_MAKE_OROG b/jobs/JREGIONAL_MAKE_OROG
index 50b6c03697..b28285f07e 100755
--- a/jobs/JREGIONAL_MAKE_OROG
+++ b/jobs/JREGIONAL_MAKE_OROG
@@ -8,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -17,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -52,7 +53,7 @@ This is the J-job script for the task that generates orography files.
#
#-----------------------------------------------------------------------
#
-${SCRIPTSDIR}/exregional_make_orog.sh || \
+${SCRIPTSdir}/exregional_make_orog.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
@@ -78,19 +79,15 @@ Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-touch "$LOGDIR/make_orog_task_complete.txt"
+touch "$OROG_DIR/make_orog_task_complete.txt"
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_MAKE_SFC_CLIMO b/jobs/JREGIONAL_MAKE_SFC_CLIMO
index 24af27bfa3..9a0aff34c1 100755
--- a/jobs/JREGIONAL_MAKE_SFC_CLIMO
+++ b/jobs/JREGIONAL_MAKE_SFC_CLIMO
@@ -8,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -17,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,9 +63,9 @@ mkdir_vrfy -p "${SFC_CLIMO_DIR}"
#
#-----------------------------------------------------------------------
#
-workdir="${SFC_CLIMO_DIR}/tmp"
-check_for_preexist_dir_file "$workdir" "delete"
-mkdir_vrfy $workdir
+DATA="${DATA:-${SFC_CLIMO_DIR}/tmp}"
+check_for_preexist_dir_file "$DATA" "delete"
+mkdir_vrfy $DATA
#
#-----------------------------------------------------------------------
#
@@ -73,8 +74,7 @@ mkdir_vrfy $workdir
#
#-----------------------------------------------------------------------
#
-${SCRIPTSDIR}/exregional_make_sfc_climo.sh \
- workdir="$workdir" || \
+${SCRIPTSdir}/exregional_make_sfc_climo.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
@@ -100,19 +100,15 @@ Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-touch "$LOGDIR/make_sfc_climo_task_complete.txt"
+touch "$SFC_CLIMO_DIR/make_sfc_climo_task_complete.txt"
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_FCST b/jobs/JREGIONAL_RUN_FCST
index dbd4c80c4b..ab56af59a5 100755
--- a/jobs/JREGIONAL_RUN_FCST
+++ b/jobs/JREGIONAL_RUN_FCST
@@ -18,7 +18,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -27,7 +28,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,9 +63,21 @@ the specified cycle.
#
#-----------------------------------------------------------------------
#
-run_dir="${CYCLE_DIR}${SLASH_ENSMEM_SUBDIR}"
-mkdir_vrfy -p ${run_dir}/INPUT
-mkdir_vrfy -p ${run_dir}/RESTART
+if [ $RUN_ENVIR = "nco" ]; then
+ export INPUT_DATA="${COMIN}"
+else
+ export INPUT_DATA="${COMIN}${SLASH_ENSMEM_SUBDIR}/INPUT"
+fi
+#
+#-----------------------------------------------------------------------
+#
+# Create the INPUT and RESTART directories under the run directory.
+#
+#-----------------------------------------------------------------------
+#
+DATA="${DATA:-${COMIN}${SLASH_ENSMEM_SUBDIR}}"
+mkdir_vrfy -p ${DATA}/INPUT
+mkdir_vrfy -p ${DATA}/RESTART
#
#-----------------------------------------------------------------------
#
@@ -73,25 +86,17 @@ mkdir_vrfy -p ${run_dir}/RESTART
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_fcst.sh \
- cdate="${CDATE}" \
- cycle_dir="${CYCLE_DIR}" \
- ensmem_indx="${ENSMEM_INDX}" \
- slash_ensmem_subdir="${SLASH_ENSMEM_SUBDIR}" || \
+$SCRIPTSdir/exregional_run_fcst.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
@@ -101,4 +106,3 @@ In directory: \"${scrfunc_dir}\"
#-----------------------------------------------------------------------
#
{ restore_shell_opts; } > /dev/null 2>&1
-
diff --git a/jobs/JREGIONAL_RUN_POST b/jobs/JREGIONAL_RUN_POST
index 86a30470bb..153c94ca45 100755
--- a/jobs/JREGIONAL_RUN_POST
+++ b/jobs/JREGIONAL_RUN_POST
@@ -17,7 +17,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -26,7 +27,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -61,27 +62,27 @@ on the output files corresponding to a specified forecast hour.
#
#-----------------------------------------------------------------------
#
-run_dir="${CYCLE_DIR}${SLASH_ENSMEM_SUBDIR}"
+DATA="${DATA:-${COMIN}${SLASH_ENSMEM_SUBDIR}}"
#
# If SUB_HOURLY_POST is not set to "TRUE", ensure that the forecast
# minutes (fmn) are set to "00". This is necessary in order to pass
# "fmn" into the post ex-script for the calculation of post_time.
#
if [ "${SUB_HOURLY_POST}" != "TRUE" ]; then
- fmn="00"
+ export fmn="00"
fi
#
#-----------------------------------------------------------------------
#
-# If it doesn't already exist, create the directory (postprd_dir) in which
-# to store post-processing output. (Note that postprd_dir may have already
+# If it doesn't already exist, create the directory (COMOUT) in which
+# to store post-processing output. (Note that COMOUT may have already
# been created by this post-processing script for a different output time
# from the same forecast start time and/or ensemble member.) Also, create
-# a temporary work directory (tmp_dir) for the current output time. This
+# a temporary work directory (DATA_FHR) for the current output time. This
# will be deleted later after the processing for the current output time
-# is complete. Then change location to tmp_dir.
+# is complete. Then change location to DATA_FHR.
#
-# Note that there may be a preexisting version of tmp_dir from previous
+# Note that there may be a preexisting version of DATA_FHR from previous
# runs of this script for the current forecast hour (and current forecast
# start time), e.g. from the workflow task that runs this script failing
# and then being called again. Thus, we first make sure preexisting
@@ -89,23 +90,20 @@ fi
#
#-----------------------------------------------------------------------
#
-if [ "${RUN_ENVIR}" = "nco" ]; then
- COMOUT="${COMOUT_BASEDIR}/$RUN.$PDY/$cyc${SLASH_ENSMEM_SUBDIR}"
- postprd_dir="$COMOUT"
-else
- postprd_dir="${run_dir}/postprd"
+if [ "${RUN_ENVIR}" != "nco" ]; then
+ export COMOUT="${DATA}/postprd"
fi
-mkdir_vrfy -p "${postprd_dir}"
+mkdir_vrfy -p "${COMOUT}"
if [ "${SUB_HOURLY_POST}" = "TRUE" ]; then
- tmp_dir="${postprd_dir}/$fhr$fmn"
+ export DATA_FHR="${DATA:-$COMOUT}/$fhr$fmn"
else
- tmp_dir="${postprd_dir}/$fhr"
+ export DATA_FHR="${DATA:-$COMOUT}/$fhr"
fi
-check_for_preexist_dir_file "${tmp_dir}" "delete"
-mkdir_vrfy -p "${tmp_dir}"
+check_for_preexist_dir_file "${DATA_FHR}" "delete"
+mkdir_vrfy -p "${DATA_FHR}"
-cd_vrfy "${tmp_dir}"
+cd_vrfy "${DATA_FHR}"
#
#-----------------------------------------------------------------------
#
@@ -113,7 +111,7 @@ cd_vrfy "${tmp_dir}"
#
#-----------------------------------------------------------------------
#
-fhr=$( printf "%s" "${fhr}" | $SED -n -r -e "s/^([0-9]+)$/\1/p" )
+export fhr=$( printf "%s" "${fhr}" | $SED -n -r -e "s/^([0-9]+)$/\1/p" )
if [ -z "$fhr" ]; then
print_err_msg_exit "\
The forecast hour (fhr) must be a non-empty string consisting of only
@@ -128,28 +126,17 @@ fi
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_post.sh \
- cdate="${CDATE}" \
- run_dir="${run_dir}" \
- postprd_dir="${postprd_dir}" \
- tmp_dir="${tmp_dir}" \
- fhr="${fhr}" \
- fmn="${fmn}" \
- dt_atmos="${DT_ATMOS}" || \
+$SCRIPTSdir/exregional_run_post.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSGRID b/jobs/JREGIONAL_RUN_VX_ENSGRID
index 867c75fc84..d20f85fa1a 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSGRID
+++ b/jobs/JREGIONAL_RUN_VX_ENSGRID
@@ -17,7 +17,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -26,7 +27,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,22 +63,17 @@ on gridded fields by initialization time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_ensgridvx.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_ensgrid.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSGRID_MEAN b/jobs/JREGIONAL_RUN_VX_ENSGRID_MEAN
index a75558d928..3864d4765b 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSGRID_MEAN
+++ b/jobs/JREGIONAL_RUN_VX_ENSGRID_MEAN
@@ -17,7 +17,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -26,7 +27,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,22 +63,17 @@ on gridded fields by initialization time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_ensgridvx_mean.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_ensgrid_mean.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSGRID_PROB b/jobs/JREGIONAL_RUN_VX_ENSGRID_PROB
index a8a2c43be5..545273f6ad 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSGRID_PROB
+++ b/jobs/JREGIONAL_RUN_VX_ENSGRID_PROB
@@ -17,7 +17,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -26,7 +27,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,22 +63,17 @@ on gridded fields by initialization time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_ensgridvx_prob.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_ensgrid_prob.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSPOINT b/jobs/JREGIONAL_RUN_VX_ENSPOINT
index fc30f076fb..b8edbd292f 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSPOINT
+++ b/jobs/JREGIONAL_RUN_VX_ENSPOINT
@@ -1,12 +1,5 @@
#!/bin/bash
-#
-#-----------------------------------------------------------------------
-#
-#
-#-----------------------------------------------------------------------
-#
-
#
#-----------------------------------------------------------------------
#
@@ -15,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -24,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -60,22 +54,17 @@ by initialitation time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_enspointvx.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_enspoint.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSPOINT_MEAN b/jobs/JREGIONAL_RUN_VX_ENSPOINT_MEAN
index a7d937c12e..6e6351ca72 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSPOINT_MEAN
+++ b/jobs/JREGIONAL_RUN_VX_ENSPOINT_MEAN
@@ -1,12 +1,5 @@
#!/bin/bash
-#
-#-----------------------------------------------------------------------
-#
-#
-#-----------------------------------------------------------------------
-#
-
#
#-----------------------------------------------------------------------
#
@@ -15,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -24,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -60,22 +54,17 @@ by initialitation time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_enspointvx_mean.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_enspoint_mean.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_ENSPOINT_PROB b/jobs/JREGIONAL_RUN_VX_ENSPOINT_PROB
index 818e588e51..244ddd8c5d 100755
--- a/jobs/JREGIONAL_RUN_VX_ENSPOINT_PROB
+++ b/jobs/JREGIONAL_RUN_VX_ENSPOINT_PROB
@@ -1,12 +1,5 @@
#!/bin/bash
-#
-#-----------------------------------------------------------------------
-#
-#
-#-----------------------------------------------------------------------
-#
-
#
#-----------------------------------------------------------------------
#
@@ -15,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -24,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -60,22 +54,17 @@ by initialitation time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_enspointvx_prob.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_enspoint_prob.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_GRIDSTAT b/jobs/JREGIONAL_RUN_VX_GRIDSTAT
index 8537cb3ec5..f6b4b59ce0 100755
--- a/jobs/JREGIONAL_RUN_VX_GRIDSTAT
+++ b/jobs/JREGIONAL_RUN_VX_GRIDSTAT
@@ -17,7 +17,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -26,7 +27,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -62,22 +63,17 @@ by initialization time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_gridstatvx.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_gridstat.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/jobs/JREGIONAL_RUN_VX_POINTSTAT b/jobs/JREGIONAL_RUN_VX_POINTSTAT
index 084543695f..0d5d83a175 100755
--- a/jobs/JREGIONAL_RUN_VX_POINTSTAT
+++ b/jobs/JREGIONAL_RUN_VX_POINTSTAT
@@ -1,12 +1,5 @@
#!/bin/bash
-#
-#-----------------------------------------------------------------------
-#
-#
-#-----------------------------------------------------------------------
-#
-
#
#-----------------------------------------------------------------------
#
@@ -15,7 +8,8 @@
#-----------------------------------------------------------------------
#
. ${GLOBAL_VAR_DEFNS_FP}
-. $USHDIR/source_util_funcs.sh
+. $USHdir/source_util_funcs.sh
+. $USHdir/job_preamble.sh
#
#-----------------------------------------------------------------------
#
@@ -24,7 +18,7 @@
#
#-----------------------------------------------------------------------
#
-{ save_shell_opts; set -u +x; } > /dev/null 2>&1
+{ save_shell_opts; . $USHdir/preamble.sh; } > /dev/null 2>&1
#
#-----------------------------------------------------------------------
#
@@ -60,22 +54,17 @@ by initialitation time for all forecast hours.
#
#-----------------------------------------------------------------------
#
-$SCRIPTSDIR/exregional_run_pointstatvx.sh \
- cycle_dir="${CYCLE_DIR}" || \
+$SCRIPTSdir/exregional_run_vx_pointstat.sh || \
print_err_msg_exit "\
Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed."
#
#-----------------------------------------------------------------------
#
-# Print exit message.
+# Run job postamble.
#
#-----------------------------------------------------------------------
#
-print_info_msg "
-========================================================================
-Exiting script: \"${scrfunc_fn}\"
-In directory: \"${scrfunc_dir}\"
-========================================================================"
+job_postamble
#
#-----------------------------------------------------------------------
#
diff --git a/modulefiles/build_wcoss2_intel b/modulefiles/build_wcoss2_intel
index f7adefb4f7..8e771b6a80 100644
--- a/modulefiles/build_wcoss2_intel
+++ b/modulefiles/build_wcoss2_intel
@@ -7,43 +7,43 @@ proc ModulesHelp { } {
module-whatis "Loads libraries needed for building SRW on WCOSS2 (Cactus/Dogwood)"
-module load envvar/1.0
+module load envvar/$::env(envvar_ver)
-module load PrgEnv-intel/8.1.0
-module load intel/19.1.3.304
-module load craype/2.7.13
-module load cray-mpich/8.1.7
+module load PrgEnv-intel/$::env(PrgEnv_intel_ver)
+module load intel/$::env(intel_ver)
+module load craype/$::env(craype_ver)
+module load cray-mpich/$::env(cray_mpich_ver)
-module load cmake/3.20.2
+module load cmake/$::env(cmake_ver)
setenv HPC_OPT /apps/ops/para/libs
-module use /apps/ops/para/libs/modulefiles/compiler/intel/19.1.3.304
-module use /apps/ops/para/libs/modulefiles/mpi/intel/19.1.3.304/cray-mpich/8.1.7
-
-module load jasper/2.0.25
-module load zlib/1.2.11
-module load libpng/1.6.37
-module load hdf5/1.10.6
-module load netcdf/4.7.4
-module load pio/2.5.2
-module load esmf/8.3.0b09
-module load fms/2022.01
-module load bacio/2.4.1
-module load crtm/2.3.0
-module load g2/3.4.5
-module load g2tmpl/1.10.0
-module load ip/3.3.3
-module load sp/2.3.3
-module load w3nco/2.4.1
-
-module load libjpeg/9c
-module load cray-pals/1.1.3
-
-module load w3emc/2.9.2
-module load nemsio/2.5.2
-module load sigio/2.3.2
-module load sfcio/1.4.1
-module load wrf_io/1.2.0
+module use /apps/ops/para/libs/modulefiles/compiler/intel/$::env(intel_ver)
+module use /apps/ops/para/libs/modulefiles/mpi/intel/$::env(intel_ver)/cray-mpich/$::env(cray_mpich_ver)
+
+module load jasper/$::env(jasper_ver)
+module load zlib/$::env(zlib_ver)
+module load libpng/$::env(libpng_ver)
+module load hdf5/$::env(hdf5_ver)
+module load netcdf/$::env(netcdf_ver)
+module load pio/$::env(pio_ver)
+module load esmf/$::env(esmf_ver)
+module load fms/$::env(fms_ver)
+module load bacio/$::env(bacio_ver)
+module load crtm/$::env(crtm_ver)
+module load g2/$::env(g2_ver)
+module load g2tmpl/$::env(g2tmpl_ver)
+module load ip/$::env(ip_ver)
+module load sp/$::env(sp_ver)
+module load w3nco/$::env(w3nco_ver)
+
+module load libjpeg/$::env(libjpeg_ver)
+module load cray-pals/$::env(cray_pals_ver)
+
+module load w3emc/$::env(w3emc_ver)
+module load nemsio/$::env(nemsio_ver)
+module load sigio/$::env(sigio_ver)
+module load sfcio/$::env(sfcio_ver)
+module load wrf_io/$::env(wrf_io_ver)
setenv CMAKE_C_COMPILER cc
setenv CMAKE_CXX_COMPILER CC
diff --git a/ush/templates/FV3.input.yml b/parm/FV3.input.yml
similarity index 99%
rename from ush/templates/FV3.input.yml
rename to parm/FV3.input.yml
index 0e9276de25..1066d43971 100644
--- a/ush/templates/FV3.input.yml
+++ b/parm/FV3.input.yml
@@ -1,7 +1,7 @@
# This configuration file maintains the modifications that need to be
# made to the base FV3 namelist specified in
#
-# ush/templates/input.nml.FV3
+# parm/input.nml.FV3
#
# to obtain the namelist for each physics suite that the SRW App can
# run with. To build a namelist for one of these configurations, use
diff --git a/ush/templates/FV3LAM_wflow.xml b/parm/FV3LAM_wflow.xml
similarity index 79%
rename from ush/templates/FV3LAM_wflow.xml
rename to parm/FV3LAM_wflow.xml
index 219798afb1..14ca173a03 100644
--- a/ush/templates/FV3LAM_wflow.xml
+++ b/parm/FV3LAM_wflow.xml
@@ -22,7 +22,7 @@ Parameters needed by the job scheduler.
-
+
@@ -86,12 +86,30 @@ specifies the number of processes per node being used (the PPN_... entities).
-
-
-
-
+
+
+
+
+
+
+{%- if run_envir == "nco" %}
+
+
+{%- else %}
+
+
+{%- endif %}
+
+{%- if run_envir == "nco" %}
+
+
+{%- else %}
+
+
+{%- endif %}
+
@@ -139,7 +157,11 @@ tasks; and the "FCST" type is used for the RUN_FCST_TN task.
{%- endfor %}
+ {%- if run_envir == "nco" %}
+ &LOGDIR;/FV3LAM_wflow_{{ workflow_id }}.log
+ {%- else %}
&LOGDIR;/FV3LAM_wflow.log
+ {%- endif %}
- &LOGDIR;/&MAKE_GRID_TN;_task_complete.txt
+ &EXPTDIR;/grid/&MAKE_GRID_TN;&CMPEXT;
&RUN_TASK_MAKE_GRID;FALSE
@@ -229,7 +259,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_DEFAULT;
- &LOAD_MODULES_RUN_TASK_FP; "&MAKE_SFC_CLIMO_TN;" "&JOBSDIR;/JREGIONAL_MAKE_SFC_CLIMO"
+ &LOAD_MODULES_RUN_TASK_FP; "&MAKE_SFC_CLIMO_TN;" "&JOBSdir;/JREGIONAL_MAKE_SFC_CLIMO"
{{ nnodes_make_sfc_climo }}:ppn={{ ppn_make_sfc_climo }}
{{ wtime_make_sfc_climo }}
&NCORES_PER_NODE;
@@ -237,20 +267,24 @@ MODULES_RUN_TASK_FP script.
&SLURM_NATIVE_CMD;
{%- endif %}
&MAKE_SFC_CLIMO_TN;
- &LOGDIR;/&MAKE_SFC_CLIMO_TN;.log
+ &LOGDIR;/&MAKE_SFC_CLIMO_TN;&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
+ PDY@Y@m@d
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
- &LOGDIR;/&MAKE_GRID_TN;_task_complete.txt
+ &EXPTDIR;/grid/&MAKE_GRID_TN;&CMPEXT;
&RUN_TASK_MAKE_GRID;FALSE
- &LOGDIR;/&MAKE_OROG_TN;_task_complete.txt
+ &EXPTDIR;/orog/&MAKE_OROG_TN;&CMPEXT;
&RUN_TASK_MAKE_OROG;FALSE
@@ -266,7 +300,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_HPSS;
- &LOAD_MODULES_RUN_TASK_FP; "&GET_EXTRN_ICS_TN;" "&JOBSDIR;/JREGIONAL_GET_EXTRN_MDL_FILES"
+ &LOAD_MODULES_RUN_TASK_FP; "&GET_EXTRN_ICS_TN;" "&JOBSdir;/JREGIONAL_GET_EXTRN_MDL_FILES"
{{ nnodes_get_extrn_ics }}:ppn={{ ppn_get_extrn_ics }}
{{ wtime_get_extrn_ics }}
&NCORES_PER_NODE;
@@ -274,12 +308,13 @@ MODULES_RUN_TASK_FP script.
&SLURM_NATIVE_CMD;
{%- endif %}
&GET_EXTRN_ICS_TN;
- &LOGDIR;/&GET_EXTRN_ICS_TN;_@Y@m@d@H.log
+ &LOGDIR;/&GET_EXTRN_ICS_TN;_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
ICS_OR_LBCSICS
@@ -292,7 +327,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_HPSS;
- &LOAD_MODULES_RUN_TASK_FP; "&GET_EXTRN_LBCS_TN;" "&JOBSDIR;/JREGIONAL_GET_EXTRN_MDL_FILES"
+ &LOAD_MODULES_RUN_TASK_FP; "&GET_EXTRN_LBCS_TN;" "&JOBSdir;/JREGIONAL_GET_EXTRN_MDL_FILES"
{{ nnodes_get_extrn_lbcs }}:ppn={{ ppn_get_extrn_lbcs }}
{{ wtime_get_extrn_lbcs }}
&NCORES_PER_NODE;
@@ -300,12 +335,13 @@ MODULES_RUN_TASK_FP script.
&SLURM_NATIVE_CMD;
{%- endif %}
&GET_EXTRN_LBCS_TN;
- &LOGDIR;/&GET_EXTRN_LBCS_TN;_@Y@m@d@H.log
+ &LOGDIR;/&GET_EXTRN_LBCS_TN;_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
ICS_OR_LBCSLBCS
@@ -328,7 +364,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_DEFAULT;
- &LOAD_MODULES_RUN_TASK_FP; "&MAKE_ICS_TN;" "&JOBSDIR;/JREGIONAL_MAKE_ICS"
+ &LOAD_MODULES_RUN_TASK_FP; "&MAKE_ICS_TN;" "&JOBSdir;/JREGIONAL_MAKE_ICS"
{{ nnodes_make_ics }}:ppn={{ ppn_make_ics }}
{{ wtime_make_ics }}
&NCORES_PER_NODE;
@@ -336,30 +372,32 @@ MODULES_RUN_TASK_FP script.
&SLURM_NATIVE_CMD;
{%- endif %}
&MAKE_ICS_TN;{{ uscore_ensmem_name }}
- &LOGDIR;/&MAKE_ICS_TN;{{ uscore_ensmem_name }}_@Y@m@d@H.log
+ &LOGDIR;/&MAKE_ICS_TN;{{ uscore_ensmem_name }}_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }}
+ ENSMEM_INDX#{{ ensmem_indx_name }}#
- &LOGDIR;/&MAKE_GRID_TN;_task_complete.txt
+ &EXPTDIR;/grid/&MAKE_GRID_TN;&CMPEXT;
&RUN_TASK_MAKE_GRID;FALSE
- &LOGDIR;/&MAKE_OROG_TN;_task_complete.txt
+ &EXPTDIR;/orog/&MAKE_OROG_TN;&CMPEXT;
&RUN_TASK_MAKE_OROG;FALSE
- &LOGDIR;/&MAKE_SFC_CLIMO_TN;_task_complete.txt
+ &EXPTDIR;/sfc_climo/&MAKE_SFC_CLIMO_TN;&CMPEXT;
&RUN_TASK_MAKE_SFC_CLIMO;FALSE
@@ -375,7 +413,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_DEFAULT;
- &LOAD_MODULES_RUN_TASK_FP; "&MAKE_LBCS_TN;" "&JOBSDIR;/JREGIONAL_MAKE_LBCS"
+ &LOAD_MODULES_RUN_TASK_FP; "&MAKE_LBCS_TN;" "&JOBSdir;/JREGIONAL_MAKE_LBCS"
{{ nnodes_make_lbcs }}:ppn={{ ppn_make_lbcs }}
{{ wtime_make_lbcs }}
&NCORES_PER_NODE;
@@ -383,30 +421,32 @@ MODULES_RUN_TASK_FP script.
&SLURM_NATIVE_CMD;
{%- endif %}
&MAKE_LBCS_TN;{{ uscore_ensmem_name }}
- &LOGDIR;/&MAKE_LBCS_TN;{{ uscore_ensmem_name }}_@Y@m@d@H.log
+ &LOGDIR;/&MAKE_LBCS_TN;{{ uscore_ensmem_name }}_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }}
+ ENSMEM_INDX#{{ ensmem_indx_name }}#
- &LOGDIR;/&MAKE_GRID_TN;_task_complete.txt
+ &EXPTDIR;/grid/&MAKE_GRID_TN;&CMPEXT;
&RUN_TASK_MAKE_GRID;FALSE
- &LOGDIR;/&MAKE_OROG_TN;_task_complete.txt
+ &EXPTDIR;/orog/&MAKE_OROG_TN;&CMPEXT;
&RUN_TASK_MAKE_OROG;FALSE
- &LOGDIR;/&MAKE_SFC_CLIMO_TN;_task_complete.txt
+ &EXPTDIR;/sfc_climo/&MAKE_SFC_CLIMO_TN;&CMPEXT;
&RUN_TASK_MAKE_SFC_CLIMO;FALSE
@@ -422,7 +462,7 @@ MODULES_RUN_TASK_FP script.
&RSRV_FCST;
- &LOAD_MODULES_RUN_TASK_FP; "&RUN_FCST_TN;" "&JOBSDIR;/JREGIONAL_RUN_FCST"
+ &LOAD_MODULES_RUN_TASK_FP; "&RUN_FCST_TN;" "&JOBSdir;/JREGIONAL_RUN_FCST"
{%- if machine in ["JET", "HERA", "LINUX"] %}
{{ ncores_run_fcst }}
{{ native_run_fcst }}
@@ -435,12 +475,13 @@ MODULES_RUN_TASK_FP script.
{%- endif %}
{{ wtime_run_fcst }}
&RUN_FCST_TN;{{ uscore_ensmem_name }}
- &LOGDIR;/&RUN_FCST_TN;{{ uscore_ensmem_name }}_@Y@m@d@H.log
+ &LOGDIR;/&RUN_FCST_TN;{{ uscore_ensmem_name }}_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
+ cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }}
ENSMEM_INDX#{{ ensmem_indx_name }}#
@@ -480,7 +521,7 @@ later below for other output times.
&RSRV_DEFAULT;
- &LOAD_MODULES_RUN_TASK_FP; "&RUN_POST_TN;" "&JOBSDIR;/JREGIONAL_RUN_POST"
+ &LOAD_MODULES_RUN_TASK_FP; "&RUN_POST_TN;" "&JOBSdir;/JREGIONAL_RUN_POST"
{{ nnodes_run_post }}:ppn={{ ppn_run_post }}
{{ wtime_run_post }}
&NCORES_PER_NODE;
@@ -488,16 +529,17 @@ later below for other output times.
&SLURM_NATIVE_CMD;
{%- endif %}
&RUN_POST_TN;{{ uscore_ensmem_name }}_f#fhr##fmn#
- &LOGDIR;/&RUN_POST_TN;{{ uscore_ensmem_name }}_f#fhr##fmn#_@Y@m@d@H.log
+ &LOGDIR;/&RUN_POST_TN;{{ uscore_ensmem_name }}_f#fhr##fmn#_@Y@m@d@H&LOGEXT;
GLOBAL_VAR_DEFNS_FP&GLOBAL_VAR_DEFNS_FP;
PDY@Y@m@d
- CDATE@Y@m@d@H
- CYCLE_DIR&CYCLE_BASEDIR;/@Y@m@d@H
- SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }}
cyc@H
+ subcyc@M
+ LOGDIR&LOGDIR;
fhr#fhr#
fmn#fmn#
+ SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }}
+ ENSMEM_INDX#{{ ensmem_indx_name }}#
leave empty for REFC and RETOP
export FHR=`echo $(seq 0 ${ACCUM} ${FCST_LEN_HRS}) | cut -d" " -f2-`
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSGRID
+${JOBSdir}/JREGIONAL_RUN_VX_ENSGRID
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSGRID_MEAN
+${JOBSdir}/JREGIONAL_RUN_VX_ENSGRID_MEAN
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSGRID_PROB
+${JOBSdir}/JREGIONAL_RUN_VX_ENSGRID_PROB
diff --git a/ush/wrappers/run_gridvx.sh b/ush/wrappers/run_gridvx.sh
index a96383f6ed..71a577ef51 100755
--- a/ush/wrappers/run_gridvx.sh
+++ b/ush/wrappers/run_gridvx.sh
@@ -15,5 +15,5 @@ export ACCUM="06" # 01 03 06 24 --> leave empty for REFC and RETOP
export FHR=`echo $(seq 0 ${ACCUM} ${FCST_LEN_HRS}) | cut -d" " -f2-`
-${JOBSDIR}/JREGIONAL_RUN_VX_GRIDSTAT
+${JOBSdir}/JREGIONAL_RUN_VX_GRIDSTAT
diff --git a/ush/wrappers/run_make_grid.sh b/ush/wrappers/run_make_grid.sh
index 96fd8a4ec4..9b2242f0f4 100755
--- a/ush/wrappers/run_make_grid.sh
+++ b/ush/wrappers/run_make_grid.sh
@@ -5,4 +5,4 @@ source ${GLOBAL_VAR_DEFNS_FP}
export CDATE=${DATE_FIRST_CYCL}${CYCL_HRS}
export CYCLE_DIR=${EXPTDIR}/${CDATE}
-${JOBSDIR}/JREGIONAL_MAKE_GRID
+${JOBSdir}/JREGIONAL_MAKE_GRID
diff --git a/ush/wrappers/run_make_ics.sh b/ush/wrappers/run_make_ics.sh
index de3d3de6d2..8ecfce2799 100755
--- a/ush/wrappers/run_make_ics.sh
+++ b/ush/wrappers/run_make_ics.sh
@@ -6,5 +6,5 @@ export CDATE=${DATE_FIRST_CYCL}${CYCL_HRS}
export CYCLE_DIR=${EXPTDIR}/${CDATE}
export SLASH_ENSMEM_SUBDIR=""
-${JOBSDIR}/JREGIONAL_MAKE_ICS
+${JOBSdir}/JREGIONAL_MAKE_ICS
diff --git a/ush/wrappers/run_make_lbcs.sh b/ush/wrappers/run_make_lbcs.sh
index adae78ea4a..7377444738 100755
--- a/ush/wrappers/run_make_lbcs.sh
+++ b/ush/wrappers/run_make_lbcs.sh
@@ -6,5 +6,5 @@ export CDATE=${DATE_FIRST_CYCL}${CYCL_HRS}
export CYCLE_DIR=${EXPTDIR}/${CDATE}
export SLASH_ENSMEM_SUBDIR=""
-${JOBSDIR}/JREGIONAL_MAKE_LBCS
+${JOBSdir}/JREGIONAL_MAKE_LBCS
diff --git a/ush/wrappers/run_make_orog.sh b/ush/wrappers/run_make_orog.sh
index cf1adab4c4..cf1972e6de 100755
--- a/ush/wrappers/run_make_orog.sh
+++ b/ush/wrappers/run_make_orog.sh
@@ -5,4 +5,4 @@ source ${GLOBAL_VAR_DEFNS_FP}
export CDATE=${DATE_FIRST_CYCL}${CYCL_HRS}
export CYCLE_DIR=${EXPTDIR}/${CDATE}
-${JOBSDIR}/JREGIONAL_MAKE_OROG
+${JOBSdir}/JREGIONAL_MAKE_OROG
diff --git a/ush/wrappers/run_make_sfc_climo.sh b/ush/wrappers/run_make_sfc_climo.sh
index 06c9260793..538d6f8924 100755
--- a/ush/wrappers/run_make_sfc_climo.sh
+++ b/ush/wrappers/run_make_sfc_climo.sh
@@ -5,4 +5,4 @@ source ${GLOBAL_VAR_DEFNS_FP}
export CDATE=${DATE_FIRST_CYCL}${CYCL_HRS}
export CYCLE_DIR=${EXPTDIR}/${CDATE}
-${JOBSDIR}/JREGIONAL_MAKE_SFC_CLIMO
+${JOBSdir}/JREGIONAL_MAKE_SFC_CLIMO
diff --git a/ush/wrappers/run_pointensvx.sh b/ush/wrappers/run_pointensvx.sh
index 142d9ec833..f066ea8676 100755
--- a/ush/wrappers/run_pointensvx.sh
+++ b/ush/wrappers/run_pointensvx.sh
@@ -12,9 +12,9 @@ export OBS_DIR=${NDAS_OBS_DIR}
export FHR=`echo $(seq 0 1 ${FCST_LEN_HRS})`
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSPOINT
+${JOBSdir}/JREGIONAL_RUN_VX_ENSPOINT
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSPOINT_MEAN
+${JOBSdir}/JREGIONAL_RUN_VX_ENSPOINT_MEAN
-${JOBSDIR}/JREGIONAL_RUN_VX_ENSPOINT_PROB
+${JOBSdir}/JREGIONAL_RUN_VX_ENSPOINT_PROB
diff --git a/ush/wrappers/run_pointvx.sh b/ush/wrappers/run_pointvx.sh
index 527c16f37d..5f87d29fbc 100755
--- a/ush/wrappers/run_pointvx.sh
+++ b/ush/wrappers/run_pointvx.sh
@@ -13,5 +13,5 @@ export OBS_DIR=${NDAS_OBS_DIR}
export FHR=`echo $(seq 0 1 ${FCST_LEN_HRS})`
-${JOBSDIR}/JREGIONAL_RUN_VX_POINTSTAT
+${JOBSdir}/JREGIONAL_RUN_VX_POINTSTAT
diff --git a/ush/wrappers/run_post.sh b/ush/wrappers/run_post.sh
index 1c8f3d4dfb..6e63226d21 100755
--- a/ush/wrappers/run_post.sh
+++ b/ush/wrappers/run_post.sh
@@ -11,5 +11,5 @@ export ENSMEM_INDX=""
num_fcst_hrs=${FCST_LEN_HRS}
for (( i=0; i<=$((num_fcst_hrs)); i++ )); do
export fhr=`printf "%03i" ${i}`
- ${JOBSDIR}/JREGIONAL_RUN_POST
+ ${JOBSdir}/JREGIONAL_RUN_POST
done
diff --git a/versions/build.ver b/versions/build.ver
new file mode 120000
index 0000000000..fb0c92cf93
--- /dev/null
+++ b/versions/build.ver
@@ -0,0 +1 @@
+build.ver.wcoss2
\ No newline at end of file
diff --git a/versions/build.ver.wcoss2 b/versions/build.ver.wcoss2
new file mode 100644
index 0000000000..9a89f97716
--- /dev/null
+++ b/versions/build.ver.wcoss2
@@ -0,0 +1,35 @@
+#!/bin/bash
+
+export module_ver=8.5.2
+export gfs_ver=v16.2
+
+export envvar_ver=1.0
+export PrgEnv_intel_ver=8.1.0
+export intel_ver=19.1.3.304
+export craype_ver=2.7.13
+export cray_mpich_ver=8.1.7
+export cmake_ver=3.20.2
+export intel_ver=19.1.3.304
+export cray_mpich_ver=8.1.7
+export jasper_ver=2.0.25
+export zlib_ver=1.2.11
+export libpng_ver=1.6.37
+export hdf5_ver=1.10.6
+export netcdf_ver=4.7.4
+export pio_ver=2.5.2
+export esmf_ver=8.3.0b09
+export fms_ver=2022.01
+export bacio_ver=2.4.1
+export crtm_ver=2.3.0
+export g2_ver=3.4.5
+export g2tmpl_ver=1.10.0
+export ip_ver=3.3.3
+export sp_ver=2.3.3
+export w3nco_ver=2.4.1
+export libjpeg_ver=9c
+export cray_pals_ver=1.1.3
+export w3emc_ver=2.9.2
+export nemsio_ver=2.5.2
+export sigio_ver=2.3.2
+export sfcio_ver=1.4.1
+export wrf_io_ver=1.2.0
diff --git a/versions/run.ver b/versions/run.ver
new file mode 120000
index 0000000000..feb792992b
--- /dev/null
+++ b/versions/run.ver
@@ -0,0 +1 @@
+run.ver.wcoss2
\ No newline at end of file
diff --git a/versions/run.ver.wcoss2 b/versions/run.ver.wcoss2
new file mode 100644
index 0000000000..a9bf588e2f
--- /dev/null
+++ b/versions/run.ver.wcoss2
@@ -0,0 +1 @@
+#!/bin/bash