diff --git a/jobs/JREGIONAL_GET_GEFS_LBCS_FILES b/jobs/JREGIONAL_GET_GEFS_LBCS_FILES new file mode 100755 index 000000000..490f83e59 --- /dev/null +++ b/jobs/JREGIONAL_GET_GEFS_LBCS_FILES @@ -0,0 +1,194 @@ +#!/bin/bash + +# +#----------------------------------------------------------------------- +# +# This script gets from the system directory the files generated by +# the external model (GEFS, specified by the variable EXTRN_MDL_NAME) +# for the lateral boundary conditions (LBCs). +# And then perform time interpolation to get the missing hourly GEFS +# files from the 3-hourly data, using wgrib2. +# +#----------------------------------------------------------------------- +# +# Source the variable definitions file and the bash utility functions. +# +#----------------------------------------------------------------------- +# +. ${GLOBAL_VAR_DEFNS_FP} +. $USHDIR/source_util_funcs.sh +# +#----------------------------------------------------------------------- +# +# Source the file defining the function that will be used to set various +# external-model-associated variables. +# +#----------------------------------------------------------------------- +# +. $USHDIR/get_extrn_mdl_file_dir_info.sh +# +#----------------------------------------------------------------------- +# +# Save current shell options (in a global array). Then set new options +# for this script/function. +# +#----------------------------------------------------------------------- +# +{ save_shell_opts; set -u +x; } > /dev/null 2>&1 +# +#----------------------------------------------------------------------- +# +# Get the full path to the file in which this script/function is located +# (scrfunc_fp), the name of that file (scrfunc_fn), and the directory in +# which the file is located (scrfunc_dir). +# +#----------------------------------------------------------------------- +# +scrfunc_fp=$( readlink -f "${BASH_SOURCE[0]}" ) +scrfunc_fn=$( basename "${scrfunc_fp}" ) +scrfunc_dir=$( dirname "${scrfunc_fp}" ) +# +#----------------------------------------------------------------------- +# +# Print message indicating entry into script. +# +#----------------------------------------------------------------------- +# +print_info_msg " +======================================================================== +Entering script: \"${scrfunc_fn}\" +In directory: \"${scrfunc_dir}\" + +This is the J-job script for the task that copies/fetches to a local +directory (from disk) the external model files from which +boundary condition files for the FV3 will be generated. +========================================================================" +# +#----------------------------------------------------------------------- +# +# Check whether the environment variable ICS_OR_LBCS is set to a valid +# value. This variable specifies whether we are getting the external +# model files for the purpose of generating initial conditions (ICs) or +# lateral boundary condtions (LBCs) for the forecast model. +# +#----------------------------------------------------------------------- +# +valid_vals_ICS_OR_LBCS=( "ICS" "LBCS" ) +check_var_valid_value "ICS_OR_LBCS" "valid_vals_ICS_OR_LBCS" +# +#----------------------------------------------------------------------- +# +# Set the parameter anl_or_fcst that determines whether we want to get +# analysis or forecast files. This depends on whether we want these files +# to generate initial condition and surface field files or lateral boundary +# condition files. Also, set time_offset_hrs, which is the offset in +# hours between the current cycle's starting time and the starting time +# of the external model providing the LBCs. +# +#----------------------------------------------------------------------- +# +anl_or_fcst="FCST" +time_offset_hrs="${EXTRN_MDL_LBCS_OFFSET_HRS}" +lbs_spec_intvl_hrs="${LBC_SPEC_INTVL_HRS}" +boundary_len_hrs="${BOUNDARY_LEN}" +# +#----------------------------------------------------------------------- +# +# Set the name of and then create the directory in which to stage the +# external model files for the current cycle (if it doesn't already exist). +# Then change location to that directory. +# +#----------------------------------------------------------------------- +# +extrn_mdl_staging_dir="${CYCLE_DIR}${SLASH_ENSMEM_SUBDIR}/${EXTRN_MDL_NAME}/for_LBCS" +if [ -d "${extrn_mdl_staging_dir}" ]; then + rm -rf ${extrn_mdl_staging_dir} +fi +mkdir_vrfy -p "${extrn_mdl_staging_dir}" +cd_vrfy "${extrn_mdl_staging_dir}" +# +#----------------------------------------------------------------------- +# +# Call the function that sets various external-model-associated variables. +# See the function defintion file for the definitions of these variables. +# +#----------------------------------------------------------------------- +# +get_extrn_mdl_file_dir_info \ + extrn_mdl_name="${EXTRN_MDL_NAME}" \ + anl_or_fcst="${anl_or_fcst}" \ + cdate_FV3LAM="${CDATE}" \ + lbs_spec_intvl_hrs="${lbs_spec_intvl_hrs}" \ + boundary_len_hrs="${boundary_len_hrs}"\ + time_offset_hrs="${time_offset_hrs}" \ + varname_extrn_mdl_memhead="${GEFS_INPUT_SUBDIR}" \ + varname_extrn_mdl_cdate="extrn_mdl_cdate" \ + varname_extrn_mdl_lbc_spec_fhrs="extrn_mdl_lbc_spec_fhrs" \ + varname_extrn_mdl_fns_on_disk="extrn_mdl_fns_on_disk" \ + varname_extrn_mdl_fns_on_disk2="extrn_mdl_fns_on_disk2" \ + varname_extrn_mdl_fns_in_arcv="extrn_mdl_fns_in_arcv" \ + varname_extrn_mdl_sysdir="extrn_mdl_sysdir" \ + varname_extrn_mdl_sysdir2="extrn_mdl_sysdir2" \ + varname_extrn_mdl_arcv_fmt="extrn_mdl_arcv_fmt" \ + varname_extrn_mdl_arcv_fns="extrn_mdl_arcv_fns" \ + varname_extrn_mdl_arcv_fps="extrn_mdl_arcv_fps" \ + varname_extrn_mdl_arcvrel_dir="extrn_mdl_arcvrel_dir" || \ +print_err_msg_exit "\ +Call to function get_extrn_mdl_file_dir_info failed." +# +#----------------------------------------------------------------------- +# +# Set the directory in which to check for the external model files (which +# we refer to here as the "source" directory) to the default one set above +# for the current machine and external model. +# +#----------------------------------------------------------------------- +# +extrn_mdl_source_dir="${extrn_mdl_sysdir}" +extrn_mdl_source_dir2="${extrn_mdl_sysdir2}" +# +#----------------------------------------------------------------------- +# +# Call the ex-script for this J-job and pass to it the necessary variables. +# +#----------------------------------------------------------------------- +# +extrn_mdl_lbc_spec_fhrs_str="( "$( printf "\"%s\" " "${extrn_mdl_lbc_spec_fhrs[@]}" )")" +extrn_mdl_fns_on_disk_str="( "$( printf "\"%s\" " "${extrn_mdl_fns_on_disk[@]}" )")" +extrn_mdl_fns_on_disk_str2="( "$( printf "\"%s\" " "${extrn_mdl_fns_on_disk2[@]}" )")" +extrn_mdl_fns_in_arcv_str="( "$( printf "\"%s\" " "${extrn_mdl_fns_in_arcv[@]}" )")" + +$SCRIPTSDIR/exregional_get_gefs_lbcs_files.sh \ + ics_or_lbcs="${ICS_OR_LBCS}" \ + use_user_staged_extrn_files="${USE_USER_STAGED_EXTRN_FILES}" \ + extrn_mdl_cdate="${extrn_mdl_cdate}" \ + extrn_mdl_lbc_spec_fhrs="${extrn_mdl_lbc_spec_fhrs_str}" \ + extrn_mdl_fns_on_disk="${extrn_mdl_fns_on_disk_str}" \ + extrn_mdl_fns_on_disk2="${extrn_mdl_fns_on_disk_str2}" \ + extrn_mdl_fns_in_arcv="${extrn_mdl_fns_in_arcv_str}" \ + extrn_mdl_source_dir="${extrn_mdl_source_dir}" \ + extrn_mdl_source_dir2="${extrn_mdl_source_dir2}" \ + extrn_mdl_staging_dir="${extrn_mdl_staging_dir}" || \ +print_err_msg_exit "\ +Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed." +# +#----------------------------------------------------------------------- +# +# Print exit message. +# +#----------------------------------------------------------------------- +# +print_info_msg " +======================================================================== +Exiting script: \"${scrfunc_fn}\" +In directory: \"${scrfunc_dir}\" +========================================================================" +# +#----------------------------------------------------------------------- +# +# Restore the shell options saved at the beginning of this script/function. +# +#----------------------------------------------------------------------- +# +{ restore_shell_opts; } > /dev/null 2>&1 + diff --git a/scripts/exregional_get_gefs_lbcs_files.sh b/scripts/exregional_get_gefs_lbcs_files.sh new file mode 100755 index 000000000..81ba13939 --- /dev/null +++ b/scripts/exregional_get_gefs_lbcs_files.sh @@ -0,0 +1,341 @@ +#!/bin/bash +set +x +# +#----------------------------------------------------------------------- +# +# Source the variable definitions file and the bash utility functions. +# +#----------------------------------------------------------------------- +# +. ${GLOBAL_VAR_DEFNS_FP} +. $USHDIR/source_util_funcs.sh +# +#----------------------------------------------------------------------- +# +# Save current shell options (in a global array). Then set new options +# for this script/function. +# +#----------------------------------------------------------------------- +# +{ save_shell_opts; set -u +x; } > /dev/null 2>&1 +# +#----------------------------------------------------------------------- +# +# Get the full path to the file in which this script/function is located +# (scrfunc_fp), the name of that file (scrfunc_fn), and the directory in +# which the file is located (scrfunc_dir). +# +#----------------------------------------------------------------------- +# +scrfunc_fp=$( readlink -f "${BASH_SOURCE[0]}" ) +scrfunc_fn=$( basename "${scrfunc_fp}" ) +scrfunc_dir=$( dirname "${scrfunc_fp}" ) +# +#----------------------------------------------------------------------- +# +# Print message indicating entry into script. +# +#----------------------------------------------------------------------- +# +print_info_msg " +======================================================================== +Entering script: \"${scrfunc_fn}\" +In directory: \"${scrfunc_dir}\" + +This is the ex-script for the task that copies/fetches to a local directory +either from disk or HPSS) the external model files from which initial or +boundary condition files for the FV3 will be generated. +========================================================================" +# +#----------------------------------------------------------------------- +# +# Specify the set of valid argument names for this script/function. Then +# process the arguments provided to this script/function (which should +# consist of a set of name-value pairs of the form arg1="value1", etc). +# +#----------------------------------------------------------------------- +# +valid_args=( \ +"ics_or_lbcs" \ +"use_user_staged_extrn_files" \ +"extrn_mdl_cdate" \ +"extrn_mdl_lbc_spec_fhrs" \ +"extrn_mdl_fns_on_disk" \ +"extrn_mdl_fns_on_disk2" \ +"extrn_mdl_fns_in_arcv" \ +"extrn_mdl_source_dir" \ +"extrn_mdl_source_dir2" \ +"extrn_mdl_staging_dir" \ +) +process_args valid_args "$@" +# +#----------------------------------------------------------------------- +# +# For debugging purposes, print out values of arguments passed to this +# script. Note that these will be printed out only if VERBOSE is set to +# TRUE. +# +#----------------------------------------------------------------------- +# +print_input_args valid_args +# +#----------------------------------------------------------------------- +# +# Load modules. +# +#----------------------------------------------------------------------- +# +case $MACHINE in + + "WCOSS2") + module load wgrib2/2.0.8 + module list + ;; + + "HERA") + module load gnu/9.2.0 + module load wgrib2/3.1.0 + wgrib2=/apps/wgrib2/3.1.0/gnu/9.2.0_ncep/bin/wgrib2 + ;; + + "JET") + module load intel/18.0.5.274 + module load wgrib2/2.0.8 + wgrib2=/apps/wgrib2/2.0.8/intel/18.0.5.274/bin/wgrib2 + ;; + + *) + print_err_msg_exit "\ +Wgrib2 has not been specified for this machine: + MACHINE = \"$MACHINE\" + wgrib2 = `which wgrib2` " + ;; + +esac +# +#----------------------------------------------------------------------- +# +# Set num_files_to_copy to the number of external model files that need +# to be copied or linked to from/at a location on disk. Then set +# extrn_mdl_fps_on_disk to the full paths of the external model files +# on disk. +# +#----------------------------------------------------------------------- +# +num_files_to_copy="${#extrn_mdl_fns_on_disk[@]}" +prefix="${extrn_mdl_source_dir}/" +extrn_mdl_fps_on_disk=( "${extrn_mdl_fns_on_disk[@]/#/$prefix}" ) +prefix2="${extrn_mdl_source_dir2}" +extrn_mdl_fps_on_disk2=( "${extrn_mdl_fns_on_disk2[@]/#/$prefix2}" ) +# +#----------------------------------------------------------------------- +# +# Loop through the list of external model files and check whether they +# all exist on disk. The counter num_files_found_on_disk keeps track of +# the number of external model files that were actually found on disk in +# the directory specified by extrn_mdl_source_dir. +# +#----------------------------------------------------------------------- +# +num_files_found_on_disk="0" +min_age="5" # Minimum file age, in minutes. +# +#----------------------------------------------------------------------- +# +# Set the variable (data_src) that determines the source of the external +# model files (either disk or HPSS). +# +#----------------------------------------------------------------------- +# +data_src="disk" +# +#----------------------------------------------------------------------- +# +# If the source of the external model files is "disk", copy the files +# from the source directory on disk to a staging directory. +# +#----------------------------------------------------------------------- +# +extrn_mdl_fns_on_disk_str="( "$( printf "\"%s\" " "${extrn_mdl_fns_on_disk[@]}" )")" + +if [ "${RUN_ENVIR}" = "nco" ]; then + + print_info_msg " +Creating links in staging directory (extrn_mdl_staging_dir) to external +model files on disk (extrn_mdl_fns_on_disk) in the source directory +(extrn_mdl_source_dir): + extrn_mdl_staging_dir = \"${extrn_mdl_staging_dir}\" + extrn_mdl_source_dir = \"${extrn_mdl_source_dir}\" + extrn_mdl_fns_on_disk = ${extrn_mdl_fns_on_disk_str}" + + for fps in "${extrn_mdl_fps_on_disk[@]}" ; do + if [ -f "$fps" ]; then + # + # Increment the counter that keeps track of the number of external + # model files found on disk and print out an informational message. + # + ln_vrfy -sf -t ${extrn_mdl_staging_dir} ${fps} + print_info_msg " +File fps exists on disk: + fps = \"$fps\"" + fi + done +else + # + # If the external model files are user-staged, then simply link to + # them. Otherwise, if they are on the system disk, copy them to the + # staging directory. + # + if [ "${use_user_staged_extrn_files}" = "TRUE" ]; then + print_info_msg " +Creating symlinks in the staging directory (extrn_mdl_staging_dir) to the +external model files on disk (extrn_mdl_fns_on_disk) in the source directory +(extrn_mdl_source_dir): + extrn_mdl_source_dir = \"${extrn_mdl_source_dir}\" + extrn_mdl_fns_on_disk = ${extrn_mdl_fns_on_disk_str} + extrn_mdl_staging_dir = \"${extrn_mdl_staging_dir}\"" + ln_vrfy -sf -t ${extrn_mdl_staging_dir} ${extrn_mdl_fps_on_disk[@]} + else + print_info_msg " +Copying external model files on disk (extrn_mdl_fns_on_disk) from source +directory (extrn_mdl_source_dir) to staging directory (extrn_mdl_staging_dir): + extrn_mdl_source_dir = \"${extrn_mdl_source_dir}\" + extrn_mdl_fns_on_disk = ${extrn_mdl_fns_on_disk_str} + extrn_mdl_staging_dir = \"${extrn_mdl_staging_dir}\"" + cp_vrfy ${extrn_mdl_fps_on_disk[@]} ${extrn_mdl_staging_dir} + fi +fi +# +#----------------------------------------------------------------------- +# +# Print message indicating successful completion of script. +# +#----------------------------------------------------------------------- +# + print_info_msg " +======================================================================== +Successfully copied or linked to external model files on disk needed for +generating lateral boundary conditions for the FV3 forecast!!! +Now move to time interpolation!!! +========================================================================" +# +#----------------------------------------------------------------------- +# +# Create a variable definitions file (a shell script) and save in it the +# values of several external-model-associated variables generated in this +# script that will be needed by downstream workflow tasks. +# +#----------------------------------------------------------------------- +# +extrn_mdl_var_defns_fn="${EXTRN_MDL_LBCS_VAR_DEFNS_FN}" +extrn_mdl_var_defns_fp="${extrn_mdl_staging_dir}/${extrn_mdl_var_defns_fn}" +check_for_preexist_dir_file "${extrn_mdl_var_defns_fp}" "delete" + +if [ "${data_src}" = "disk" ]; then + extrn_mdl_fns_str="( "$( printf "\"%s\" " "${extrn_mdl_fns_on_disk[@]}" )")" +fi + +# +#----------------------------------------------------------------------- +# + +yyyymmdd=${extrn_mdl_cdate:0:8} +hh=${extrn_mdl_cdate:8:2} + +echo extrn_mdl_cdate=${extrn_mdl_cdate} +echo " yyyymmddhh= ${yyyymmdd} ${hh} " + +for files in "${extrn_mdl_fps_on_disk[@]}"; do + file=$( basename "$files" ) + echo " Checking for $file " + if [[ -f ${extrn_mdl_staging_dir}/$file ]]; then + echo "Found ${extrn_mdl_staging_dir}/$file " + else + fcsthr=$( echo $file | awk '{print substr($0, length($0)-2)}' | sed 's/^0*//' ) + +print_info_msg " +======================================================================== + +Missing $files for forecast hour $fcsthr ! +Need to do time interpolation! + +========================================================================" + + fcsthr_0=$(( fcsthr % 3 )) + echo fcsthr_0=${fcsthr_0} + fcsthr_m=$(( fcsthr - fcsthr_0 )) + echo fcsthr_m=${fcsthr_m} + fcsthr_p=$(( fcsthr - fcsthr_0 + 3 )) + echo fcsthr_p=${fcsthr_p} + fhrm=$( printf "%03d" ${fcsthr_m} ) + echo fhrm=${fhrm} + fhrp=$( printf "%03d" ${fcsthr_p} ) + echo fhrp=${fhrp} + in1=$( echo $file | sed 's/...$/'${fhrm}'/g' ) + echo in1=${in1} + in2=$( echo $file | sed 's/...$/'${fhrp}'/g' ) + echo in2=${in2} + vtime=$( date +%Y%m%d%H -d "${yyyymmdd} ${hh} +${fcsthr_m} hours" ) + echo vtime = $vtime + a="vt=${vtime}" + d1="${fcsthr} hour forecast" + echo $d1 + c=$( expr ${fcsthr_0}/3 | bc -l ) + c1=$( printf "%.5f\n" $c ) + b1=$( expr 1-$c1 | bc -l ) + echo " b1,c1= $b1 $c1 " + +print_info_msg " +======================================================================== +Deriving ${extrn_mdl_staging_dir}/$file +based on +${extrn_mdl_staging_dir}/$in1 +and +${extrn_mdl_staging_dir}/$in2 +========================================================================" + + $wgrib2 ${extrn_mdl_staging_dir}/$in1 -rpn sto_1 -import_grib ${extrn_mdl_staging_dir}/$in2 -rpn sto_2 -set_grib_type same \ + -if ":$a:" \ + -rpn "rcl_1:$b1:*:rcl_2:$c1:*:+" -set_ftime "$d1" -set_scaling same same -grib_out ${extrn_mdl_staging_dir}/$file + +print_info_msg " +======================================================================== +Done interpolating the GEFS lbcs files for hour \"${fcsthr}\" +========================================================================" + + fi + +done + +settings="\ +DATA_SRC=\"${data_src}\" +EXTRN_MDL_CDATE=\"${extrn_mdl_cdate}\" +EXTRN_MDL_STAGING_DIR=\"${extrn_mdl_staging_dir}\" +EXTRN_MDL_FNS=${extrn_mdl_fns_str}" +# +# If the external model files obtained above were for generating LBCS (as +# opposed to ICs), then add to the external model variable definitions +# file the array variable EXTRN_MDL_LBC_SPEC_FHRS containing the forecast +# hours at which the lateral boundary conditions are specified. +# +extrn_mdl_lbc_spec_fhrs_str="( "$( printf "\"%s\" " "${extrn_mdl_lbc_spec_fhrs[@]}" )")" +settings="$settings +EXTRN_MDL_LBC_SPEC_FHRS=${extrn_mdl_lbc_spec_fhrs_str}" + +{ cat << EOM >> ${extrn_mdl_var_defns_fp} +$settings +EOM +} || print_err_msg_exit "\ +Heredoc (cat) command to create a variable definitions file associated +with the external model from which to generate ${ics_or_lbcs} returned with a +nonzero status. The full path to this variable definitions file is: + extrn_mdl_var_defns_fp = \"${extrn_mdl_var_defns_fp}\"" +# +#----------------------------------------------------------------------- +# +# Restore the shell options saved at the beginning of this script/function. +# +#----------------------------------------------------------------------- +# +{ restore_shell_opts; } > /dev/null 2>&1 + diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index dd26b4b22..d7c28afd5 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -700,7 +700,7 @@ grid_ratio_ens=3 #if analysis is 3km, then ensemble=3*3=9km. GDAS i_en_perts_io=1 #0 or 1: original file 3: pre-processed ensembles q_hyb_ens=.false. ens_fast_read=.false. -CORRLENGTH=400 #horizontal localization scale of "Gaspari-Cohn function=0" for EnKF (km) +CORRLENGTH=300 #horizontal localization scale of "Gaspari-Cohn function=0" for EnKF (km) LNSIGCUTOFF=0.5 #vertical localization scale of "Gaspari-Cohn function=0" for EnKF (lnp) CORRLENGTH_radardbz=18 #horizontal localization scale of "Gaspari-Cohn function=0" for radardbz EnKF (km) LNSIGCUTOFF_radardbz=0.5 #vertical localization scale of "Gaspari-Cohn function=0" for radardbz EnKF (lnp) @@ -1683,6 +1683,7 @@ MAKE_SFC_CLIMO_TN="make_sfc_climo" GET_EXTRN_ICS_TN="get_extrn_ics" GET_EXTRN_LBCS_TN="get_extrn_lbcs" GET_EXTRN_LBCS_LONG_TN="get_extrn_lbcs_long" +GET_GEFS_LBCS_TN="get_gefs_lbcs" MAKE_ICS_TN="make_ics" MAKE_LBCS_TN="make_lbcs" RUN_FCST_TN="run_fcst" diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index ccd89f581..95f6e81af 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -201,6 +201,7 @@ settings="\ 'get_extrn_ics_tn': ${GET_EXTRN_ICS_TN} 'get_extrn_lbcs_tn': ${GET_EXTRN_LBCS_TN} 'get_extrn_lbcs_long_tn': ${GET_EXTRN_LBCS_LONG_TN} + 'get_gefs_lbcs_tn': ${GET_GEFS_LBCS_TN} 'make_ics_tn': ${MAKE_ICS_TN} 'make_lbcs_tn': ${MAKE_LBCS_TN} 'run_fcst_tn': ${RUN_FCST_TN} diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index a330a106d..07dfcfb2c 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -123,7 +123,7 @@ else EXTRN_MDL_SYSBASEDIR_ICS="" ;; "JET") - EXTRN_MDL_SYSBASEDIR_ICS="${EXTRN_MDL_SOURCE_BASEDIR_ICS:-/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b}" + EXTRN_MDL_SYSBASEDIR_ICS="${EXTRN_MDL_SOURCE_BASEDIR_ICS:-"/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b"}" ;; "HERA") EXTRN_MDL_SYSBASEDIR_ICS="${EXTRN_MDL_SOURCE_BASEDIR_ICS:-/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b}" @@ -319,7 +319,7 @@ else "GEFS") case "$MACHINE" in "JET") - EXTRN_MDL_SYSBASEDIR_LBCS="${EXTRN_MDL_SOURCE_BASEDIR_LBCS:-/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b}" + EXTRN_MDL_SYSBASEDIR_LBCS="${EXTRN_MDL_SOURCE_BASEDIR_LBCS:-"/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b"}" ;; "HERA") EXTRN_MDL_SYSBASEDIR_LBCS="${EXTRN_MDL_SOURCE_BASEDIR_LBCS:-/mnt/lfs4/BMC/public/data/grids/gens/pgrb2b}" diff --git a/ush/templates/FV3LAM_wflow.xml b/ush/templates/FV3LAM_wflow.xml index 28b177345..dc18f2a0b 100644 --- a/ush/templates/FV3LAM_wflow.xml +++ b/ush/templates/FV3LAM_wflow.xml @@ -35,6 +35,7 @@ Workflow task names. + @@ -743,6 +744,45 @@ MODULES_RUN_TASK_FP script. + +{%- if extrn_mdl_name_lbcs in ["GEFS"] and bc_update_interval==1 %} + + + + &WALL_LIMIT_PRE; + &RSRV_DEFAULT; + &LOAD_MODULES_RUN_TASK_FP; "&GET_EXTRN_LBCS_TN;" "&JOBSDIR;/JREGIONAL_GET_GEFS_LBCS_FILES" + &RESOURCES_GET_EXTRN_LBCS; + &WALLTIME_GET_EXTRN_LBCS; + &NODESIZE_ALL; + &TAG;_&GET_GEFS_LBCS_TN;{{ uscore_ensmem_name }} + &LOGDIR;/&GET_GEFS_LBCS_TN;_&TAG;{{ uscore_ensmem_name }}_@Y@m@d@H.log + + 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 + EXTRN_MDL_NAME{{ extrn_mdl_name_lbcs }} + ICS_OR_LBCSLBCS + BOUNDARY_LEN{{ boundary_len_hrs }} + SLASH_ENSMEM_SUBDIR{{ slash_ensmem_subdir }} + GEFS_INPUT_SUBDIR#subdirGE# + GDASENKF_INPUT_SUBDIR#subdirGDAS# + GDAS_MEM_NAME#memNameGDAS# + + + + {%- for h in range(extrn_mdl_lbcs_offset_hrs, boundary_len_hrs+extrn_mdl_lbcs_offset_hrs+1, 3) %} + {{ extrn_mdl_sysbasedir_lbcs }}/#subdirGE#/@y@j@H000{{ "%03d" % h }} + {%- endfor %} + + + + +{%- else %}