From f6a3be3a428e3344b210a01f9b4ed35a86c7f97d Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 6 Oct 2020 15:23:14 -0500 Subject: [PATCH 01/39] Add ORION as a new platform. Common sets of changes: ---------------------- (A) Add ORION stanza to case statement that sets the run command and the resource limits. (B) Edit comments. File-by-file changes: -------------------- jobs/JREGIONAL_MAKE_ICS: (A) jobs/JREGIONAL_MAKE_LBCS: (A) scripts/exregional_make_grid.sh: (A), (B) scripts/exregional_make_orog.sh: (A), (B) scripts/exregional_make_sfc_climo.sh: (A), (B) scripts/exregional_run_fcst.sh: (A) scripts/exregional_run_post.sh: (A) ush/set_extrn_mdl_params.sh: (B) * Add ORION stanzas to some of the case statements that set EXTRN_MDL_SYSBASEDIR_ICS and EXTRN_MDL_SYSBASEDIR_LBCS for certain external models. ush/setup.sh: * Add ORION stanza to case statement that sets the number of cores per node, the scheduler, and various queue-related workflow parameters. * Add ORION stanza to case statement that sets the workflow variables FIXgsm and SFC_CLIMO_INPUT_DIR. ush/valid_param_vals.sh: * Add ORION to list of valid machine names. --- jobs/JREGIONAL_MAKE_ICS | 6 +++ jobs/JREGIONAL_MAKE_LBCS | 5 +++ scripts/exregional_make_grid.sh | 23 +++------- scripts/exregional_make_orog.sh | 15 +++---- scripts/exregional_make_sfc_climo.sh | 6 ++- scripts/exregional_run_fcst.sh | 8 +++- scripts/exregional_run_post.sh | 10 +++-- ush/set_extrn_mdl_params.sh | 64 ++++++++++++++++------------ ush/setup.sh | 24 +++++++---- ush/valid_param_vals.sh | 2 +- 10 files changed, 97 insertions(+), 66 deletions(-) diff --git a/jobs/JREGIONAL_MAKE_ICS b/jobs/JREGIONAL_MAKE_ICS index b8e872837..6e54268ae 100755 --- a/jobs/JREGIONAL_MAKE_ICS +++ b/jobs/JREGIONAL_MAKE_ICS @@ -92,10 +92,16 @@ case "$MACHINE" in nprocs=$(( NNODES_MAKE_ICS*PPN_MAKE_ICS )) APRUN="mpirun -np $nprocs" ;; + "STAMPEDE") APRUN="ibrun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + esac # #----------------------------------------------------------------------- diff --git a/jobs/JREGIONAL_MAKE_LBCS b/jobs/JREGIONAL_MAKE_LBCS index 7b53dab31..5f2cc0be6 100755 --- a/jobs/JREGIONAL_MAKE_LBCS +++ b/jobs/JREGIONAL_MAKE_LBCS @@ -97,6 +97,11 @@ case "$MACHINE" in APRUN="ibrun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index 48cfb49a2..9426c856a 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -90,19 +90,14 @@ export OMP_STACKSIZE=2048m # #----------------------------------------------------------------------- # -# Load modules and set various computational parameters and directories. -# -# Note: -# These module loads should all be moved to modulefiles. This has been -# done for Hera but must still be done for other machines. +# Set the machine-dependent run command. Also, set resource limits as +# necessary. # #----------------------------------------------------------------------- # case $MACHINE in - "WCOSS_C" | "WCOSS") -# { save_shell_opts; set +x; } > /dev/null 2>&1 . $MODULESHOME/init/sh @@ -119,27 +114,20 @@ case $MACHINE in ulimit -a ;; - "HERA") -# APRUN="time" -# # ulimit -s unlimited # ulimit -a ;; -# "JET") -# APRUN="time" ulimit -a ;; "ODIN") -# export APRUN="srun -n 1" - ulimit -s unlimited ulimit -a ;; @@ -149,12 +137,15 @@ case $MACHINE in ;; "STAMPEDE") -# export APRUN="time" - ulimit -s unlimited ulimit -a ;; + +"ORION") + APRUN="time" + ;; + esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index a8a39dcc0..e5d429a65 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -98,9 +98,7 @@ export OMP_STACKSIZE=2048m # case $MACHINE in - "WCOSS_C" | "WCOSS") -# { save_shell_opts; set +x; } > /dev/null 2>&1 . $MODULESHOME/init/sh @@ -117,14 +115,12 @@ case $MACHINE in ulimit -a ;; - "HERA") ulimit -s unlimited ulimit -a APRUN="time" ;; - "JET") ulimit -s unlimited ulimit -a @@ -133,14 +129,11 @@ case $MACHINE in "ODIN") -# export APRUN="srun -n 1" - ulimit -s unlimited ulimit -a ;; - "CHEYENNE") APRUN="time" ;; @@ -150,6 +143,12 @@ case $MACHINE in export topo_dir="/work/00315/tg455890/stampede2/regional_fv3/fix_orog" ;; +"ORION") + ulimit -s unlimited + ulimit -a + APRUN="time" + ;; + esac # #----------------------------------------------------------------------- @@ -322,7 +321,7 @@ ${tmp_dir}" \ ;; -"CHEYENNE" | "HERA" | "JET" | "ODIN" | "STAMPEDE") +"CHEYENNE" | "HERA" | "JET" | "ODIN" | "STAMPEDE" | "ORION") $APRUN "${exec_fp}" < "${input_redirect_fn}" || \ print_err_msg_exit "\ Call to executable (exec_fp) that generates the raw orography file returned diff --git a/scripts/exregional_make_sfc_climo.sh b/scripts/exregional_make_sfc_climo.sh index 938ede5e9..b7e6d118a 100755 --- a/scripts/exregional_make_sfc_climo.sh +++ b/scripts/exregional_make_sfc_climo.sh @@ -122,7 +122,7 @@ EOF # #----------------------------------------------------------------------- # -# Set the run machine-dependent run command. +# Set the machine-dependent run command. # #----------------------------------------------------------------------- # @@ -161,6 +161,10 @@ case $MACHINE in APRUN="ibrun -np ${nprocs}" ;; +"ORION") + APRUN="srun" + ;; + *) print_err_msg_exit "\ Run command has not been specified for this machine: diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 10b7fed07..3f664013a 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -128,7 +128,13 @@ case $MACHINE in APRUN="ibrun -np ${PE_MEMBER01}" #LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" ;; - +# +"ORION") + ulimit -s unlimited + ulimit -a + APRUN="srun" +# LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" +# esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_run_post.sh b/scripts/exregional_run_post.sh index 60758381e..d876ada53 100755 --- a/scripts/exregional_run_post.sh +++ b/scripts/exregional_run_post.sh @@ -79,9 +79,6 @@ print_input_args valid_args # #----------------------------------------------------------------------- # -print_info_msg "$VERBOSE" " -Starting post-processing for fhr = $fhr hr..." - case $MACHINE in "WCOSS_CRAY") @@ -133,6 +130,10 @@ case $MACHINE in APRUN="ibrun -n $nprocs" ;; +"ORION") + APRUN="srun" + ;; + esac # #----------------------------------------------------------------------- @@ -195,6 +196,9 @@ EOF # #----------------------------------------------------------------------- # +print_info_msg "$VERBOSE" " +Starting post-processing for fhr = $fhr hr..." + ${APRUN} ./ncep_post < itag || print_err_msg_exit "\ Call to executable to run post for forecast hour $fhr returned with non- zero exit code." diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index c434f8d60..50ffff61e 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -1,9 +1,9 @@ # #----------------------------------------------------------------------- # -# This file defines and then calls a function that sets parameters rela- -# ting to the external model used for initial conditions (ICs) and the -# one used for lateral boundary conditions (LBCs). +# This file defines and then calls a function that sets parameters +# associated with the external model used for initial conditions (ICs) +# and the one used for lateral boundary conditions (LBCs). # #----------------------------------------------------------------------- # @@ -32,15 +32,14 @@ local func_name="${FUNCNAME[0]}" #----------------------------------------------------------------------- # # Set the system directory (i.e. location on disk, not on HPSS) in which -# the files generated by the external model specified by EXTRN_MDL_- -# NAME_ICS that are necessary for generating initial condition (IC) -# and surface files for the FV3SAR are stored (usually for a limited -# time, e.g. for the GFS external model, 2 weeks on WCOSS and 2 days on -# theia). If for a given cycle these files are available in this system -# directory, they will be copied over to a subdirectory within the cy- -# cle's run directory. If these files are not available in the system -# directory, then we search for them elsewhere, e.g. in the mass store -# (HPSS). +# the files generated by the external model specified by EXTRN_MDL_NAME_ICS +# that are necessary for generating initial condition (IC) and surface +# files for the FV3SAR are stored (usually for a limited time, e.g. for +# the GFS external model, 2 weeks on WCOSS and 2 days on hera). If for +# a given cycle these files are available in this system directory, they +# will be copied over to a subdirectory under the cycle directory. If +# these files are not available in the system directory, then we search +# for them elsewhere, e.g. in the mass store (HPSS). # #----------------------------------------------------------------------- # @@ -76,6 +75,9 @@ else "STAMPEDE") EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; + "ORION") + EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + ;; *) print_err_msg_exit "\ The system directory in which to look for the files generated by the ex- @@ -108,6 +110,9 @@ this machine and external model combination: "CHEYENNE") EXTRN_MDL_FILES_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; + "ORION") + EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + ;; *) print_err_msg_exit "\ The system directory in which to look for the files generated by the ex- @@ -166,9 +171,9 @@ fi # #----------------------------------------------------------------------- # -# Set EXTRN_MDL_LBCS_OFFSET_HRS, which is the number of hours to -# shift the starting time of the external model that provides lateral -# boundary conditions. +# Set EXTRN_MDL_LBCS_OFFSET_HRS, which is the number of hours to shift +# the starting time of the external model that provides lateral boundary +# conditions. # #----------------------------------------------------------------------- # @@ -190,15 +195,14 @@ esac #----------------------------------------------------------------------- # # Set the system directory (i.e. location on disk, not on HPSS) in which -# the files generated by the external model specified by EXTRN_MDL_- -# NAME_LBCS that are necessary for generating lateral boundary condition -# (LBC) files for the FV3SAR are stored (usually for a limited time, -# e.g. for the GFS external model, 2 weeks on WCOSS and 2 days on the- -# ia). If for a given cycle these files are available in this system -# directory, they will be copied over to a subdirectory within the cy- -# cle's run directory. If these files are not available in the system -# directory, then we search for them elsewhere, e.g. in the mass store -# (HPSS). +# the files generated by the external model specified by EXTRN_MDL_NAME_LBCS +# that are necessary for generating lateral boundary condition (LBC) files +# for the FV3SAR are stored (usually for a limited time, e.g. for the GFS +# external model, 2 weeks on WCOSS and 2 days on hera). If for a given +# cycle these files are available in this system directory, they will be +# copied over to a subdirectory under the cycle directory. If these files +# are not available in the system directory, then we search for them +# elsewhere, e.g. in the mass store (HPSS). # #----------------------------------------------------------------------- # @@ -234,6 +238,9 @@ else "STAMPEDE") EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; + "ORION") + EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + ;; *) print_err_msg_exit "\ The system directory in which to look for the files generated by the ex- @@ -267,6 +274,9 @@ this machine and external model combination: "CHEYENNE") EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; + "ORION") + EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + ;; *) print_err_msg_exit "\ The system directory in which to look for the files generated by the ex- @@ -300,7 +310,6 @@ this machine and external model combination: ;; - "HRRRX") case $MACHINE in @@ -321,9 +330,8 @@ this machine and external model combination: ;; esac ;; - - - + + esac fi diff --git a/ush/setup.sh b/ush/setup.sh index 507cfbd02..1719031c2 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -318,7 +318,6 @@ check_var_valid_value "MACHINE" "valid_vals_MACHINE" case $MACHINE in # "WCOSS_CRAY") -# NCORES_PER_NODE="24" SCHED="lsfcray" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} @@ -328,7 +327,6 @@ case $MACHINE in ;; # "WCOSS_DELL_P3") -# NCORES_PER_NODE=24 SCHED="lsf" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} @@ -338,8 +336,7 @@ case $MACHINE in ;; # "HERA") -# - NCORES_PER_NODE=24 + NCORES_PER_NODE=24 # Should this be 40? Need to check heradocs. SCHED="${SCHED:-slurm}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} QUEUE_HPSS=${QUEUE_HPSS:-"service"} @@ -347,7 +344,6 @@ case $MACHINE in ;; # "JET") -# NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} @@ -356,7 +352,6 @@ case $MACHINE in ;; # "ODIN") -# NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} @@ -365,7 +360,6 @@ case $MACHINE in ;; # "CHEYENNE") -# NCORES_PER_NODE=36 SCHED="${SCHED:-pbspro}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"regular"} @@ -375,13 +369,21 @@ case $MACHINE in ;; # "STAMPEDE") -# NCORES_PER_NODE=68 SCHED="slurm" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} QUEUE_HPSS=${QUEUE_HPSS:-"development"} QUEUE_FCST=${QUEUE_FCST:-"normal"} ;; +# +"ORION") + NCORES_PER_NODE=40 + SCHED="${SCHED:-slurm}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_FCST=${QUEUE_FCST:-""} + ;; +# esac # #----------------------------------------------------------------------- @@ -741,6 +743,7 @@ case $MACHINE in FIXgsm="/scratch/ywang/fix/theia_fix/fix_am" SFC_CLIMO_INPUT_DIR="/scratch/ywang/fix/climo_fields_netcdf" ;; + "CHEYENNE") FIXgsm="/glade/p/ral/jntp/UFS_CAM/fix/fix_am" SFC_CLIMO_INPUT_DIR="/glade/p/ral/jntp/UFS_CAM/fix/climo_fields_netcdf" @@ -751,6 +754,11 @@ case $MACHINE in SFC_CLIMO_INPUT_DIR="/work/00315/tg455890/stampede2/regional_fv3/climo_fields_netcdf" ;; +"ORION") + FIXgsm="/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am" + SFC_CLIMO_INPUT_DIR="/dont/know/what/this/should/be" + ;; + *) print_err_msg_exit "\ Directories have not been specified for this machine: diff --git a/ush/valid_param_vals.sh b/ush/valid_param_vals.sh index a4378f03d..0d89c5ed6 100644 --- a/ush/valid_param_vals.sh +++ b/ush/valid_param_vals.sh @@ -1,6 +1,6 @@ valid_vals_RUN_ENVIR=("nco" "community") valid_vals_VERBOSE=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") -valid_vals_MACHINE=("WCOSS_CRAY" "WCOSS_DELL_P3" "THEIA" "HERA" "JET" "ODIN" "CHEYENNE" "STAMPEDE") +valid_vals_MACHINE=("WCOSS_CRAY" "WCOSS_DELL_P3" "THEIA" "HERA" "JET" "ODIN" "CHEYENNE" "STAMPEDE" "ORION") valid_vals_SCHED=("slurm" "pbspro" "lsf" "lsfcray" "none") valid_vals_PREDEF_GRID_NAME=( \ "EMC_CONUS_3km" \ From 9ccfe46688318b611b5e475aa91e405c9943fdf5 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 6 Oct 2020 15:51:03 -0500 Subject: [PATCH 02/39] Merge set_extrn_mdl_params.sh manually (even outside of mergetool) to make the merge of develop into feature/orion_port easier. --- ush/set_extrn_mdl_params.sh | 224 +++++++++++++++--------------------- 1 file changed, 91 insertions(+), 133 deletions(-) diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index 50ffff61e..2a4e88ffd 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -45,130 +45,114 @@ local func_name="${FUNCNAME[0]}" # if [ "${RUN_ENVIR}" = "nco" ]; then - EXTRN_MDL_FILES_SYSBASEDIR_ICS="$COMINgfs" + EXTRN_MDL_SYSBASEDIR_ICS="$COMINgfs" else case ${EXTRN_MDL_NAME_ICS} in - - + "GSMGFS") case $MACHINE in "WCOSS_CRAY") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; "WCOSS_DELL_P3") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; "ODIN") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch/ywang/EPIC/GDAS/2019053000_mem001" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch/ywang/EPIC/GDAS/2019053000_mem001" ;; "CHEYENNE") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" + EXTRN_MDL_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "STAMPEDE") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; "ORION") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" - ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_ICS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\"" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; esac ;; - - + "FV3GFS") case $MACHINE in "WCOSS_CRAY") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/gpfs/dell1/nco/ops/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_ICS="/gpfs/dell1/nco/ops/com/gfs/prod" ;; "WCOSS_DELL_P3") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/gpfs/dell1/nco/ops/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_ICS="/gpfs/dell1/nco/ops/com/gfs/prod" ;; "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/public/data/grids/gfs/nemsio" + EXTRN_MDL_SYSBASEDIR_ICS="/public/data/grids/gfs/nemsio" ;; "ODIN") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch/ywang/test_runs/FV3_regional/gfs" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch/ywang/test_runs/FV3_regional/gfs" ;; "CHEYENNE") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" + EXTRN_MDL_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "ORION") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="" - ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_ICS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\"" + EXTRN_MDL_SYSBASEDIR_ICS="" ;; esac ;; - - + "RAPX") case $MACHINE in "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/misc/whome/rtrr/rap" + EXTRN_MDL_SYSBASEDIR_ICS="/misc/whome/rtrr/rap" ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_ICS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\"" +# This goes with the comment below for the if-statement (-z EXTRN_MDL_SYSBASEDIR_ICS). +# Should not need this case. + "CHEYENNE") + EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" ;; esac ;; - "HRRRX") case $MACHINE in "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" + EXTRN_MDL_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_ICS="/misc/whome/rtrr/hrrr" + EXTRN_MDL_SYSBASEDIR_ICS="/misc/whome/rtrr/hrrr" ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_ICS has not been specified -for this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\"" + "CHEYENNE") + EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" ;; esac ;; - esac fi # +# If EXTRN_MDL_SYSBASEDIR_ICS has not been set (not even to a null string), +# print out an error message and exit. +# +if [ -z "${EXTRN_MDL_SYSBASEDIR_ICS+x}" ]; then + print_err_msg_exit "\ +The variable EXTRN_MDL_SYSBASEDIR_ICS specifying the system directory +in which to look for the files generated by the external model for ICs +has not been set for the current combination of machine (MACHINE) and +external model (EXTRN_MDL_NAME_ICS): + MACHINE = \"$MACHINE\" + EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\"" +fi +# #----------------------------------------------------------------------- # # Set EXTRN_MDL_LBCS_OFFSET_HRS, which is the number of hours to shift @@ -178,18 +162,18 @@ fi #----------------------------------------------------------------------- # case ${EXTRN_MDL_NAME_LBCS} in -"GSMGFS") - EXTRN_MDL_LBCS_OFFSET_HRS="0" - ;; -"FV3GFS") - EXTRN_MDL_LBCS_OFFSET_HRS="0" - ;; -"RAPX") - EXTRN_MDL_LBCS_OFFSET_HRS="3" - ;; -"HRRRX") - EXTRN_MDL_LBCS_OFFSET_HRS="0" - ;; + "GSMGFS") + EXTRN_MDL_LBCS_OFFSET_HRS="0" + ;; + "FV3GFS") + EXTRN_MDL_LBCS_OFFSET_HRS="0" + ;; + "RAPX") + EXTRN_MDL_LBCS_OFFSET_HRS="3" + ;; + "HRRRX") + EXTRN_MDL_LBCS_OFFSET_HRS="0" + ;; esac # #----------------------------------------------------------------------- @@ -208,134 +192,108 @@ esac # if [ "${RUN_ENVIR}" = "nco" ]; then - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="$COMINgfs" + EXTRN_MDL_SYSBASEDIR_LBCS="$COMINgfs" else case ${EXTRN_MDL_NAME_LBCS} in - - + "GSMGFS") case $MACHINE in "WCOSS_CRAY") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; "WCOSS_DELL_P3") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; "ODIN") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch/ywang/EPIC/GDAS/2019053000_mem001" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/ywang/EPIC/GDAS/2019053000_mem001" ;; "CHEYENNE") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" + EXTRN_MDL_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "STAMPEDE") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; "ORION") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" - ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_LBCS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\"" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; esac ;; - "FV3GFS") - case $MACHINE in "WCOSS_CRAY") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/gpfs/dell1/nco/ops/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_LBCS="/gpfs/dell1/nco/ops/com/gfs/prod" ;; "WCOSS_DELL_P3") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/gpfs/dell1/nco/ops/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_LBCS="/gpfs/dell1/nco/ops/com/gfs/prod" ;; "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/public/data/grids/gfs/nemsio" + EXTRN_MDL_SYSBASEDIR_LBCS="/public/data/grids/gfs/nemsio" ;; "ODIN") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch/ywang/test_runs/FV3_regional/gfs" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/ywang/test_runs/FV3_regional/gfs" ;; "CHEYENNE") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" + EXTRN_MDL_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "ORION") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="" - ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_LBCS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\"" + EXTRN_MDL_SYSBASEDIR_LBCS="" ;; esac ;; - "RAPX") - case $MACHINE in "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/misc/whome/rtrr/rap" + EXTRN_MDL_SYSBASEDIR_LBCS="/misc/whome/rtrr/rap" ;; - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_LBCS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\"" + "CHEYENNE") + EXTRN_MDL_SYSBASEDIR_LBCS="dummy_value" ;; esac ;; - - + "HRRRX") - case $MACHINE in "HERA") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" ;; "JET") - EXTRN_MDL_FILES_SYSBASEDIR_LBCS="/misc/whome/rtrr/hrrr" - ;; - - *) - print_err_msg_exit "\ -The system directory in which to look for the files generated by the ex- -ternal model specified by EXTRN_MDL_NAME_LBCS has not been specified for -this machine and external model combination: - MACHINE = \"$MACHINE\" - EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\"" + EXTRN_MDL_SYSBASEDIR_LBCS="/misc/whome/rtrr/hrrr" ;; esac ;; - esac fi - +# +# If EXTRN_MDL_SYSBASEDIR_LBCS has not been set (not even to a null string), +# print out an error message and exit. +# +if [ -z "${EXTRN_MDL_SYSBASEDIR_LBCS+x}" ]; then + print_err_msg_exit "\ +The variable EXTRN_MDL_SYSBASEDIR_LBCS specifying the system directory +in which to look for the files generated by the external model for LBCs +has not been set for the current combination of machine (MACHINE) and +external model (EXTRN_MDL_NAME_LBCS): + MACHINE = \"$MACHINE\" + EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\"" +fi } # #----------------------------------------------------------------------- From a616c1d7f7e45fef7555dbc0ef032edcfab60a57 Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Thu, 8 Oct 2020 14:36:26 -0600 Subject: [PATCH 03/39] Modify/add predefined grids (#305) ## DESCRIPTION OF CHANGES: This PR renames and modifies several existing grids and creates some new ones. Details below. Note that the 3 grids required for the ufs-srweather-app release are created in this PR: RRFS_CONUS_25km, RRFS_CONUS_13km, RRFS_CONUS_3km. These pass their tests (2 tests per grid) except for RRFS_CONUS_13km, which fails one of its two tests in the make_ics task. This may need further attention, possibly after the PR is merged. ### CONUS and SUBCONUS grids of ESGgrid type: * There are currently four such grids: GSD_HRRR25km, GSD_HRRR13km, GSD_HRRR3km, and GSD_SUBCONUS3km. * These have been renamed to RRFS_CONUS_25km, RRFS_CONUS_13km, RRFS_CONUS_3km, and RRFS_SUBCONUS_3km, respectively. * The grid parameters (both native and write-component) have been adjusted as follows: * The outer boundaries of the three CONUS grids are reset such that they are as close to the HRRRX grid boundary as possible but such that each grid, including its 4-cell-wide halo, is within the HRRRX domain. This is to ensure that the HRRRX can be used to generate ICs for these CONUS grids. * The write-component grid corresponding to each of these four native grids is reset such that it is as large as possible but still lies completely within the grid (without any halo points). * There is no longer a GFDLgrid type grid corresponding to these grids; they are all strictly of type ESGgrid. Setting GRID_GEN_METHOD to "GFDLgrid" with any of these grids will result in an error during the workflow generation step. * The following WE2E tests have been added to test these grids: * grid_RRFS_CONUS_25km_FV3GFS_FV3GFS - run on the RRFS_CONUS_13km grid using FV3GFS for ICs/LBCs and the GFS_v16beta physics suite. * grid_RRFS_CONUS_13km_FV3GFS_FV3GFS - same as above but for the RRFS_CONUS_13km grid. * grid_RRFS_CONUS_3km_FV3GFS_FV3GFS - same as above but for the RRFS_CONUS_3km grid. * grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS - same as above but for the RRFS_SUBCONUS_3km grid. * grid_RRFS_CONUS_25km_HRRRX_RAPX - run on the RRFS_CONUS_25km grid using HRRRX for ICs, RAPX for LBCs, and the GSD_SAR physics suite. * grid_RRFS_CONUS_13km_HRRRX_RAPX - same as above but for the RRFS_CONUS_13km grid. * grid_RRFS_CONUS_3km_HRRRX_RAPX - same as above but for the RRFS_CONUS_3km grid. * grid_RRFS_SUBCONUS_3km_HRRRX_RAPX - same as above but for the RRFS_SUBCONUS_3km grid. ### CONUS grids of GFDLgrid type: * There are currently two GFDLgrid type grids that are actively tested: EMC_CONUS_coarse and EMC_CONUS_3km. * Two new ones similar to these have been introduced: CONUS_25km_GFDLgrid and CONUS_3km_GFDLgrid. * CONUS_25km_GFDLgrid is similar to EMC_CONUS_coarse except that it is adjusted to be centered about the "center" point (with respect to the "parent" tile 6) and to have an average cell size of about 25.1km (whereas EMC_CONUS_coarse was not symmetric and had an average cell size of about 23.? km). In centering the grid, the number of grid points in each direction was chosen to allow more choices in setting LAYOUT_X, LAYOUT_Y, and BLOCKSIZE. * CONUS_3km_GFDLgrid is similar to EMC_CONUS_3km except that it is adjusted to be centered about the "center" point (with respect to the "parent" tile 6). In centering the grid, the number of grid points in each direction was chosen to allow more choices in setting LAYOUT_X, LAYOUT_Y, and BLOCKSIZE. * The write-component grids corresponding to these two native grids have been set such that they are as large as possible but still lie completely within the native grid (without any halo points). * These grids are present to allow testing of the GFDLgrid capability in the workflow as new PRs are merged. * The current EMC_CONUS_coarse and EMC_CONUS_3km grids are retained for now but will be removed soon in another PR. * Setting GRID_GEN_METHOD to "ESGgrid" is not allowed with either of these grids; if set, it will result in an error during the workflow generation step. * The following WE2E tests have been added to test these grids: * grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS - run on the CONUS_25km_GFDLgrid grid using FV3GFS for ICs/LBCs and the GFS_v16beta physics suite. * grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS - same as above but on the CONUS_3km_GFDLgrid grid. ### Alaska grids: * There are currently three Alaska grids of ESGgrid type: EMC_AK (a 3-km grid), GSD_RRFSAK_3km, and GSD_HRRR_AK_50km. Only GSD_HRRR_AK_50km is actively tested. * The RRFSAK_3km grid is renamed to RRFS_AK_3km and its write-component grid adjusted so that it covers as much of the native as possible without going outside. * The new Alaska grids RRFS_AK_13km has been added. This is meant to be a replacement for the GSD_HRRR_AK_50km, which was deemed too coarse for testing (and will be removed in a future PR). * The Alaska grids RRFS_AK_3km and RRFS_AK_13km fail most of the tests (see below) and need further adjustment. They are included in this PR in order to allow users to try them and suggest modifications. * The following WE2E tests have been added to test these grids: * grid_RRFS_AK_13km_FV3GFS_FV3GFS - run on the RRFS_AK_13km grid using FV3GFS for ICs/LBCs and the GFS_v16beta physics suite. * grid_RRFS_AK_3km_FV3GFS_FV3GFS - same as above but for the RRFS_AK_3km grid. * grid_RRFS_AK_13km_RAPX_RAPX - run on the RRFS_AK_13km grid using RAPX for ICs/LBCs and the GSD_SAR physics suite. * grid_RRFS_AK_3km_RAPX_RAPX - same as above but for the RRFS_AK_3km grid. ## TESTS CONDUCTED: Ran the 14 new WE2E tests added in this PR. Test results are as follows: ``` * grid_RRFS_CONUS_13km_FV3GFS_FV3GFS SUCCESS * grid_RRFS_CONUS_13km_HRRRX_RAPX FAILURE - In make_ics task * Log file: PET00 ESMCI_Mesh_Regrid_Glue.C:313 c_esmc_regrid_create() Arguments are incompatible - - There exist destination points (e.g. id=1) which can't be mapped to any source cell * Boundary of native grid may be too close to that of HRRRX grid. * grid_RRFS_CONUS_25km_FV3GFS_FV3GFS SUCCESS * grid_RRFS_CONUS_25km_HRRRX_RAPX SUCCESS * grid_RRFS_CONUS_3km_FV3GFS_FV3GFS SUCCESS * grid_RRFS_CONUS_3km_HRRRX_RAPX SUCCESS * grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS FAILURE - In run_fcst task * Log file: FATAL from PE 719: compute_qs: saturation vapor pressure table overflow, nbad= 1 * Fails only after hour 5, so probably not a grid issue. * grid_RRFS_SUBCONUS_3km_HRRRX_RAPX SUCCESS * grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS SUCCESS * grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS SUCCESS * grid_RRFS_AK_13km_FV3GFS_FV3GFS SUCCESS * grid_RRFS_AK_13km_RAPX_RAPX FAILURE - In run_fcst task * Log file: AVOST IN VILKA Table index= -2147483648 I,J= 1 1 LU_index = 15 Psfc[hPa] = 914.224907314199 Tsfc = 278.090454101562 * grid_RRFS_AK_3km_FV3GFS_FV3GFS FAILURE - In run_fcst task * Log file: forrtl: severe (174): SIGSEGV, segmentation fault occurred *** longjmp causes uninitialized stack frame ***: /scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/ufs-srweather-app/exec/fv3_g fs.x terminated * Fails only after hour 2, so probably not a grid issue. * grid_RRFS_AK_3km_RAPX_RAPX FAILURE - In run_fcst task * Log file: AVOST IN VILKA Table index= -2147483648 I,J= 1 1 LU_index = 15 Psfc[hPa] = 847.226062635191 Tsfc = 294.777954101562 ``` Note that: * The RRFS_CONUS_XXkm grids pass 5 of 6 tests. The failure of test grid_RRFS_CONUS_13km_HRRRX_RAPX in the make_ics task is due to there being one or more "destination" cells on the RRFS_CONUS_13km grid for which chgres_cube could not find one or more "source" cells on the HRRRX external grid. This may be fixed by making the RRFS_CONUS_13km grid smaller, but it would be better to fix chgres_cube so that this case works (since the RRFS_CONUS_13km grid, including its 4-cell-wide halo, is already completely within the HRRRX domain). * The RRFS_SUBCONUS_XXkm grids (2 tests) pass for the HRRRX/RAPX ICs/LBCs case but fail in the run_fcst task for the FV3GFS ICs/LBCs case. Since the failure occurs after hour 5, it is probably not grid-related. * The CONUS_XXkm_GFDLgrid grids pass their tests (2 tests). * The RRFS_AK_XXkm grids pass only 1 of 4 tests. These failures need to be investigated further. --- .../baseline_configs/config.DOT_OR_USCORE.sh | 2 +- .../config.community_ensemble_008mems.sh | 2 +- .../config.community_ensemble_2mems.sh | 2 +- ...get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh | 2 +- ...get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh | 2 +- ...ig.get_extrn_files_from_hpss_HRRRX_RAPX.sh | 2 +- ...fig.get_extrn_files_from_hpss_RAPX_RAPX.sh | 2 +- ....grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh | 19 + ...g.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh | 19 + .../config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh | 20 + .../config.grid_RRFS_AK_13km_RAPX_RAPX.sh | 20 + .../config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh | 20 + .../config.grid_RRFS_AK_3km_RAPX_RAPX.sh | 20 + ...nfig.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh | 19 + .../config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh | 19 + ...nfig.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh | 19 + .../config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh | 19 + ...onfig.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh | 19 + .../config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh | 19 + ...ig.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh | 19 + ...onfig.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh | 19 + ... config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh} | 2 +- ...onfig.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh} | 2 +- ...> config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh} | 2 +- ...onfig.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh} | 2 +- .../config.pregen_grid_orog_sfc_climo.sh | 2 +- tests/baseline_configs/config.regional_001.sh | 2 +- tests/baseline_configs/config.regional_002.sh | 2 +- .../config.suite_FV3_CPT_v0.sh | 2 +- .../config.suite_FV3_GFS_v15p2.sh | 2 +- .../config.suite_FV3_GFS_v16beta.sh | 2 +- .../config.suite_FV3_GSD_SAR.sh | 2 +- .../config.suite_FV3_GSD_v0.sh | 2 +- .../config.suite_FV3_RRFS_v1beta.sh | 2 +- .../config.user_download_extrn_files.sh | 2 +- tests/baselines_list.txt | 9 +- ush/config.community.sh | 2 +- ush/config_defaults.sh | 10 - ush/set_gridparams_ESGgrid.sh | 2 - ush/set_predef_grid_params.sh | 353 +++++++++++++----- ush/setup.sh | 6 +- ush/templates/wrtcmp_lambert_conformal | 8 +- ush/valid_param_vals.sh | 21 +- 43 files changed, 572 insertions(+), 151 deletions(-) create mode 100644 tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh rename tests/baseline_configs/{config.nco_GSD_HRRR3km_HRRRX_RAPX.sh => config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh} (91%) rename tests/baseline_configs/{config.nco_GSD_HRRR3km_FV3GFS_FV3GFS.sh => config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh} (92%) rename tests/baseline_configs/{config.nco_GSD_HRRR25km_HRRRX_RAPX.sh => config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh} (91%) rename tests/baseline_configs/{config.nco_GSD_SUBCONUS3km_HRRRX_RAPX.sh => config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh} (90%) diff --git a/tests/baseline_configs/config.DOT_OR_USCORE.sh b/tests/baseline_configs/config.DOT_OR_USCORE.sh index b3ee37a2a..0b7c202c6 100644 --- a/tests/baseline_configs/config.DOT_OR_USCORE.sh +++ b/tests/baseline_configs/config.DOT_OR_USCORE.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.community_ensemble_008mems.sh b/tests/baseline_configs/config.community_ensemble_008mems.sh index b8327de74..a0a75a139 100644 --- a/tests/baseline_configs/config.community_ensemble_008mems.sh +++ b/tests/baseline_configs/config.community_ensemble_008mems.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.community_ensemble_2mems.sh b/tests/baseline_configs/config.community_ensemble_2mems.sh index 8d0aa37a4..00450be06 100644 --- a/tests/baseline_configs/config.community_ensemble_2mems.sh +++ b/tests/baseline_configs/config.community_ensemble_2mems.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh index c6d6c01dd..c0d56966d 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh index 8b37fe088..1fbf5962c 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh index 3ef9eeadc..5e786809a 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh index 21c147c62..393c8bc0b 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..0d0b0e736 --- /dev/null +++ b/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="CONUS_25km_GFDLgrid" +GRID_GEN_METHOD="GFDLgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..c41026343 --- /dev/null +++ b/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="CONUS_3km_GFDLgrid" +GRID_GEN_METHOD="GFDLgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..57da4b332 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh @@ -0,0 +1,20 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_AK_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" + +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="6" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh new file mode 100644 index 000000000..630271e55 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh @@ -0,0 +1,20 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_AK_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" + +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="6" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="RAPX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..02e9f97ee --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh @@ -0,0 +1,20 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_AK_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" + +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="6" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh new file mode 100644 index 000000000..c3cb06e8f --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh @@ -0,0 +1,20 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_AK_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" + +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="6" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="RAPX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..b30f7f457 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh new file mode 100644 index 000000000..e5e302975 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..68511e5cb --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_25km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh new file mode 100644 index 000000000..4047e11fd --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_25km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..15d70793c --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh new file mode 100644 index 000000000..751172472 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh new file mode 100644 index 000000000..68c1a1581 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_SUBCONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GFS_v16beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh new file mode 100644 index 000000000..85ed27905 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh @@ -0,0 +1,19 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_SUBCONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +USE_CCPP="TRUE" +CCPP_PHYS_SUITE="FV3_GSD_SAR" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.nco_GSD_HRRR3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh similarity index 91% rename from tests/baseline_configs/config.nco_GSD_HRRR3km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh index adb727e85..4e28b83af 100644 --- a/tests/baseline_configs/config.nco_GSD_HRRR3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh @@ -1,7 +1,7 @@ RUN_ENVIR="nco" PREEXISTING_DIR_METHOD="rename" -EMC_GRID_NAME="GSD_HRRR3km" +EMC_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.nco_GSD_HRRR3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh similarity index 92% rename from tests/baseline_configs/config.nco_GSD_HRRR3km_FV3GFS_FV3GFS.sh rename to tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh index 1cd78cdce..0bd17e582 100644 --- a/tests/baseline_configs/config.nco_GSD_HRRR3km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh @@ -1,7 +1,7 @@ RUN_ENVIR="nco" PREEXISTING_DIR_METHOD="rename" -EMC_GRID_NAME="GSD_HRRR3km" +EMC_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.nco_GSD_HRRR25km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh similarity index 91% rename from tests/baseline_configs/config.nco_GSD_HRRR25km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh index 56e4755d0..523194b41 100644 --- a/tests/baseline_configs/config.nco_GSD_HRRR25km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh @@ -1,7 +1,7 @@ RUN_ENVIR="nco" PREEXISTING_DIR_METHOD="rename" -EMC_GRID_NAME="GSD_HRRR25km" +EMC_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.nco_GSD_SUBCONUS3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh similarity index 90% rename from tests/baseline_configs/config.nco_GSD_SUBCONUS3km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh index 87814fd5b..1bb952e72 100644 --- a/tests/baseline_configs/config.nco_GSD_SUBCONUS3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh @@ -1,7 +1,7 @@ RUN_ENVIR="nco" PREEXISTING_DIR_METHOD="rename" -EMC_GRID_NAME="GSD_SUBCONUS3km" +EMC_GRID_NAME="RRFS_SUBCONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh b/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh index 6652b2a8c..e08418601 100644 --- a/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh +++ b/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.regional_001.sh b/tests/baseline_configs/config.regional_001.sh index 26db77458..4f6c92ceb 100644 --- a/tests/baseline_configs/config.regional_001.sh +++ b/tests/baseline_configs/config.regional_001.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.regional_002.sh b/tests/baseline_configs/config.regional_002.sh index 89ffb439e..678975ecc 100644 --- a/tests/baseline_configs/config.regional_002.sh +++ b/tests/baseline_configs/config.regional_002.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_CPT_v0.sh b/tests/baseline_configs/config.suite_FV3_CPT_v0.sh index f5d369b99..d23e50841 100644 --- a/tests/baseline_configs/config.suite_FV3_CPT_v0.sh +++ b/tests/baseline_configs/config.suite_FV3_CPT_v0.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh b/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh index afa644cec..692db567c 100644 --- a/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh +++ b/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh b/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh index 92868325f..554b8a727 100644 --- a/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh +++ b/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh b/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh index d5611fed4..613d1b786 100644 --- a/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh +++ b/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_GSD_v0.sh b/tests/baseline_configs/config.suite_FV3_GSD_v0.sh index f0699e887..9193847fe 100644 --- a/tests/baseline_configs/config.suite_FV3_GSD_v0.sh +++ b/tests/baseline_configs/config.suite_FV3_GSD_v0.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh b/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh index 79d01bd38..63b2d6404 100644 --- a/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh +++ b/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baseline_configs/config.user_download_extrn_files.sh b/tests/baseline_configs/config.user_download_extrn_files.sh index ae9aa4102..3a1b32819 100644 --- a/tests/baseline_configs/config.user_download_extrn_files.sh +++ b/tests/baseline_configs/config.user_download_extrn_files.sh @@ -1,7 +1,7 @@ RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" diff --git a/tests/baselines_list.txt b/tests/baselines_list.txt index f3e610ee8..7946d6aa0 100644 --- a/tests/baselines_list.txt +++ b/tests/baselines_list.txt @@ -6,11 +6,12 @@ get_extrn_files_from_hpss_GSMGFS_GSMGFS get_extrn_files_from_hpss_HRRRX_RAPX get_extrn_files_from_hpss_RAPX_RAPX grid_GSD_HRRR_AK_50km +grid_RRFS_CONUS_13km grid_GSD_RAP13km -nco_GSD_HRRR25km_HRRRX_RAPX -nco_GSD_HRRR3km_FV3GFS_FV3GFS -nco_GSD_HRRR3km_HRRRX_RAPX -nco_GSD_SUBCONUS3km_HRRRX_RAPX +nco_RRFS_CONUS_25km_HRRRX_RAPX +nco_RRFS_CONUS_3km_FV3GFS_FV3GFS +nco_RRFS_CONUS_3km_HRRRX_RAPX +nco_RRFS_SUBCONUS_3km_HRRRX_RAPX nco_conus nco_conus_c96 nco_conus_c96__suite_FV3_GFS_2017_gfdlmp diff --git a/ush/config.community.sh b/ush/config.community.sh index 0c735b57f..5c71641d8 100644 --- a/ush/config.community.sh +++ b/ush/config.community.sh @@ -11,7 +11,7 @@ VERBOSE="TRUE" RUN_ENVIR="community" PREEXISTING_DIR_METHOD="rename" -PREDEF_GRID_NAME="GSD_HRRR25km" +PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" USE_CCPP="TRUE" diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index 87f25e4ae..7ce18a4d6 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -708,14 +708,6 @@ GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES="TRUE" # NOTE: Probably don't need to make this a user-specified variable. # Just set it in the function set_gridparams_ESGgrid.sh. # -# ESGgrid_ALPHA_PARAM: -# The alpha parameter used in the Jim Purser map projection/grid generation -# method. -# -# ESGgrid_KAPPA_PARAM: -# The kappa parameter used in the Jim Purser map projection/grid generation -# method. -# #----------------------------------------------------------------------- # ESGgrid_LON_CTR="-97.5" @@ -725,8 +717,6 @@ ESGgrid_DELY="3000.0" ESGgrid_NX="1000" ESGgrid_NY="1000" ESGgrid_WIDE_HALO_WIDTH="6" -ESGgrid_ALPHA_PARAM="0.21423" -ESGgrid_KAPPA_PARAM="-0.23209" # #----------------------------------------------------------------------- # diff --git a/ush/set_gridparams_ESGgrid.sh b/ush/set_gridparams_ESGgrid.sh index 669efb771..8cef16ee3 100644 --- a/ush/set_gridparams_ESGgrid.sh +++ b/ush/set_gridparams_ESGgrid.sh @@ -55,8 +55,6 @@ function set_gridparams_ESGgrid() { "halo_width" \ "delx" \ "dely" \ -"alpha" \ -"kappa" \ "output_varname_lon_ctr" \ "output_varname_lat_ctr" \ "output_varname_nx" \ diff --git a/ush/set_predef_grid_params.sh b/ush/set_predef_grid_params.sh index 5c038a93e..636fcf70c 100644 --- a/ush/set_predef_grid_params.sh +++ b/ush/set_predef_grid_params.sh @@ -322,7 +322,7 @@ predefined domain: # #----------------------------------------------------------------------- # -"GSD_HRRR25km") +"RRFS_CONUS_25km") if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then @@ -340,16 +340,16 @@ predefined domain: ESGgrid_DELX="25000.0" ESGgrid_DELY="25000.0" - ESGgrid_NX=200 - ESGgrid_NY=110 + ESGgrid_NX=204 + ESGgrid_NY=114 ESGgrid_WIDE_HALO_WIDTH=6 DT_ATMOS="300" - LAYOUT_X="20" + LAYOUT_X="6" LAYOUT_Y="2" - BLOCKSIZE="10" + BLOCKSIZE="34" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" @@ -359,10 +359,10 @@ predefined domain: WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="191" - WRTCMP_ny="97" - WRTCMP_lon_lwr_left="-120.72962370" - WRTCMP_lat_lwr_left="25.11648583" + WRTCMP_nx="201" + WRTCMP_ny="109" + WRTCMP_lon_lwr_left="-121.52372751" + WRTCMP_lat_lwr_left="23.57183129" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -376,7 +376,7 @@ predefined domain: # #----------------------------------------------------------------------- # -"GSD_HRRR13km") +"RRFS_CONUS_13km") if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then @@ -394,29 +394,29 @@ predefined domain: ESGgrid_DELX="13000.0" ESGgrid_DELY="13000.0" - ESGgrid_NX=390 - ESGgrid_NY=210 + ESGgrid_NX=400 + ESGgrid_NY=232 ESGgrid_WIDE_HALO_WIDTH=6 DT_ATMOS="180" - LAYOUT_X="10" - LAYOUT_Y="10" - BLOCKSIZE="39" + LAYOUT_X="16" + LAYOUT_Y="8" + BLOCKSIZE="29" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" - WRTCMP_write_tasks_per_group="10" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) WRTCMP_output_grid="lambert_conformal" WRTCMP_cen_lon="${ESGgrid_LON_CTR}" WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="383" - WRTCMP_ny="195" - WRTCMP_lon_lwr_left="-121.58647982" - WRTCMP_lat_lwr_left="24.36006861" + WRTCMP_nx="397" + WRTCMP_ny="225" + WRTCMP_lon_lwr_left="-121.93788248" + WRTCMP_lat_lwr_left="22.51531359" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -430,57 +430,15 @@ predefined domain: # #----------------------------------------------------------------------- # -"GSD_HRRR3km") +"RRFS_CONUS_3km") if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then - GFDLgrid_LON_T6_CTR=-97.5 - GFDLgrid_LAT_T6_CTR=38.5 - GFDLgrid_STRETCH_FAC=1.0001 - GFDLgrid_RES="96" - GFDLgrid_REFINE_RATIO=36 - - #num_margin_#num_margin_cells_T6_left=9 - #GFDLgrid_ISTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_left + 1 )) - GFDLgrid_ISTART_OF_RGNL_DOM_ON_T6G="26" - - #num_margin_cells_T6_right=9 - #GFDLgrid_IEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_right )) - GFDLgrid_IEND_OF_RGNL_DOM_ON_T6G="71" - - #num_margin_cells_T6_bottom=9 - #GFDLgrid_JSTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_bottom + 1 )) - GFDLgrid_JSTART_OF_RGNL_DOM_ON_T6G="36" - - #num_margin_cells_T6_top=9 - #GFDLgrid_JEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_top )) - GFDLgrid_JEND_OF_RGNL_DOM_ON_T6G="61" - - GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES="FALSE" - - DT_ATMOS="40" - - LAYOUT_X="18" - LAYOUT_Y="12" - BLOCKSIZE="46" - - QUILTING="TRUE" - - if [ "$QUILTING" = "TRUE" ]; then - WRTCMP_write_groups="1" - WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) - WRTCMP_output_grid="lambert_conformal" - WRTCMP_cen_lon="-97.5" - WRTCMP_cen_lat="38.5" - WRTCMP_stdlat1="38.5" - WRTCMP_stdlat2="38.5" - WRTCMP_nx="1738" - WRTCMP_ny="974" - WRTCMP_lon_lwr_left="-122.21414225" - WRTCMP_lat_lwr_left="22.41403305" - WRTCMP_dx="3000.0" - WRTCMP_dy="3000.0" - fi + print_err_msg_exit "\ +The parameters for a \"${GRID_GEN_METHOD}\" type grid have not yet been specified for this +predefined domain: + PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\" + GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\"" elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then @@ -490,29 +448,29 @@ predefined domain: ESGgrid_DELX="3000.0" ESGgrid_DELY="3000.0" - ESGgrid_NX=1728 - ESGgrid_NY=1008 + ESGgrid_NX=1740 + ESGgrid_NY=1036 ESGgrid_WIDE_HALO_WIDTH=6 DT_ATMOS="40" - LAYOUT_X="32" - LAYOUT_Y="16" - BLOCKSIZE="27" + LAYOUT_X="30" + LAYOUT_Y="14" + BLOCKSIZE="29" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" - WRTCMP_write_tasks_per_group="24" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) WRTCMP_output_grid="lambert_conformal" WRTCMP_cen_lon="${ESGgrid_LON_CTR}" WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="1726" - WRTCMP_ny="974" - WRTCMP_lon_lwr_left="-122.21414225" - WRTCMP_lat_lwr_left="22.41403305" + WRTCMP_nx="1738" + WRTCMP_ny="1012" + WRTCMP_lon_lwr_left="-122.07320852" + WRTCMP_lat_lwr_left="21.93831404" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -526,7 +484,7 @@ predefined domain: # #----------------------------------------------------------------------- # -"GSD_SUBCONUS3km") +"RRFS_SUBCONUS_3km") if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then @@ -551,9 +509,6 @@ predefined domain: DT_ATMOS="40" -# LAYOUT_X="12" -# LAYOUT_Y="10" -# BLOCKSIZE="30" LAYOUT_X="30" LAYOUT_Y="24" BLOCKSIZE="35" @@ -566,10 +521,10 @@ predefined domain: WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="825" - WRTCMP_ny="580" - WRTCMP_lon_lwr_left="-109.8" - WRTCMP_lat_lwr_left="26.5" + WRTCMP_nx="837" + WRTCMP_ny="595" + WRTCMP_lon_lwr_left="-109.97410429" + WRTCMP_lat_lwr_left="26.31459843" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -579,6 +534,134 @@ predefined domain: # #----------------------------------------------------------------------- # +# A CONUS domain of GFDLgrid type with ~25km cells. +# Note: +# This grid is larger than the HRRR domain and thus cannot be initialized +# using the HRRRX. +# +#----------------------------------------------------------------------- +# +"CONUS_25km_GFDLgrid") + + if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then + + GFDLgrid_LON_T6_CTR=-97.5 + GFDLgrid_LAT_T6_CTR=38.5 + GFDLgrid_STRETCH_FAC=1.4 + GFDLgrid_RES="96" + GFDLgrid_REFINE_RATIO=3 + + num_margin_cells_T6_left=12 + GFDLgrid_ISTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_left + 1 )) + + num_margin_cells_T6_right=12 + GFDLgrid_IEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_right )) + + num_margin_cells_T6_bottom=16 + GFDLgrid_JSTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_bottom + 1 )) + + num_margin_cells_T6_top=16 + GFDLgrid_JEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_top )) + +# GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES="FALSE" + + DT_ATMOS="225" + + LAYOUT_X="6" + LAYOUT_Y="4" + BLOCKSIZE="36" + + if [ "$QUILTING" = "TRUE" ]; then + WRTCMP_write_groups="1" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) + WRTCMP_output_grid="rotated_latlon" + WRTCMP_cen_lon="${GFDLgrid_LON_T6_CTR}" + WRTCMP_cen_lat="${GFDLgrid_LAT_T6_CTR}" + WRTCMP_lon_lwr_left="-24.40085141" + WRTCMP_lat_lwr_left="-19.65624142" + WRTCMP_lon_upr_rght="24.40085141" + WRTCMP_lat_upr_rght="19.65624142" + WRTCMP_dlon="0.22593381" + WRTCMP_dlat="0.22593381" + fi + + elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then + + print_err_msg_exit "\ +The parameters for a \"${GRID_GEN_METHOD}\" type grid have not yet been specified for this +predefined domain: + PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\" + GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\"" + + fi + ;; +# +#----------------------------------------------------------------------- +# +# A CONUS domain of GFDLgrid type with ~3km cells. +# Note: +# This grid is larger than the HRRR domain and thus cannot be initialized +# using the HRRRX. +# +#----------------------------------------------------------------------- +# +"CONUS_3km_GFDLgrid") + + if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then + + GFDLgrid_LON_T6_CTR=-97.5 + GFDLgrid_LAT_T6_CTR=38.5 + GFDLgrid_STRETCH_FAC=1.5 + GFDLgrid_RES="768" + GFDLgrid_REFINE_RATIO=3 + + num_margin_cells_T6_left=69 + GFDLgrid_ISTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_left + 1 )) + + num_margin_cells_T6_right=69 + GFDLgrid_IEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_right )) + + num_margin_cells_T6_bottom=164 + GFDLgrid_JSTART_OF_RGNL_DOM_ON_T6G=$(( num_margin_cells_T6_bottom + 1 )) + + num_margin_cells_T6_top=164 + GFDLgrid_JEND_OF_RGNL_DOM_ON_T6G=$(( GFDLgrid_RES - num_margin_cells_T6_top )) + +# GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES="FALSE" + + DT_ATMOS="18" + + LAYOUT_X="30" + LAYOUT_Y="22" + BLOCKSIZE="35" + + if [ "$QUILTING" = "TRUE" ]; then + WRTCMP_write_groups="1" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) + WRTCMP_output_grid="rotated_latlon" + WRTCMP_cen_lon="${GFDLgrid_LON_T6_CTR}" + WRTCMP_cen_lat="${GFDLgrid_LAT_T6_CTR}" + WRTCMP_lon_lwr_left="-25.23144805" + WRTCMP_lat_lwr_left="-15.82130419" + WRTCMP_lon_upr_rght="25.23144805" + WRTCMP_lat_upr_rght="15.82130419" + WRTCMP_dlon="0.02665763" + WRTCMP_dlat="0.02665763" + fi + + elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then + + print_err_msg_exit "\ +The parameters for a \"${GRID_GEN_METHOD}\" type grid have not yet been specified for this +predefined domain: + PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\" + GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\"" + + fi + ;; +# +#----------------------------------------------------------------------- +# # EMC's 3km CONUS grid. # #----------------------------------------------------------------------- @@ -865,7 +948,7 @@ predefined domain: # #----------------------------------------------------------------------- # -"GSD_RRFSAK_3km") +"RRFS_AK_3km") if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then @@ -924,24 +1007,25 @@ predefined domain: ESGgrid_WIDE_HALO_WIDTH=6 - DT_ATMOS="50" +# DT_ATMOS="50" + DT_ATMOS="10" LAYOUT_X="30" LAYOUT_Y="17" - BLOCKSIZE="25" + BLOCKSIZE="40" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" - WRTCMP_write_tasks_per_group="2" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) WRTCMP_output_grid="lambert_conformal" WRTCMP_cen_lon="${ESGgrid_LON_CTR}" WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="1320" - WRTCMP_ny="950" - WRTCMP_lon_lwr_left="173.734" - WRTCMP_lat_lwr_left="46.740347" + WRTCMP_nx="1379" + WRTCMP_ny="1003" + WRTCMP_lon_lwr_left="-187.89737923" + WRTCMP_lat_lwr_left="45.84576053" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -951,6 +1035,83 @@ predefined domain: # #----------------------------------------------------------------------- # +# 13-km HRRR Alaska grid. +# +#----------------------------------------------------------------------- +# +"RRFS_AK_13km") + + if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then + + print_err_msg_exit "\ +The parameters for a \"${GRID_GEN_METHOD}\" type grid have not yet been specified for this +predefined domain: + PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\" + GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\"" + + elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then + + ESGgrid_LON_CTR=-161.5 + ESGgrid_LAT_CTR=63.0 + + ESGgrid_DELX="13000.0" + ESGgrid_DELY="13000.0" + + ESGgrid_NX=320 + ESGgrid_NY=240 + + ESGgrid_WIDE_HALO_WIDTH=6 + +# DT_ATMOS="50" + DT_ATMOS="10" + + LAYOUT_X="16" + LAYOUT_Y="12" + BLOCKSIZE="40" + + if [ "$QUILTING" = "TRUE" ]; then + WRTCMP_write_groups="1" + WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) + WRTCMP_output_grid="lambert_conformal" + WRTCMP_cen_lon="${ESGgrid_LON_CTR}" + WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" + WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" + WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" + +# The following work. They were obtained using the NCL scripts but only +# after manually modifying the longitutes of two of the 4 corners of the +# domain to add 360.0 to them. Need to automate that procedure. + WRTCMP_nx="318" + WRTCMP_ny="234" +# WRTCMP_lon_lwr_left="-187.76660836" + WRTCMP_lon_lwr_left="172.23339164" + WRTCMP_lat_lwr_left="45.77691870" + + WRTCMP_dx="${ESGgrid_DELX}" + WRTCMP_dy="${ESGgrid_DELY}" + fi + +# The following rotated_latlon coordinate system parameters were obtained +# using the NCL code and work. +# if [ "$QUILTING" = "TRUE" ]; then +# WRTCMP_write_groups="1" +# WRTCMP_write_tasks_per_group=$(( 1*LAYOUT_Y )) +# WRTCMP_output_grid="rotated_latlon" +# WRTCMP_cen_lon="${ESGgrid_LON_CTR}" +# WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" +# WRTCMP_lon_lwr_left="-18.47206579" +# WRTCMP_lat_lwr_left="-13.56176982" +# WRTCMP_lon_upr_rght="18.47206579" +# WRTCMP_lat_upr_rght="13.56176982" +# WRTCMP_dlon="0.11691181" +# WRTCMP_dlat="0.11691181" +# fi + + fi + ;; +# +#----------------------------------------------------------------------- +# # 50-km HRRR Alaska grid. # #----------------------------------------------------------------------- @@ -963,8 +1124,8 @@ predefined domain: The parameters for a \"${GRID_GEN_METHOD}\" type grid have not yet been specified for this predefined domain: PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\" - GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\" -" + GRID_GEN_METHOD = \"${GRID_GEN_METHOD}\"" + elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then ESGgrid_LON_CTR=-163.5 diff --git a/ush/setup.sh b/ush/setup.sh index bf9f38572..307f41253 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -480,7 +480,7 @@ case "${EMC_GRID_NAME}" in "conus_c96") PREDEF_GRID_NAME="EMC_CONUS_coarse" ;; - "GSD_HRRR25km" | "GSD_HRRR13km" | "GSD_HRRR3km" | "GSD_SUBCONUS3km") + "RRFS_CONUS_25km" | "RRFS_CONUS_13km" | "RRFS_CONUS_3km" | "RRFS_SUBCONUS_3km") PREDEF_GRID_NAME="${EMC_GRID_NAME}" ;; "conus_orig" | "guam" | "hi" | "pr") @@ -1019,7 +1019,7 @@ fi if [ "${EXPT_BASEDIR:0:1}" != "/" ]; then EXPT_BASEDIR="${SR_WX_APP_TOP_DIR}/../expt_dirs/${EXPT_BASEDIR}" fi -EXPT_BASEDIR="$( readlink -f ${EXPT_BASEDIR} )" +EXPT_BASEDIR="$( readlink -m ${EXPT_BASEDIR} )" mkdir_vrfy -p "${EXPT_BASEDIR}" # #----------------------------------------------------------------------- @@ -1768,8 +1768,6 @@ elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then halo_width="${ESGgrid_WIDE_HALO_WIDTH}" \ delx="${ESGgrid_DELX}" \ dely="${ESGgrid_DELY}" \ - alpha="${ESGgrid_ALPHA_PARAM}" \ - kappa="${ESGgrid_KAPPA_PARAM}" \ output_varname_lon_ctr="LON_CTR" \ output_varname_lat_ctr="LAT_CTR" \ output_varname_nx="NX" \ diff --git a/ush/templates/wrtcmp_lambert_conformal b/ush/templates/wrtcmp_lambert_conformal index 1219885a8..fd4e52eea 100644 --- a/ush/templates/wrtcmp_lambert_conformal +++ b/ush/templates/wrtcmp_lambert_conformal @@ -12,10 +12,10 @@ cen_lon: # Reference longitude, in degrees. cen_lat: # Reference latitude, in degrees. stdlat1: # Latitude of first standard parallel, in degrees. stdlat2: # Latitude of second standard parallel, in degrees. -nx: # Number of points along x-axis in Lambert conformal (x,y) plane. -ny: # Number of points along y-axis in Lambert conformal (x,y) plane. -lon1: # Longitude of grid point at lower-left corner of grid, in degrees. -lat1: # Latitude of grid point at lower-left corner of grid, in degrees. +nx: # Number of grid cells along x-axis in Lambert conformal (x,y) plane. +ny: # Number of grid cells along y-axis in Lambert conformal (x,y) plane. +lon1: # Longitude of center of grid cell at bottom-left corner of grid, in degrees. +lat1: # Latitude of center of grid cell at bottom-left corner of grid, in degrees. dx: # Grid cell size in x direction, in meters. dy: # Grid cell size in y direction, in meters. diff --git a/ush/valid_param_vals.sh b/ush/valid_param_vals.sh index 92298fae4..be3d8c177 100644 --- a/ush/valid_param_vals.sh +++ b/ush/valid_param_vals.sh @@ -12,12 +12,15 @@ valid_vals_PREDEF_GRID_NAME=( \ "GSD_HAFSV0.A3km" \ "GSD_HAFSV0.A13km" \ "GSD_HAFSV0.A25km" \ -"GSD_RRFSAK_3km" \ +"RRFS_AK_13km" \ +"RRFS_AK_3km" \ "GSD_HRRR_AK_50km" \ -"GSD_HRRR25km" \ -"GSD_HRRR13km" \ -"GSD_HRRR3km" \ -"GSD_SUBCONUS3km" \ +"RRFS_CONUS_25km" \ +"RRFS_CONUS_13km" \ +"RRFS_CONUS_3km" \ +"RRFS_SUBCONUS_3km" \ +"CONUS_25km_GFDLgrid" \ +"CONUS_3km_GFDLgrid" \ "GSD_RAP13km" \ ) valid_vals_EMC_GRID_NAME=( \ @@ -28,10 +31,10 @@ valid_vals_EMC_GRID_NAME=( \ "guam" \ "hi" \ "pr" \ -"GSD_HRRR25km" \ -"GSD_HRRR13km" \ -"GSD_HRRR3km" \ -"GSD_SUBCONUS3km" \ +"RRFS_CONUS_25km" \ +"RRFS_CONUS_13km" \ +"RRFS_CONUS_3km" \ +"RRFS_SUBCONUS_3km" \ "GSD_RAP13km" \ ) valid_vals_USE_CCPP=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") From 81281b06fc934401ca3741313e538e02a9322cbb Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Thu, 8 Oct 2020 17:40:19 -0500 Subject: [PATCH 04/39] Bug fixes for Orion port. --- tests/run_experiments.sh | 2 ++ ush/setup.sh | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/run_experiments.sh b/tests/run_experiments.sh index 753e6917e..f71de6902 100755 --- a/tests/run_experiments.sh +++ b/tests/run_experiments.sh @@ -741,6 +741,8 @@ PTMP=\"${PTMP}\"" extrn_mdl_source_basedir="/mnt/lfs1/BMC/fim/Gerard.Ketefian/UFS_CAM/staged_extrn_mdl_files" elif [ "$MACHINE" = "CHEYENNE" ]; then extrn_mdl_source_basedir="/glade/p/ral/jntp/UFS_CAM/staged_extrn_mdl_files" + elif [ "$MACHINE" = "ORION" ]; then + extrn_mdl_source_basedir="/work/noaa/gsd-fv3-dev/gsketefia/UFS/staged_extrn_mdl_files" else print_err_msg_exit "\ The base directory (extrn_mdl_source_basedir) in which the user-staged diff --git a/ush/setup.sh b/ush/setup.sh index ce6c462c5..6b6386cd1 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -403,7 +403,7 @@ case $MACHINE in SCHED="${SCHED:-slurm}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} QUEUE_HPSS=${QUEUE_HPSS:-"service"} - QUEUE_FCST=${QUEUE_FCST:-""} + QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; # esac From 92c626a3d36de803f0c5b6c159601f041c545371 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Thu, 8 Oct 2020 19:26:56 -0500 Subject: [PATCH 05/39] Add TOPO_DIR for ORION; don't require that the full path except last portion to the EXPT_BASEDIR initially exist (i.e. no -f to readlink) before creating the directory. --- ush/setup.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ush/setup.sh b/ush/setup.sh index 6b6386cd1..81a7d452f 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -779,6 +779,7 @@ case $MACHINE in "ORION") FIXgsm="/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am" + TOPO_DIR="/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am" SFC_CLIMO_INPUT_DIR="/dont/know/what/this/should/be" ;; @@ -1027,7 +1028,7 @@ fi if [ "${EXPT_BASEDIR:0:1}" != "/" ]; then EXPT_BASEDIR="${SR_WX_APP_TOP_DIR}/../expt_dirs/${EXPT_BASEDIR}" fi -EXPT_BASEDIR="$( readlink -f ${EXPT_BASEDIR} )" +EXPT_BASEDIR="$( readlink -m ${EXPT_BASEDIR} )" mkdir_vrfy -p "${EXPT_BASEDIR}" # #----------------------------------------------------------------------- From d79ebc34f8bacaee5948030cab460d8da144d774 Mon Sep 17 00:00:00 2001 From: Michael Kavulich Date: Thu, 8 Oct 2020 22:16:53 -0600 Subject: [PATCH 06/39] Modifications to run workflow with unmodified executable names from each repository (#304) ## DESCRIPTION OF CHANGES: The new top-level cmake build for the SRW App ([SRW App PR#27](https://github.com/ufs-community/ufs-srweather-app/pull/27)) results in some executables having different names. This PR makes modifications that 1. Allow the workflow to run successfully with the new cmake build and its different executable names, and 2. Allow back-compatibility with the old build system to allow for a gradual transition to new build system This PR also explicitly disallows running the workflow without CCPP, which we decided against supporting several months ago. I don't think the capability even works so this shouldn't effect anyone at this time. ## TESTS CONDUCTED: - **Cheyenne**: Build and end-to-end test ("DOT_OR_USCORE" test case) was successful on Cheyenne with intel, both for the cmake build and the old build script (that will soon be deprecated). - **Hera**: Build and end-to-end tests successful (aside from expected failures). Also built with old build script successfully. - **Jet**: Build test was successful. ## ISSUE: It was not the primary aim of this PR, but it does partially resolve #196 --- scripts/exregional_make_grid.sh | 2 +- scripts/exregional_make_ics.sh | 2 +- scripts/exregional_make_lbcs.sh | 2 +- scripts/exregional_make_orog.sh | 4 ++-- ush/generate_FV3LAM_wflow.sh | 22 +++++++++++++++++++--- ush/setup.sh | 2 +- 6 files changed, 25 insertions(+), 9 deletions(-) diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index f37402c48..c7b850005 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -513,7 +513,7 @@ fi # # Set the name and path to the executable and make sure that it exists. # -exec_fn="shave.x" +exec_fn="shave" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ diff --git a/scripts/exregional_make_ics.sh b/scripts/exregional_make_ics.sh index 6759edc64..3cd3dfdf7 100755 --- a/scripts/exregional_make_ics.sh +++ b/scripts/exregional_make_ics.sh @@ -493,7 +493,7 @@ hh="${EXTRN_MDL_CDATE:8:2}" # #----------------------------------------------------------------------- # -exec_fn="chgres_cube.exe" +exec_fn="chgres_cube" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ diff --git a/scripts/exregional_make_lbcs.sh b/scripts/exregional_make_lbcs.sh index 84f317d74..6f074ae5d 100755 --- a/scripts/exregional_make_lbcs.sh +++ b/scripts/exregional_make_lbcs.sh @@ -344,7 +344,7 @@ esac # #----------------------------------------------------------------------- # -exec_fn="chgres_cube.exe" +exec_fn="chgres_cube" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index 1d1f5586e..61639c3b3 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -181,7 +181,7 @@ mkdir_vrfy -p "${shave_dir}" # Set the name and path to the executable that generates the raw orography # file and make sure that it exists. # -exec_fn="orog.x" +exec_fn="orog" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ @@ -531,7 +531,7 @@ Filtering of orography complete." # # Set the name and path to the executable and make sure that it exists. # -exec_fn="shave.x" +exec_fn="shave" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 0244cd7cd..489a2b536 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -589,12 +589,28 @@ fi #----------------------------------------------------------------------- # if [ "${USE_CCPP}" = "TRUE" ]; then - exec_fn="fv3.exe" + exec_fn="NEMS.exe" else - exec_fn="fv3_32bit.exe" + print_err_msg_exit "\ +Running this workflow without CCPP is not supported at this time. +Please set USE_CCPP=TRUE in your config.sh file. +" +fi + +exec_fp="${SR_WX_APP_TOP_DIR}/bin/${exec_fn}" +#Check for the old build location for fv3 executable +if [ ! -f "${exec_fp}" ]; then + exec_fp_alt="${UFS_WTHR_MDL_DIR}/build/${exec_fn}" + if [ ! -f "${exec_fp_alt}" ]; then + print_err_msg_exit "\ +The executable (exec_fp) for running the forecast model does not exist: + exec_fp = \"${exec_fp}\" +Please ensure that you've built this executable." + else + exec_fp="${exec_fp_alt}" + fi fi -exec_fp="${UFS_WTHR_MDL_DIR}/tests/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ The executable (exec_fp) for running the forecast model does not exist: diff --git a/ush/setup.sh b/ush/setup.sh index 307f41253..20a6f49c4 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -715,7 +715,7 @@ SORCDIR="$HOMErrfs/sorc" SRC_DIR="${SR_WX_APP_TOP_DIR}/src" PARMDIR="$HOMErrfs/parm" MODULES_DIR="$HOMErrfs/modulefiles" -EXECDIR="${SR_WX_APP_TOP_DIR}/exec" +EXECDIR="${SR_WX_APP_TOP_DIR}/bin" FIXrrfs="$HOMErrfs/fix" TEMPLATE_DIR="$USHDIR/templates" From d684d82a910387d6ace2257eb9c732ce90dd6236 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 16:53:29 -0500 Subject: [PATCH 07/39] More modifications to run workflow on orion. --- ush/get_extrn_mdl_file_dir_info.sh | 15 +++++++++++++++ ush/launch_FV3LAM_wflow.sh | 8 ++++++-- ush/load_modules_run_task.sh | 4 ++++ ush/set_extrn_mdl_params.sh | 8 ++++---- ush/setup.sh | 18 ++++++------------ 5 files changed, 35 insertions(+), 18 deletions(-) diff --git a/ush/get_extrn_mdl_file_dir_info.sh b/ush/get_extrn_mdl_file_dir_info.sh index ae1300634..f2055d068 100755 --- a/ush/get_extrn_mdl_file_dir_info.sh +++ b/ush/get_extrn_mdl_file_dir_info.sh @@ -560,6 +560,9 @@ bination of external model (extrn_mdl_name) and analysis or forecast "HERA") sysdir="" ;; + "ORION") + sysdir="$sysbasedir" + ;; "JET") sysdir="" ;; @@ -594,6 +597,9 @@ has not been specified for this external model and machine combination: "HERA") sysdir="$sysbasedir/gfs.${yyyymmdd}/${hh}" ;; + "ORION") + sysdir="$sysbasedir" + ;; "JET") sysdir="$sysbasedir" ;; @@ -625,6 +631,9 @@ has not been specified for this external model and machine combination: "HERA") sysdir="$sysbasedir" ;; + "ORION") + sysdir="$sysbasedir" + ;; "JET") sysdir="$sysbasedir/${yyyymmdd}${hh}/postprd" ;; @@ -656,6 +665,9 @@ has not been specified for this external model and machine combination: "HERA") sysdir="$sysbasedir" ;; + "ORION") + sysdir="$sysbasedir" + ;; "JET") sysdir="$sysbasedir/${yyyymmdd}${hh}/postprd" ;; @@ -686,6 +698,9 @@ has not been specified for this external model and machine combination: "HERA") sysdir="$sysbasedir" ;; + "ORION") + sysdir="$sysbasedir" + ;; "JET") sysdir="$sysbasedir" ;; diff --git a/ush/launch_FV3LAM_wflow.sh b/ush/launch_FV3LAM_wflow.sh index 8004e32e4..60910d812 100755 --- a/ush/launch_FV3LAM_wflow.sh +++ b/ush/launch_FV3LAM_wflow.sh @@ -92,8 +92,12 @@ expt_name="${EXPT_SUBDIR}" #----------------------------------------------------------------------- # if [ "$MACHINE" != "CHEYENNE" ]; then - module purge - module load rocoto + if [ "$MACHINE" = "ORION" ]; then + module load contrib rocoto + else + module purge + module load rocoto + fi fi # #----------------------------------------------------------------------- diff --git a/ush/load_modules_run_task.sh b/ush/load_modules_run_task.sh index 6e523ce3e..94ef2039d 100755 --- a/ush/load_modules_run_task.sh +++ b/ush/load_modules_run_task.sh @@ -114,6 +114,10 @@ case "$MACHINE" in "HERA") . /apps/lmod/lmod/init/sh ;; +# + "ORION") + . /apps/lmod/lmod/init/sh + ;; # "JET") . /apps/lmod/lmod/init/sh diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index 2a4e88ffd..4e68bf474 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -75,7 +75,7 @@ else EXTRN_MDL_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; "ORION") - EXTRN_MDL_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" ;; esac ;; @@ -101,7 +101,7 @@ else EXTRN_MDL_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "ORION") - EXTRN_MDL_SYSBASEDIR_ICS="" + EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" ;; esac ;; @@ -222,7 +222,7 @@ else EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; "ORION") - EXTRN_MDL_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="dummy_value" ;; esac ;; @@ -248,7 +248,7 @@ else EXTRN_MDL_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; "ORION") - EXTRN_MDL_SYSBASEDIR_LBCS="" + EXTRN_MDL_SYSBASEDIR_LBCS="dummy_value" ;; esac ;; diff --git a/ush/setup.sh b/ush/setup.sh index 81a7d452f..c99054e51 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -741,18 +741,18 @@ case $MACHINE in SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} ;; -"THEIA") - FIXgsm=${FIXgsm:-"/scratch4/NCEPDEV/global/save/glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/scratch4/NCEPDEV/global/save/glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch4/NCEPDEV/da/noscrub/George.Gayno/climo_fields_netcdf"} - ;; - "HERA") FIXgsm=${FIXgsm:-"/scratch1/NCEPDEV/global/glopara/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/scratch1/NCEPDEV/global/glopara/fix/fix_orog"} SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch1/NCEPDEV/da/George.Gayno/ufs_utils.git/climo_fields_netcdf"} ;; +"ORION") + FIXgsm=${FIXgsm:-"/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/climo_fields_netcdf"} + ;; + "JET") FIXgsm=${FIXgsm:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_orog"} @@ -777,12 +777,6 @@ case $MACHINE in SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/00315/tg455890/stampede2/regional_fv3/climo_fields_netcdf"} ;; -"ORION") - FIXgsm="/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am" - TOPO_DIR="/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am" - SFC_CLIMO_INPUT_DIR="/dont/know/what/this/should/be" - ;; - *) print_err_msg_exit "\ One or more fix file directories have not been specified for this machine: From c3db63f98c6c0eb498b3f898ff929de593a696c5 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 16:58:01 -0500 Subject: [PATCH 08/39] Add module files for orion. --- modulefiles/tasks/orion/get_extrn_ics | 6 ++++++ modulefiles/tasks/orion/get_extrn_lbcs | 6 ++++++ modulefiles/tasks/orion/make_grid.local | 6 ++++++ modulefiles/tasks/orion/make_ics.local | 6 ++++++ modulefiles/tasks/orion/make_lbcs.local | 6 ++++++ modulefiles/tasks/orion/run_fcst.local | 6 ++++++ 6 files changed, 36 insertions(+) create mode 100644 modulefiles/tasks/orion/get_extrn_ics create mode 100644 modulefiles/tasks/orion/get_extrn_lbcs create mode 100644 modulefiles/tasks/orion/make_grid.local create mode 100644 modulefiles/tasks/orion/make_ics.local create mode 100644 modulefiles/tasks/orion/make_lbcs.local create mode 100644 modulefiles/tasks/orion/run_fcst.local diff --git a/modulefiles/tasks/orion/get_extrn_ics b/modulefiles/tasks/orion/get_extrn_ics new file mode 100644 index 000000000..a9d5b4412 --- /dev/null +++ b/modulefiles/tasks/orion/get_extrn_ics @@ -0,0 +1,6 @@ +#%Module##################################################### +## Module file for get_extrn_ics task. +############################################################# + +module purge + diff --git a/modulefiles/tasks/orion/get_extrn_lbcs b/modulefiles/tasks/orion/get_extrn_lbcs new file mode 100644 index 000000000..09f37151a --- /dev/null +++ b/modulefiles/tasks/orion/get_extrn_lbcs @@ -0,0 +1,6 @@ +#%Module##################################################### +## Module file for get_extrn_lbcs task. +############################################################# + +module purge + diff --git a/modulefiles/tasks/orion/make_grid.local b/modulefiles/tasks/orion/make_grid.local new file mode 100644 index 000000000..5c1331242 --- /dev/null +++ b/modulefiles/tasks/orion/make_grid.local @@ -0,0 +1,6 @@ + +#module use -a /contrib/miniconda3/modulefiles +#module load miniconda3 +#if [module-info mode load] { +# system "conda activate regional_workflow" +#} diff --git a/modulefiles/tasks/orion/make_ics.local b/modulefiles/tasks/orion/make_ics.local new file mode 100644 index 000000000..5c1331242 --- /dev/null +++ b/modulefiles/tasks/orion/make_ics.local @@ -0,0 +1,6 @@ + +#module use -a /contrib/miniconda3/modulefiles +#module load miniconda3 +#if [module-info mode load] { +# system "conda activate regional_workflow" +#} diff --git a/modulefiles/tasks/orion/make_lbcs.local b/modulefiles/tasks/orion/make_lbcs.local new file mode 100644 index 000000000..5c1331242 --- /dev/null +++ b/modulefiles/tasks/orion/make_lbcs.local @@ -0,0 +1,6 @@ + +#module use -a /contrib/miniconda3/modulefiles +#module load miniconda3 +#if [module-info mode load] { +# system "conda activate regional_workflow" +#} diff --git a/modulefiles/tasks/orion/run_fcst.local b/modulefiles/tasks/orion/run_fcst.local new file mode 100644 index 000000000..5c1331242 --- /dev/null +++ b/modulefiles/tasks/orion/run_fcst.local @@ -0,0 +1,6 @@ + +#module use -a /contrib/miniconda3/modulefiles +#module load miniconda3 +#if [module-info mode load] { +# system "conda activate regional_workflow" +#} From a2ab5b9f5a0586544a60b0e73cab4042c9127451 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 17:46:07 -0500 Subject: [PATCH 09/39] Changes to orion modulefiles. --- modulefiles/tasks/orion/make_grid.local | 1 + modulefiles/tasks/orion/make_ics.local | 1 + modulefiles/tasks/orion/make_lbcs.local | 1 + modulefiles/tasks/orion/run_fcst.local | 1 + 4 files changed, 4 insertions(+) diff --git a/modulefiles/tasks/orion/make_grid.local b/modulefiles/tasks/orion/make_grid.local index 5c1331242..7b0776c62 100644 --- a/modulefiles/tasks/orion/make_grid.local +++ b/modulefiles/tasks/orion/make_grid.local @@ -4,3 +4,4 @@ #if [module-info mode load] { # system "conda activate regional_workflow" #} +module load python/3.7 diff --git a/modulefiles/tasks/orion/make_ics.local b/modulefiles/tasks/orion/make_ics.local index 5c1331242..7b0776c62 100644 --- a/modulefiles/tasks/orion/make_ics.local +++ b/modulefiles/tasks/orion/make_ics.local @@ -4,3 +4,4 @@ #if [module-info mode load] { # system "conda activate regional_workflow" #} +module load python/3.7 diff --git a/modulefiles/tasks/orion/make_lbcs.local b/modulefiles/tasks/orion/make_lbcs.local index 5c1331242..7b0776c62 100644 --- a/modulefiles/tasks/orion/make_lbcs.local +++ b/modulefiles/tasks/orion/make_lbcs.local @@ -4,3 +4,4 @@ #if [module-info mode load] { # system "conda activate regional_workflow" #} +module load python/3.7 diff --git a/modulefiles/tasks/orion/run_fcst.local b/modulefiles/tasks/orion/run_fcst.local index 5c1331242..2b539c8f0 100644 --- a/modulefiles/tasks/orion/run_fcst.local +++ b/modulefiles/tasks/orion/run_fcst.local @@ -4,3 +4,4 @@ #if [module-info mode load] { # system "conda activate regional_workflow" #} +#module load python/3.7 From 896733860a3924077ddc71d79793eb4c28af094d Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 18:29:36 -0500 Subject: [PATCH 10/39] Remove the "-l" flag to bash so that the script is no longer executed in a login shell. This allows the settings set by a "module load" (e.g. module load python/3.7 that prepends a python path to PATH) to be inherited by the script rather than get overwritten. --- tests/run_experiments.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/run_experiments.sh b/tests/run_experiments.sh index f71de6902..ceead7215 100755 --- a/tests/run_experiments.sh +++ b/tests/run_experiments.sh @@ -1,4 +1,4 @@ -#!/bin/bash -l +#!/bin/bash # #----------------------------------------------------------------------- From 4e5f55cf4cf8a7189bf213025f0fee128400bcd8 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 19:02:04 -0500 Subject: [PATCH 11/39] Clean up spacing, etc. --- jobs/JREGIONAL_MAKE_ICS | 13 ++- jobs/JREGIONAL_MAKE_LBCS | 13 ++- scripts/exregional_make_grid.sh | 166 ++++++++++++++------------- scripts/exregional_make_orog.sh | 126 ++++++++++---------- scripts/exregional_make_sfc_climo.sh | 60 +++++----- scripts/exregional_run_fcst.sh | 122 ++++++++++---------- scripts/exregional_run_post.sh | 97 ++++++++-------- 7 files changed, 314 insertions(+), 283 deletions(-) diff --git a/jobs/JREGIONAL_MAKE_ICS b/jobs/JREGIONAL_MAKE_ICS index bb0f71c3c..ff3cc5010 100755 --- a/jobs/JREGIONAL_MAKE_ICS +++ b/jobs/JREGIONAL_MAKE_ICS @@ -70,6 +70,11 @@ case "$MACHINE" in APRUN="srun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + "JET") ulimit -s unlimited APRUN="srun" @@ -88,9 +93,11 @@ case "$MACHINE" in APRUN="ibrun" ;; - "ORION") - ulimit -s unlimited - APRUN="srun" + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" ;; esac diff --git a/jobs/JREGIONAL_MAKE_LBCS b/jobs/JREGIONAL_MAKE_LBCS index 58d53f3ec..c09c17f6c 100755 --- a/jobs/JREGIONAL_MAKE_LBCS +++ b/jobs/JREGIONAL_MAKE_LBCS @@ -70,6 +70,11 @@ case "$MACHINE" in APRUN="srun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + "JET") ulimit -s unlimited APRUN="srun" @@ -88,9 +93,11 @@ case "$MACHINE" in APRUN="ibrun" ;; - "ORION") - ulimit -s unlimited - APRUN="srun" + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" ;; esac diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index 4ae93e7b6..4c3a2f6d0 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -99,60 +99,64 @@ export OMP_STACKSIZE=2048m # case $MACHINE in -"WCOSS_C" | "WCOSS") - { save_shell_opts; set +x; } > /dev/null 2>&1 + "WCOSS_C" | "WCOSS") + { save_shell_opts; set +x; } > /dev/null 2>&1 - . $MODULESHOME/init/sh - module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 - module list + . $MODULESHOME/init/sh + module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 + module list - { restore_shell_opts; } > /dev/null 2>&1 + { restore_shell_opts; } > /dev/null 2>&1 - export NODES=1 - export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" - export KMP_AFFINITY=disabled + export NODES=1 + export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" + export KMP_AFFINITY=disabled - ulimit -s unlimited - ulimit -a - ;; + ulimit -s unlimited + ulimit -a + ;; -"HERA") - APRUN="time" -# ulimit -s unlimited -# ulimit -a - ;; + "HERA") + APRUN="time" + ;; -"JET") - APRUN="time" - ulimit -a - ;; + "ORION") + APRUN="time" + ;; + "JET") + APRUN="time" + ulimit -a + ;; -"ODIN") - export APRUN="srun -n 1" - ulimit -s unlimited - ulimit -a - ;; + "ODIN") + export APRUN="srun -n 1" + ulimit -s unlimited + ulimit -a + ;; -"CHEYENNE") - APRUN="time" - ;; + "CHEYENNE") + APRUN="time" + ;; -"STAMPEDE") - export APRUN="time" - ulimit -s unlimited - ulimit -a - ;; + "STAMPEDE") + export APRUN="time" + ulimit -s unlimited + ulimit -a + ;; -"ORION") - APRUN="time" - ;; + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" + ;; esac # #----------------------------------------------------------------------- # -# Create the (cycle-independent) subdirectories under the experiment +# Create the (cycle-independent) subdirectories under the experiment # directory (EXPTDIR) that are needed by the various steps and substeps # in this script. # @@ -198,12 +202,12 @@ mkdir_vrfy -p "$tmpdir" # size specified by the argument to the --halo flag does not extend be- # yond the boundaries of the parent grid (tile 6). In this case, since # the values passed to the --istart_nest, ..., and --jend_nest flags al- -# ready include a halo (because these arguments are +# ready include a halo (because these arguments are # -# ${ISTART_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, -# ${IEND_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, +# ${ISTART_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, +# ${IEND_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, # ${JSTART_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, and -# ${JEND_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, +# ${JEND_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG}, # # i.e. they include "WITH_WIDE_HALO_" in their names), it is reasonable # to pass as the argument to --halo a zero. However, make_hgrid re- @@ -221,7 +225,7 @@ mkdir_vrfy -p "$tmpdir" # --nlon 2*${RES} \ # --grid_name C${RES}_grid \ # --do_schmidt --stretch_factor ${STRETCH_FAC} \ -# --target_lon ${LON_CTR} +# --target_lon ${LON_CTR} # --target_lat ${LAT_CTR} \ # --nest_grid --parent_tile 6 --refine_ratio ${GFDLgrid_REFINE_RATIO} \ # --istart_nest ${ISTART_OF_RGNL_DOM_WITH_WIDE_HALO_ON_T6SG} \ @@ -326,7 +330,7 @@ if [ "${GRID_GEN_METHOD}" = "GFDLgrid" ]; then --halo 1 \ --great_circle_algorithm || \ print_err_msg_exit "\ -Call to executable (exec_fp) that generates grid files returned with +Call to executable (exec_fp) that generates grid files returned with nonzero exit code. exec_fp = \"${exec_fp}\"" # @@ -344,15 +348,15 @@ elif [ "${GRID_GEN_METHOD}" = "ESGgrid" ]; then rgnl_grid_nml_fp="$tmpdir/${RGNL_GRID_NML_FN}" print_info_msg "$VERBOSE" " -Creating namelist file (rgnl_grid_nml_fp) to be read in by the grid +Creating namelist file (rgnl_grid_nml_fp) to be read in by the grid generation executable (exec_fp): rgnl_grid_nml_fp = \"${rgnl_grid_nml_fp}\" exec_fp = \"${exec_fp}\"" # -# Create a multiline variable that consists of a yaml-compliant string -# specifying the values that the namelist variables need to be set to -# (one namelist variable per line, plus a header and footer). Below, -# this variable will be passed to a python script that will create the +# Create a multiline variable that consists of a yaml-compliant string +# specifying the values that the namelist variables need to be set to +# (one namelist variable per line, plus a header and footer). Below, +# this variable will be passed to a python script that will create the # namelist file. # settings=" @@ -370,8 +374,8 @@ generation executable (exec_fp): # ${USHDIR}/set_namelist.py -q -u "$settings" -o ${rgnl_grid_nml_fp} || \ print_err_msg_exit "\ -Call to python script set_namelist.py to set the variables in the -regional_esg_grid namelist file failed. Parameters passed to this script +Call to python script set_namelist.py to set the variables in the +regional_esg_grid namelist file failed. Parameters passed to this script are: Full path to output namelist file: rgnl_grid_nml_fp = \"${rgn_grid_nml_fp}\" @@ -385,9 +389,9 @@ $settings" print_err_msg_exit "\ Call to executable (exec_fp) that generates a ESGgrid-type regional grid returned with nonzero exit code: - exec_fp = \"${exec_fp}\"" + exec_fp = \"${exec_fp}\"" # -# Set the name of the regional grid file generated by the above call. +# Set the name of the regional grid file generated by the above call. # This must be the same name as in the regional_esg_grid code. # grid_fn="regional_grid.nc" @@ -475,7 +479,7 @@ mv_vrfy "${grid_fp_orig}" "${grid_fp}" # be using (i.e. if RUN_TASK_MAKE_OROG or RUN_TASK_MAKE_SURF_CLIMO is set # to "FALSE", in which case RES_IN_FIXLAM_FILENAMES will not be set to a # null string), check that the grid resolution contained in the variable -# CRES set above matches the resolution appearing in the names of the +# CRES set above matches the resolution appearing in the names of the # preexisting orography and/or surface climatology files. # #----------------------------------------------------------------------- @@ -484,7 +488,7 @@ if [ ! -z "${RES_IN_FIXLAM_FILENAMES}" ]; then res="${CRES:1}" if [ "$res" -ne "${RES_IN_FIXLAM_FILENAMES}" ]; then print_err_msg_exit "\ -The resolution (res) calculated for the grid does not match the resolution +The resolution (res) calculated for the grid does not match the resolution (RES_IN_FIXLAM_FILENAMES) appearing in the names of the orography and/or surface climatology files: res = \"$res\" @@ -494,10 +498,10 @@ fi # #----------------------------------------------------------------------- # -# Partially "shave" the halo from the grid file having a wide halo to +# Partially "shave" the halo from the grid file having a wide halo to # generate two new grid files -- one with a 3-grid-wide halo and another # with a 4-cell-wide halo. These are needed as inputs by the forecast -# model as well as by the code (chgres_cube) that generates the lateral +# model as well as by the code (chgres_cube) that generates the lateral # boundary condition files. <== Are these also needed by make_sfc_climo??? # #----------------------------------------------------------------------- @@ -508,27 +512,27 @@ exec_fn="shave.x" exec_fp="$EXECDIR/${exec_fn}" if [ ! -f "${exec_fp}" ]; then print_err_msg_exit "\ -The executable (exec_fp) for \"shaving\" down the halo in the grid file +The executable (exec_fp) for \"shaving\" down the halo in the grid file does not exist: exec_fp = \"${exec_fp}\" Please ensure that you've built this executable." fi # # Set the full path to the "unshaved" grid file, i.e. the one with a wide -# halo. This is the input grid file for generating both the grid file +# halo. This is the input grid file for generating both the grid file # with a 3-cell-wide halo and the one with a 4-cell-wide halo. # unshaved_fp="${grid_fp}" # -# We perform the work in tmpdir, so change location to that directory. -# Once it is complete, we will move the resultant file from tmpdir to +# We perform the work in tmpdir, so change location to that directory. +# Once it is complete, we will move the resultant file from tmpdir to # GRID_DIR. # cd_vrfy "$tmpdir" # # Create an input namelist file for the shave executable to generate a -# grid file with a 3-cell-wide halo from the one with a wide halo. Then -# call the shave executable. Finally, move the resultant file to the +# grid file with a 3-cell-wide halo from the one with a wide halo. Then +# call the shave executable. Finally, move the resultant file to the # GRID_DIR directory. # print_info_msg "$VERBOSE" " @@ -553,8 +557,8 @@ The namelist file (nml_fn) used in this call is in directory tmpdir: mv_vrfy ${shaved_fp} ${GRID_DIR} # # Create an input namelist file for the shave executable to generate a -# grid file with a 4-cell-wide halo from the one with a wide halo. Then -# call the shave executable. Finally, move the resultant file to the +# grid file with a 4-cell-wide halo from the one with a wide halo. Then +# call the shave executable. Finally, move the resultant file to the # GRID_DIR directory. # print_info_msg "$VERBOSE" " @@ -626,7 +630,7 @@ halo failed." # #----------------------------------------------------------------------- # -# Create symlinks in the FIXLAM directory to the grid and mosaic files +# Create symlinks in the FIXLAM directory to the grid and mosaic files # generated above in the GRID_DIR directory. # #----------------------------------------------------------------------- @@ -640,28 +644,28 @@ failed." # #----------------------------------------------------------------------- # -# Call a function (set_FV3nml_sfc_climo_filenames) to set the values of -# those variables in the forecast model's namelist file that specify the -# paths to the surface climatology files. These files will either already +# Call a function (set_FV3nml_sfc_climo_filenames) to set the values of +# those variables in the forecast model's namelist file that specify the +# paths to the surface climatology files. These files will either already # be avaialable in a user-specified directory (SFC_CLIMO_DIR) or will be -# generated by the MAKE_SFC_CLIMO_TN task. They (or symlinks to them) +# generated by the MAKE_SFC_CLIMO_TN task. They (or symlinks to them) # will be placed (or wll already exist) in the FIXLAM directory. # -# Also, if running ensemble forecasts, call a function (set_FV3nml_stoch_params) -# to create a new FV3 namelist file for each ensemble member that contains -# a unique set of stochastic parameters (i.e. relative to the namelist +# Also, if running ensemble forecasts, call a function (set_FV3nml_stoch_params) +# to create a new FV3 namelist file for each ensemble member that contains +# a unique set of stochastic parameters (i.e. relative to the namelist # files of the other members). # -# Note that unless RUN_TASK_MAKE_GRID is set to "FALSE", the call to -# set_FV3nml_sfc_climo_filenames has to be performed here instead of -# earlier during experiment generation because the surface climatology -# file names depend on the grid resolution variable CRES, and that may +# Note that unless RUN_TASK_MAKE_GRID is set to "FALSE", the call to +# set_FV3nml_sfc_climo_filenames has to be performed here instead of +# earlier during experiment generation because the surface climatology +# file names depend on the grid resolution variable CRES, and that may # not be available until the above steps in this script have been performed. # -# Similarly, unless RUN_TASK_MAKE_GRID is set to "FALSE", the call to -# set_FV3nml_stoch_params must be performed here because it uses the +# Similarly, unless RUN_TASK_MAKE_GRID is set to "FALSE", the call to +# set_FV3nml_stoch_params must be performed here because it uses the # namelist file generated by the call to set_FV3nml_sfc_climo_filenames -# as a starting point (base) and modifies it to add the stochastic +# as a starting point (base) and modifies it to add the stochastic # parameters. Thus, the changes made by set_FV3nml_sfc_climo_filenames # must already be in the base namelist file. # @@ -678,7 +682,7 @@ for the various ensemble members failed." fi create_diag_table_files || print_err_msg_exit "\ -Call to function to create a diagnostics table file under each cycle +Call to function to create a diagnostics table file under each cycle directory failed." # #----------------------------------------------------------------------- diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index a6c4dbad8..38cd95fdd 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -98,55 +98,61 @@ export OMP_STACKSIZE=2048m # case $MACHINE in -"WCOSS_C" | "WCOSS") - { save_shell_opts; set +x; } > /dev/null 2>&1 - - . $MODULESHOME/init/sh - module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 - module list - - { restore_shell_opts; } > /dev/null 2>&1 - - export NODES=1 - export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" - export KMP_AFFINITY=disabled - - ulimit -s unlimited - ulimit -a - ;; - -"HERA") - ulimit -s unlimited - ulimit -a - APRUN="time" - ;; - -"JET") - ulimit -s unlimited - ulimit -a - export APRUN="time" - ;; - - -"ODIN") - export APRUN="srun -n 1" - ulimit -s unlimited - ulimit -a - ;; - -"CHEYENNE") - APRUN="time" - ;; - -"STAMPEDE") - export APRUN="time" - ;; - -"ORION") - ulimit -s unlimited - ulimit -a - APRUN="time" - ;; + "WCOSS_C" | "WCOSS") + { save_shell_opts; set +x; } > /dev/null 2>&1 + + . $MODULESHOME/init/sh + module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 + module list + + { restore_shell_opts; } > /dev/null 2>&1 + + export NODES=1 + export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" + export KMP_AFFINITY=disabled + + ulimit -s unlimited + ulimit -a + ;; + + "HERA") + ulimit -s unlimited + ulimit -a + APRUN="time" + ;; + + "ORION") + ulimit -s unlimited + ulimit -a + APRUN="time" + ;; + + "JET") + ulimit -s unlimited + ulimit -a + export APRUN="time" + ;; + + "ODIN") + export APRUN="srun -n 1" + ulimit -s unlimited + ulimit -a + ;; + + "CHEYENNE") + APRUN="time" + ;; + + "STAMPEDE") + export APRUN="time" + ;; + + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" + ;; esac # @@ -191,7 +197,7 @@ fi # # Create a temporary (work) directory in which to generate the raw orography # file and change location to it. -# +# tmp_dir="${raw_dir}/tmp" mkdir_vrfy -p "${tmp_dir}" cd_vrfy "${tmp_dir}" @@ -229,7 +235,7 @@ grid_fp="${FIXLAM}/${grid_fn}" # them to a text file. # # Note that it doesn't matter what lonb and latb are set to below because -# if we specify an input grid file to the executable read in (which is +# if we specify an input grid file to the executable read in (which is # what we do below), then if lonb and latb are not set to the dimensions # of the grid specified in that file (divided by 2 since the grid file # specifies a "supergrid"), then lonb and latb effectively get reset to @@ -263,7 +269,7 @@ cat "${input_redirect_fn}" # #----------------------------------------------------------------------- # -# Call the executable to generate the raw orography file corresponding +# Call the executable to generate the raw orography file corresponding # to tile 7 (the regional domain) only. # # The following will create an orography file named @@ -314,7 +320,7 @@ ${tmp_dir}" \ "CHEYENNE" | "HERA" | "JET" | "ODIN" | "STAMPEDE" | "ORION") $APRUN "${exec_fp}" < "${input_redirect_fn}" || \ print_err_msg_exit "\ -Call to executable (exec_fp) that generates the raw orography file returned +Call to executable (exec_fp) that generates the raw orography file returned with nonzero exit code: exec_fp = \"${exec_fp}\"" ;; @@ -346,9 +352,9 @@ mv_vrfy "${raw_orog_fp_orig}" "${raw_orog_fp}" # # Copy the two orography files needed for the drag suite in the FV3_RRFS_v1beta # physics suite. -# -# Note that the following is a temporary fix. We need a long-term solution -# that calls a script or program to generates the necessary files (instead +# +# Note that the following is a temporary fix. We need a long-term solution +# that calls a script or program to generates the necessary files (instead # of copying them). # #----------------------------------------------------------------------- @@ -365,22 +371,22 @@ Orography file generation complete." # # Note that the orography filtering code assumes that the regional grid # is a GFDLgrid type of grid; it is not designed to handle ESGgrid type -# regional grids. If the flag "regional" in the orography filtering +# regional grids. If the flag "regional" in the orography filtering # namelist file is set to .TRUE. (which it always is will be here; see -# below), then filtering code will first calculate a resolution (i.e. +# below), then filtering code will first calculate a resolution (i.e. # number of grid points) value named res_regional for the assumed GFDLgrid # type regional grid using the formula # # res_regional = res*stretch_fac*real(refine_ratio) # # Here res, stretch_fac, and refine_ratio are the values passed to the -# code via the namelist. res and stretch_fac are assumed to be the +# code via the namelist. res and stretch_fac are assumed to be the # resolution (in terms of number of grid points) and the stretch factor # of the (GFDLgrid type) regional grid's parent global cubed-sphere grid, # and refine_ratio is the ratio of the number of grid cells on the regional # grid to a single cell on tile 6 of the parent global grid. After # calculating res_regional, the code interpolates/extrapolates between/ -# beyond a set of (currently 7) resolution values for which the four +# beyond a set of (currently 7) resolution values for which the four # filtering parameters (n_del2_weak, cd4, max_slope, peak_fac) are provided # (by GFDL) to obtain the corresponding values of these parameters at a # resolution of res_regional. These interpolated/extrapolated values are diff --git a/scripts/exregional_make_sfc_climo.sh b/scripts/exregional_make_sfc_climo.sh index 9453831ce..0e4067f0f 100755 --- a/scripts/exregional_make_sfc_climo.sh +++ b/scripts/exregional_make_sfc_climo.sh @@ -128,49 +128,49 @@ EOF # case $MACHINE in -"WCOSS_C") + "WCOSS_C") # This could be wrong. Just a guess since I don't have access to this machine. - APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} - ;; + APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} + ;; -"WCOSS") + "WCOSS") # This could be wrong. Just a guess since I don't have access to this machine. - APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} - ;; + APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} + ;; -"HERA") - APRUN="srun" - ;; + "HERA") + APRUN="srun" + ;; -"JET") - APRUN="srun" - ;; + "ORION") + APRUN="srun" + ;; -"CHEYENNE") - nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) - APRUN="mpirun -np $nprocs" - ;; + "JET") + APRUN="srun" + ;; -"ODIN") - nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) - APRUN="srun -n $nprocs" - ;; + "CHEYENNE") + nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) + APRUN="mpirun -np $nprocs" + ;; -"STAMPEDE") - nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) - APRUN="ibrun -np ${nprocs}" - ;; + "ODIN") + nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) + APRUN="srun -n $nprocs" + ;; -"ORION") - APRUN="srun" - ;; + "STAMPEDE") + nprocs=$(( NNODES_MAKE_SFC_CLIMO*PPN_MAKE_SFC_CLIMO )) + APRUN="ibrun -np ${nprocs}" + ;; -*) - print_err_msg_exit "\ + *) + print_err_msg_exit "\ Run command has not been specified for this machine: MACHINE = \"$MACHINE\" APRUN = \"$APRUN\"" - ;; + ;; esac # diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index a77bdf482..10d899034 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -88,68 +88,68 @@ print_input_args valid_args #----------------------------------------------------------------------- # case $MACHINE in -# -"WCOSS_CRAY") -# - ulimit -s unlimited - ulimit -a - APRUN="aprun -b -j1 -n${PE_MEMBER01} -N24 -d1 -cc depth" - ;; -# -"WCOSS_DELL_P3") - ulimit -s unlimited - ulimit -a - APRUN="mpirun -l -np ${PE_MEMBER01}" - ;; -# -"HERA") - ulimit -s unlimited - ulimit -a - APRUN="srun" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" - OMP_NUM_THREADS=4 - ;; -# -"JET") - ulimit -s unlimited - ulimit -a - APRUN="srun" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" - OMP_NUM_THREADS=4 - ;; -# -"ODIN") -# - module list - - ulimit -s unlimited - ulimit -a - APRUN="srun -n ${PE_MEMBER01}" - ;; -# -"CHEYENNE") -# - module list - nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) - APRUN="mpirun -np $nprocs" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" - ;; -# - -"STAMPEDE") -# - module list - APRUN="ibrun -np ${PE_MEMBER01}" - #LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" - ;; -# -"ORION") - ulimit -s unlimited - ulimit -a - APRUN="srun" -# LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" -# + "WCOSS_CRAY") + ulimit -s unlimited + ulimit -a + APRUN="aprun -b -j1 -n${PE_MEMBER01} -N24 -d1 -cc depth" + ;; + + "WCOSS_DELL_P3") + ulimit -s unlimited + ulimit -a + APRUN="mpirun -l -np ${PE_MEMBER01}" + ;; + + "HERA") + ulimit -s unlimited + ulimit -a + APRUN="srun" + LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" + OMP_NUM_THREADS=4 + ;; + + "ORION") + ulimit -s unlimited + ulimit -a + APRUN="srun" +# LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" + + "JET") + ulimit -s unlimited + ulimit -a + APRUN="srun" + LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" + OMP_NUM_THREADS=4 + ;; + + "ODIN") + module list + ulimit -s unlimited + ulimit -a + APRUN="srun -n ${PE_MEMBER01}" + ;; + + "CHEYENNE") + module list + nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) + APRUN="mpirun -np $nprocs" + LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" + ;; + + "STAMPEDE") + module list + APRUN="ibrun -np ${PE_MEMBER01}" +# LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" + ;; + + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" + ;; + esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_run_post.sh b/scripts/exregional_run_post.sh index 8d799e03a..957c19c21 100755 --- a/scripts/exregional_run_post.sh +++ b/scripts/exregional_run_post.sh @@ -82,58 +82,65 @@ print_input_args valid_args # case $MACHINE in -"WCOSS_CRAY") + "WCOSS_CRAY") # Specify computational resources. - export NODES=2 - export ntasks=48 - export ptile=24 - export threads=1 - export MP_LABELIO=yes - export OMP_NUM_THREADS=$threads + export NODES=2 + export ntasks=48 + export ptile=24 + export threads=1 + export MP_LABELIO=yes + export OMP_NUM_THREADS=$threads - APRUN="aprun -j 1 -n${ntasks} -N${ptile} -d${threads} -cc depth" - ;; + APRUN="aprun -j 1 -n${ntasks} -N${ptile} -d${threads} -cc depth" + ;; -"WCOSS_DELL_P3") + "WCOSS_DELL_P3") # Specify computational resources. - export NODES=2 - export ntasks=48 - export ptile=24 - export threads=1 - export MP_LABELIO=yes - export OMP_NUM_THREADS=$threads - - APRUN="mpirun" - ;; + export NODES=2 + export ntasks=48 + export ptile=24 + export threads=1 + export MP_LABELIO=yes + export OMP_NUM_THREADS=$threads -"HERA") - APRUN="srun" - ;; + APRUN="mpirun" + ;; -"JET") - APRUN="srun" - ;; + "HERA") + APRUN="srun" + ;; -"ODIN") - APRUN="srun -n 1" - ;; + "ORION") + APRUN="srun" + ;; -"CHEYENNE") - module list - nprocs=$(( NNODES_RUN_POST*PPN_RUN_POST )) - APRUN="mpirun -np $nprocs" - ;; + "JET") + APRUN="srun" + ;; -"STAMPEDE") - nprocs=$(( NNODES_RUN_POST*PPN_RUN_POST )) - APRUN="ibrun -n $nprocs" - ;; + "ODIN") + APRUN="srun -n 1" + ;; -"ORION") - APRUN="srun" - ;; + "CHEYENNE") + module list + nprocs=$(( NNODES_RUN_POST*PPN_RUN_POST )) + APRUN="mpirun -np $nprocs" + ;; + + "STAMPEDE") + nprocs=$(( NNODES_RUN_POST*PPN_RUN_POST )) + APRUN="ibrun -n $nprocs" + ;; + + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" + ;; esac # @@ -149,7 +156,7 @@ if [ ${USE_CUSTOM_POST_CONFIG_FILE} = "TRUE" ]; then post_config_fp="${CUSTOM_POST_CONFIG_FP}" print_info_msg " ==================================================================== -Copying the user-defined post flat file specified by CUSTOM_POST_CONFIG_FP +Copying the user-defined post flat file specified by CUSTOM_POST_CONFIG_FP to the post forecast hour directory (fhr_dir): CUSTOM_POST_CONFIG_FP = \"${CUSTOM_POST_CONFIG_FP}\" fhr_dir = \"${fhr_dir}\" @@ -158,7 +165,7 @@ else post_config_fp="${EMC_POST_DIR}/parm/postxconfig-NT-fv3lam.txt" print_info_msg " ==================================================================== -Copying the default post flat file specified by post_config_fp to the post +Copying the default post flat file specified by post_config_fp to the post forecast hour directory (fhr_dir): post_config_fp = \"${post_config_fp}\" fhr_dir = \"${fhr_dir}\" @@ -170,7 +177,7 @@ cp_vrfy ${EXECDIR}/ncep_post . # #----------------------------------------------------------------------- # -# Get the cycle date and hour (in formats of yyyymmdd and hh, respectively) +# Get the cycle date and hour (in formats of yyyymmdd and hh, respectively) # from cdate. # #----------------------------------------------------------------------- @@ -225,14 +232,14 @@ zero exit code." #----------------------------------------------------------------------- # # Move (and rename) the output files from the work directory to their -# final location (postprd_dir). Then delete the work directory. +# final location (postprd_dir). Then delete the work directory. # #----------------------------------------------------------------------- # # #----------------------------------------------------------------------- # -# A separate ${post_fhr} forecast hour variable is required for the post +# A separate ${post_fhr} forecast hour variable is required for the post # files, since they may or may not be three digits long, depending on the # length of the forecast. # From 0077c062cedeace59752aa7ba88e4715bf18ffe6 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 19:08:36 -0500 Subject: [PATCH 12/39] More spacing changes. --- ush/setup.sh | 252 ++++++++++++++++++++-------------------- ush/valid_param_vals.sh | 2 +- 2 files changed, 127 insertions(+), 127 deletions(-) diff --git a/ush/setup.sh b/ush/setup.sh index c99054e51..51ce38c6f 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -338,74 +338,74 @@ check_var_valid_value "MACHINE" "valid_vals_MACHINE" #----------------------------------------------------------------------- # case $MACHINE in -# -"WCOSS_CRAY") - NCORES_PER_NODE="24" - SCHED="lsfcray" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} - QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} - QUEUE_HPSS_TAG="queue" # lsfcray does not support "partition" tag - QUEUE_FCST=${QUEUE_FCST:-"dev"} - ;; -# -"WCOSS_DELL_P3") - NCORES_PER_NODE=24 - SCHED="lsf" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} - QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} - QUEUE_HPSS_TAG="queue" # lsf does not support "partition" tag - QUEUE_FCST=${QUEUE_FCST:-"dev"} - ;; -# -"HERA") - NCORES_PER_NODE=24 # Should this be 40? Need to check heradocs. - SCHED="${SCHED:-slurm}" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} - QUEUE_FCST=${QUEUE_FCST:-"batch"} - ;; -# -"JET") - NCORES_PER_NODE=24 - SCHED="${SCHED:-slurm}" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} - QUEUE_FCST=${QUEUE_FCST:-"batch"} - ;; -# -"ODIN") - NCORES_PER_NODE=24 - SCHED="${SCHED:-slurm}" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} - QUEUE_HPSS=${QUEUE_HPSS:-""} - QUEUE_FCST=${QUEUE_FCST:-""} - ;; -# -"CHEYENNE") - NCORES_PER_NODE=36 - SCHED="${SCHED:-pbspro}" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"regular"} - QUEUE_HPSS=${QUEUE_HPSS:-"regular"} - QUEUE_HPSS_TAG="queue" # pbspro does not support "partition" tag - QUEUE_FCST=${QUEUE_FCST:-"regular"} - ;; -# -"STAMPEDE") - NCORES_PER_NODE=68 - SCHED="slurm" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} - QUEUE_HPSS=${QUEUE_HPSS:-"development"} - QUEUE_FCST=${QUEUE_FCST:-"normal"} - ;; -# -"ORION") - NCORES_PER_NODE=40 - SCHED="${SCHED:-slurm}" - QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} - QUEUE_FCST=${QUEUE_FCST:-"batch"} - ;; -# + + "WCOSS_CRAY") + NCORES_PER_NODE="24" + SCHED="lsfcray" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} + QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} + QUEUE_HPSS_TAG="queue" # lsfcray does not support "partition" tag + QUEUE_FCST=${QUEUE_FCST:-"dev"} + ;; + + "WCOSS_DELL_P3") + NCORES_PER_NODE=24 + SCHED="lsf" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} + QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} + QUEUE_HPSS_TAG="queue" # lsf does not support "partition" tag + QUEUE_FCST=${QUEUE_FCST:-"dev"} + ;; + + "HERA") + NCORES_PER_NODE=24 # Should this be 40? Need to check heradocs. + SCHED="${SCHED:-slurm}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_FCST=${QUEUE_FCST:-"batch"} + ;; + + "ORION") + NCORES_PER_NODE=40 + SCHED="${SCHED:-slurm}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_FCST=${QUEUE_FCST:-"batch"} + ;; + + "JET") + NCORES_PER_NODE=24 + SCHED="${SCHED:-slurm}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_FCST=${QUEUE_FCST:-"batch"} + ;; + + "ODIN") + NCORES_PER_NODE=24 + SCHED="${SCHED:-slurm}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} + QUEUE_HPSS=${QUEUE_HPSS:-""} + QUEUE_FCST=${QUEUE_FCST:-""} + ;; + + "CHEYENNE") + NCORES_PER_NODE=36 + SCHED="${SCHED:-pbspro}" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"regular"} + QUEUE_HPSS=${QUEUE_HPSS:-"regular"} + QUEUE_HPSS_TAG="queue" # pbspro does not support "partition" tag + QUEUE_FCST=${QUEUE_FCST:-"regular"} + ;; + + "STAMPEDE") + NCORES_PER_NODE=68 + SCHED="slurm" + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} + QUEUE_HPSS=${QUEUE_HPSS:-"development"} + QUEUE_FCST=${QUEUE_FCST:-"normal"} + ;; + esac # #----------------------------------------------------------------------- @@ -723,70 +723,70 @@ TEMPLATE_DIR="$USHDIR/templates" case $MACHINE in -"WCOSS_CRAY") - FIXgsm=${FIXgsm:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - -"WCOSS_DELL_P3") - FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - -"DELL") - FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - -"HERA") - FIXgsm=${FIXgsm:-"/scratch1/NCEPDEV/global/glopara/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/scratch1/NCEPDEV/global/glopara/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch1/NCEPDEV/da/George.Gayno/ufs_utils.git/climo_fields_netcdf"} - ;; - -"ORION") - FIXgsm=${FIXgsm:-"/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/climo_fields_netcdf"} - ;; - -"JET") - FIXgsm=${FIXgsm:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/lfs1/HFIP/hwrf-data/git/fv3gfs/fix/fix_sfc_climo"} - ;; - -"ODIN") - FIXgsm=${FIXgsm:-"/scratch/ywang/fix/theia_fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/scratch/ywang/fix/theia_fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch/ywang/fix/climo_fields_netcdf"} - ;; - -"CHEYENNE") - FIXgsm=${FIXgsm:-"/glade/p/ral/jntp/UFS_CAM/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/glade/p/ral/jntp/UFS_CAM/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/glade/p/ral/jntp/UFS_CAM/fix/climo_fields_netcdf"} - ;; - -"STAMPEDE") - FIXgsm=${FIXgsm:-"/work/00315/tg455890/stampede2/regional_fv3/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/work/00315/tg455890/stampede2/regional_fv3/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/00315/tg455890/stampede2/regional_fv3/climo_fields_netcdf"} - ;; - -*) - print_err_msg_exit "\ + "WCOSS_CRAY") + FIXgsm=${FIXgsm:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + ;; + + "WCOSS_DELL_P3") + FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + ;; + + "DELL") + FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + ;; + + "HERA") + FIXgsm=${FIXgsm:-"/scratch1/NCEPDEV/global/glopara/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/scratch1/NCEPDEV/global/glopara/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch1/NCEPDEV/da/George.Gayno/ufs_utils.git/climo_fields_netcdf"} + ;; + + "ORION") + FIXgsm=${FIXgsm:-"/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/climo_fields_netcdf"} + ;; + + "JET") + FIXgsm=${FIXgsm:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/lfs4/HFIP/hfv3gfs/glopara/git/fv3gfs/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/lfs1/HFIP/hwrf-data/git/fv3gfs/fix/fix_sfc_climo"} + ;; + + "ODIN") + FIXgsm=${FIXgsm:-"/scratch/ywang/fix/theia_fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/scratch/ywang/fix/theia_fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch/ywang/fix/climo_fields_netcdf"} + ;; + + "CHEYENNE") + FIXgsm=${FIXgsm:-"/glade/p/ral/jntp/UFS_CAM/fix/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/glade/p/ral/jntp/UFS_CAM/fix/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/glade/p/ral/jntp/UFS_CAM/fix/climo_fields_netcdf"} + ;; + + "STAMPEDE") + FIXgsm=${FIXgsm:-"/work/00315/tg455890/stampede2/regional_fv3/fix_am"} + TOPO_DIR=${TOPO_DIR:-"/work/00315/tg455890/stampede2/regional_fv3/fix_orog"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/00315/tg455890/stampede2/regional_fv3/climo_fields_netcdf"} + ;; + + *) + print_err_msg_exit "\ One or more fix file directories have not been specified for this machine: MACHINE = \"$MACHINE\" FIXgsm = \"${FIXgsm:-\"\"} TOPO_DIR = \"${TOPO_DIR:-\"\"} SFC_CLIMO_INPUT_DIR = \"${SFC_CLIMO_INPUT_DIR:-\"\"} - You can specify the missing location(s) in config.sh" - ;; + ;; + esac # #----------------------------------------------------------------------- diff --git a/ush/valid_param_vals.sh b/ush/valid_param_vals.sh index 4e9fffcc4..7d3001fef 100644 --- a/ush/valid_param_vals.sh +++ b/ush/valid_param_vals.sh @@ -1,6 +1,6 @@ valid_vals_RUN_ENVIR=("nco" "community") valid_vals_VERBOSE=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") -valid_vals_MACHINE=("WCOSS_CRAY" "WCOSS_DELL_P3" "THEIA" "HERA" "JET" "ODIN" "CHEYENNE" "STAMPEDE" "ORION") +valid_vals_MACHINE=("WCOSS_CRAY" "WCOSS_DELL_P3" "HERA" "ORION" "JET" "ODIN" "CHEYENNE" "STAMPEDE") valid_vals_SCHED=("slurm" "pbspro" "lsf" "lsfcray" "none") valid_vals_PREDEF_GRID_NAME=( \ "EMC_CONUS_3km" \ From ad04092d523c19e8bd88e9bbb393057aa4888187 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 20:39:42 -0500 Subject: [PATCH 13/39] Bug fix. --- scripts/exregional_run_fcst.sh | 63 +++++++++++++++++----------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 10d899034..5dd04f437 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -94,13 +94,13 @@ case $MACHINE in ulimit -a APRUN="aprun -b -j1 -n${PE_MEMBER01} -N24 -d1 -cc depth" ;; - + "WCOSS_DELL_P3") ulimit -s unlimited ulimit -a APRUN="mpirun -l -np ${PE_MEMBER01}" ;; - + "HERA") ulimit -s unlimited ulimit -a @@ -108,13 +108,14 @@ case $MACHINE in LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" OMP_NUM_THREADS=4 ;; - + "ORION") ulimit -s unlimited ulimit -a APRUN="srun" # LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" - + ;; + "JET") ulimit -s unlimited ulimit -a @@ -122,34 +123,34 @@ case $MACHINE in LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" OMP_NUM_THREADS=4 ;; - + "ODIN") module list ulimit -s unlimited ulimit -a APRUN="srun -n ${PE_MEMBER01}" ;; - + "CHEYENNE") module list nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) APRUN="mpirun -np $nprocs" LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" ;; - + "STAMPEDE") module list APRUN="ibrun -np ${PE_MEMBER01}" # LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" ;; - + *) print_err_msg_exit "\ Run command has not been specified for this machine: MACHINE = \"$MACHINE\" APRUN = \"$APRUN\"" ;; - + esac # #----------------------------------------------------------------------- @@ -162,13 +163,13 @@ run_dir="${cycle_dir}${slash_ensmem_subdir}" # #----------------------------------------------------------------------- # -# Create links in the INPUT subdirectory of the current run directory to +# Create links in the INPUT subdirectory of the current run directory to # the grid and (filtered) orography files. # #----------------------------------------------------------------------- # print_info_msg "$VERBOSE" " -Creating links in the INPUT subdirectory of the current run directory to +Creating links in the INPUT subdirectory of the current run directory to the grid and (filtered) orography files ..." @@ -259,14 +260,14 @@ Cannot create symlink because target does not exist: fi # # If using the FV3_RRFS_v1beta physics suite, there are two files (that -# contain statistics of the orography) that are needed by the drag +# contain statistics of the orography) that are needed by the drag # parameterization in that suite. Below, symlinks to these are created # in the run directory. Note that the symlinks must have specific names -# that the FV3 model is hardcoded to recognize ("${CRES}_" and "halo0" +# that the FV3 model is hardcoded to recognize ("${CRES}_" and "halo0" # must be stripped from the file names). We use those below. # if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then -# Symlink to orographic statistics fields file with "${CRES}_" and "halo0" +# Symlink to orographic statistics fields file with "${CRES}_" and "halo0" # stripped from name. target="${FIXLAM}/${CRES}${DOT_OR_USCORE}oro_data_ls.tile${TILE_RGNL}.halo${NH0}.nc" symlink="oro_data_ls.nc" @@ -322,7 +323,7 @@ fi # gfs_bndy*.nc # gfs_ctrl.nc # -# Some of these files (gfs_ctrl.nc, gfs_bndy*.nc) already exist, but +# Some of these files (gfs_ctrl.nc, gfs_bndy*.nc) already exist, but # others do not. Thus, create links with these names to the appropriate # files (in this case the initial condition and surface files only). # @@ -363,9 +364,9 @@ fi #----------------------------------------------------------------------- # # Create links in the current run directory to fixed (i.e. static) files -# in the FIXam directory. These links have names that are set to the +# in the FIXam directory. These links have names that are set to the # names of files that the forecast model expects to exist in the current -# working directory when the forecast model executable is called (and +# working directory when the forecast model executable is called (and # that is just the run directory). # #----------------------------------------------------------------------- @@ -373,7 +374,7 @@ fi cd_vrfy ${run_dir} print_info_msg "$VERBOSE" " -Creating links in the current run directory (run_dir) to fixed (i.e. +Creating links in the current run directory (run_dir) to fixed (i.e. static) files in the FIXam directory: FIXam = \"${FIXam}\" run_dir = \"${run_dir}\"" @@ -407,8 +408,8 @@ done # #----------------------------------------------------------------------- # -# If running this cycle/ensemble member combination more than once (e.g. -# using rocotoboot), remove any time stamp file that may exist from the +# If running this cycle/ensemble member combination more than once (e.g. +# using rocotoboot), remove any time stamp file that may exist from the # previous attempt. # #----------------------------------------------------------------------- @@ -419,13 +420,13 @@ rm_vrfy -f time_stamp.out #----------------------------------------------------------------------- # # Create links in the current run directory to cycle-independent (and -# ensemble-member-independent) model input files in the main experiment +# ensemble-member-independent) model input files in the main experiment # directory. # #----------------------------------------------------------------------- # print_info_msg "$VERBOSE" " -Creating links in the current run directory to cycle-independent model +Creating links in the current run directory to cycle-independent model input files in the main experiment directory..." relative_or_null="" @@ -445,7 +446,7 @@ fi if [ "${USE_CCPP}" = "TRUE" ]; then - ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} + ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ @@ -466,17 +467,17 @@ create_model_configure_file \ cdate="$cdate" \ nthreads=${OMP_NUM_THREADS:-1} \ run_dir="${run_dir}" || print_err_msg_exit "\ -Call to function to create a model configuration file for the current +Call to function to create a model configuration file for the current cycle's (cdate) run directory (run_dir) failed: cdate = \"${cdate}\" run_dir = \"${run_dir}\"" # #----------------------------------------------------------------------- # -# If running ensemble forecasts, create a link to the cycle-specific -# diagnostic tables file in the cycle directory. Note that this link -# should not be made if not running ensemble forecasts because in that -# case, the cycle directory is the run directory (and we would be creating +# If running ensemble forecasts, create a link to the cycle-specific +# diagnostic tables file in the cycle directory. Note that this link +# should not be made if not running ensemble forecasts because in that +# case, the cycle directory is the run directory (and we would be creating # a symlink with the name of a file that already exists). # #----------------------------------------------------------------------- @@ -501,15 +502,15 @@ export OMP_STACKSIZE=1024m #----------------------------------------------------------------------- # # Run the FV3-LAM model. Note that we have to launch the forecast from -# the current cycle's directory because the FV3 executable will look for -# input files in the current directory. Since those files have been +# the current cycle's directory because the FV3 executable will look for +# input files in the current directory. Since those files have been # staged in the cycle directory, the current directory must be the cycle # directory (which it already is). # #----------------------------------------------------------------------- # $APRUN ${FV3_EXEC_FP} || print_err_msg_exit "\ -Call to executable to run FV3-LAM forecast returned with nonzero exit +Call to executable to run FV3-LAM forecast returned with nonzero exit code." # #----------------------------------------------------------------------- From 116086aad84d4b5e70a20cef4c0d9d20df429fbd Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 9 Oct 2020 20:40:18 -0500 Subject: [PATCH 14/39] Rearrange case-statement cases for consistency with case-statements in other scripts. --- ush/set_extrn_mdl_params.sh | 38 +++++++++++++++++++++++-------------- 1 file changed, 24 insertions(+), 14 deletions(-) diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index 4e68bf474..9ec1c8707 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -62,6 +62,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_ICS="" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_ICS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_ICS="" ;; @@ -74,9 +77,6 @@ else "STAMPEDE") EXTRN_MDL_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; - "ORION") - EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" - ;; esac ;; @@ -91,6 +91,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_ICS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_ICS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_ICS="/public/data/grids/gfs/nemsio" ;; @@ -100,9 +103,6 @@ else "CHEYENNE") EXTRN_MDL_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; - "ORION") - EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" - ;; esac ;; @@ -111,11 +111,12 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_ICS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_ICS="/misc/whome/rtrr/rap" ;; -# This goes with the comment below for the if-statement (-z EXTRN_MDL_SYSBASEDIR_ICS). -# Should not need this case. "CHEYENNE") EXTRN_MDL_SYSBASEDIR_ICS="dummy_value" ;; @@ -127,6 +128,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_ICS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_ICS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_ICS="/misc/whome/rtrr/hrrr" ;; @@ -209,6 +213,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_LBCS="" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_LBCS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_LBCS="" ;; @@ -221,9 +228,6 @@ else "STAMPEDE") EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" ;; - "ORION") - EXTRN_MDL_SYSBASEDIR_LBCS="dummy_value" - ;; esac ;; @@ -238,6 +242,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_LBCS="/scratch1/NCEPDEV/rstprod/com/gfs/prod" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_LBCS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_LBCS="/public/data/grids/gfs/nemsio" ;; @@ -247,9 +254,6 @@ else "CHEYENNE") EXTRN_MDL_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; - "ORION") - EXTRN_MDL_SYSBASEDIR_LBCS="dummy_value" - ;; esac ;; @@ -258,6 +262,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/rap/full/wrfnat" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_LBCS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_LBCS="/misc/whome/rtrr/rap" ;; @@ -272,6 +279,9 @@ else "HERA") EXTRN_MDL_SYSBASEDIR_LBCS="/scratch2/BMC/public/data/gsd/hrrr/conus/wrfnat" ;; + "ORION") + EXTRN_MDL_SYSBASEDIR_LBCS="" + ;; "JET") EXTRN_MDL_SYSBASEDIR_LBCS="/misc/whome/rtrr/hrrr" ;; From e72f8d7af9665f8fa5a1303e3a90a01b1f3b0e3b Mon Sep 17 00:00:00 2001 From: David Wright Date: Sun, 11 Oct 2020 22:28:45 -0400 Subject: [PATCH 15/39] Feature to read in FVCOM lake surface conditions into FV3-LAM (#293) * Feature to read in FVCOM lake surface conditions to FV3-LAM Add feature to allow user to use data generated by FVCOM in FV3-LAM as initialization of lake surface properties over the Great Lakes. FVCOM data must be interpolated to FV3-LAM grid for this routine to work. Following additions were made: - Generated 3 new variables: USE_FVCOM, FVCOM_DIR, and FVCOM_FILE. These are user defined variables available in config.sh. USE_FVCOM: TRUE/FALSE flag to use FVCOM data FVCOM_DIR: Directory path for local FVCOM files FVCOM_FILE: Name of file (.nc) that contains FVCOM data - Added to exregional_make_ics.sh to run the fortran code to replace lake surface conditions with those in FVCOM_FILE. - Created sorc/fvcom_to_FV3 which contains fortran code to modify sfc_data.tile7.halo0.nc with new lake surface conditions. * Remove Fortran source code and put in UFS_UTILS PR * Change fvcom_to_FV3 to remove .exe file name extension Co-authored-by: David Wright --- scripts/exregional_make_ics.sh | 42 ++++++++++++++++++++++++++++++++++ ush/config_defaults.sh | 24 +++++++++++++++++++ ush/setup.sh | 33 ++++++++++++++++++++++++++ ush/valid_param_vals.sh | 1 + 4 files changed, 100 insertions(+) diff --git a/scripts/exregional_make_ics.sh b/scripts/exregional_make_ics.sh index 3cd3dfdf7..c89e458fe 100755 --- a/scripts/exregional_make_ics.sh +++ b/scripts/exregional_make_ics.sh @@ -611,6 +611,48 @@ mv_vrfy gfs.bndy.nc ${ics_dir}/gfs_bndy.tile${TILE_RGNL}.000.nc # #----------------------------------------------------------------------- # +# Process FVCOM Data +# +#----------------------------------------------------------------------- +# +if [ "${USE_FVCOM}" = "TRUE" ]; then + + fvcom_exec_fn="fvcom_to_FV3" + fvcom_exec_fp="$EXECDIR/${fvcom_exec_fn}" + if [ ! -f "${fvcom_exec_fp}" ]; then + print_err_msg_exit "\ +The executable (fvcom_exec_fp) for processing FVCOM data onto FV3-LAM +native grid does not exist: + fvcom_exec_fp = \"${fvcom_exec_fp}\" +Please ensure that you've built this executable." + fi + cp_vrfy ${fvcom_exec_fp} ${ics_dir}/. + fvcom_data_fp="${FVCOM_DIR}/${FVCOM_FILE}" + if [ ! -f "${fvcom_data_fp}" ]; then + print_err_msg_exit "\ +The file or path (fvcom_data_fp) does not exist: + fvcom_data_fp = \"${fvcom_data_fp}\" +Please check the following user defined variables: + FVCOM_DIR = \"${FVCOM_DIR}\" + FVCOM_FILE= \"${FVCOM_FILE}\" " + fi + + cp_vrfy ${fvcom_data_fp} ${ics_dir}/fvcom.nc + cd_vrfy ${ics_dir} + ${APRUN} ${fvcom_exec_fn} sfc_data.tile${TILE_RGNL}.halo${NH0}.nc fvcom.nc || \ + print_err_msg_exit "\ +Call to executable (fvcom_exe) to modify sfc fields for FV3-LAM failed: + fvcom_exe = \"${fvcom_exe}\" +The following variables were being used: + FVCOM_DIR = \"${FVCOM_DIR}\" + FVCOM_FILE = \"${FVCOM_FILE}\" + ics_dir = \"${ics_dir}\" + fvcom_exe_dir = \"${fvcom_exe_dir}\" + fvcom_exe = \"${fvcom_exe}\"" +fi +# +#----------------------------------------------------------------------- +# # Print message indicating successful completion of script. # #----------------------------------------------------------------------- diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index 7ce18a4d6..a80bff088 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -1277,3 +1277,27 @@ HALO_BLEND=0 #----------------------------------------------------------------------- # GWD_RRFS_v1beta_BASEDIR="" +# +#----------------------------------------------------------------------- +# +# USE_FVCOM: +# Flag set to update surface conditions in FV3-LAM with fields generated +# from the Finite Volume Community Ocean Model (FVCOM). This will +# replace lake/sea surface temperature, ice surface temperature, and ice +# placement. FVCOM data must already be interpolated to the desired +# FV3-LAM grid. This flag will be used in make_ics to modify sfc_data.nc +# after chgres_cube is run by running the routine process_FVCOM.exe +# +# FVCOM_DIR: +# User defined directory where FVCOM data already interpolated to FV3-LAM +# grid is located. File name in this path should be "fvcom.nc" to allow +# +# FVCOM_FILE: +# Name of file located in FVCOM_DIR that has FVCOM data interpolated to +# FV3-LAM grid. This file will be copied later to a new location and name +# changed to fvcom.nc +#------------------------------------------------------------------------ +# +USE_FVCOM="FALSE" +FVCOM_DIR="/user/defined/dir/to/fvcom/data" +FVCOM_FILE="fvcom.nc" diff --git a/ush/setup.sh b/ush/setup.sh index 20a6f49c4..d55b90d7d 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -310,6 +310,27 @@ if [ "${DO_SPPT}" = "FALSE" ]; then SPPT_MAG=-999.0 fi +# +#----------------------------------------------------------------------- +# +# Make sure that USE_FVCOM is set to a valid value and assign directory +# and file names. +# +#----------------------------------------------------------------------- +# +check_var_valid_value "USE_FVCOM" "valid_vals_USE_FVCOM" +# +# Set USE_FVCOM to either "TRUE" or "FALSE" so we don't have to consider +# other valid values later on. +# +USE_FVCOM=${USE_FVCOM^^} +if [ "$USE_FVCOM" = "TRUE" ] || \ + [ "$USE_FVCOM" = "YES" ]; then + USE_FVCOM="TRUE" +elif [ "$USE_FVCOM" = "FALSE" ] || \ + [ "$USE_FVCOM" = "NO" ]; then + USE_FVCOM="FALSE" +fi # #----------------------------------------------------------------------- # @@ -2813,6 +2834,18 @@ $( printf "\"%s\" \\\\\n" "${ALL_CDATES[@]}" ) # #----------------------------------------------------------------------- # +# If USE_FVCOM is set to TRUE, then FVCOM data (located in FVCOM_DIR +# in FVCOM_FILE) will be used to update lower boundary conditions during +# make_ics. +# +#----------------------------------------------------------------------- +# +USE_FVCOM="${USE_FVCOM}" +FVCOM_DIR="${FVCOM_DIR}" +FVCOM_FILE="${FVCOM_FILE}" +# +#----------------------------------------------------------------------- +# # Computational parameters. # #----------------------------------------------------------------------- diff --git a/ush/valid_param_vals.sh b/ush/valid_param_vals.sh index be3d8c177..f7590e0dd 100644 --- a/ush/valid_param_vals.sh +++ b/ush/valid_param_vals.sh @@ -74,3 +74,4 @@ valid_vals_DO_SHUM=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") valid_vals_DO_SPPT=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") valid_vals_DO_SKEB=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") valid_vals_USE_ZMTNBLCK=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") +valid_vals_USE_FVCOM=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") From 52b49f1facd9eff97269c0750f43233995946735 Mon Sep 17 00:00:00 2001 From: JeffBeck-NOAA <55201531+JeffBeck-NOAA@users.noreply.github.com> Date: Tue, 13 Oct 2020 12:28:06 -0600 Subject: [PATCH 16/39] Add NOMADS script call back into generate script. (#311) * Add NOMADS data script call back into generate script. * Change location of NOMADS script call --- ush/generate_FV3LAM_wflow.sh | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 489a2b536..daad082e3 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -631,8 +631,6 @@ Copying the FV3-LAM executable (exec_fp) to the executables directory EXECDIR = \"$EXECDIR\"" cp_vrfy "${exec_fp}" "${FV3_EXEC_FP}" fi - - # #----------------------------------------------------------------------- # @@ -669,7 +667,7 @@ if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ print_err_msg_exit "\ The value to set the variable lsoil to in the FV3 namelist file (FV3_NML_FP) has not been specified for the following combination of physics suite and -external models for ICs and LBCs: +external model ICs: CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\" EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\" Please change one or more of these parameters or provide a value for lsoil @@ -950,6 +948,15 @@ edit the cron table): Done. " # +# If necessary, run the NOMADS script to source external model data. +# +if [ "${NOMADS}" = "TRUE" ]; then + echo "Getting NOMADS online data" + echo "NOMADS_file_type=" $NOMADS_file_type + cd $EXPTDIR + $USHDIR/NOMADS_get_extrn_mdl_files.sh $DATE_FIRST_CYCL $CYCL_HRS $NOMADS_file_type $FCST_LEN_HRS $LBC_SPEC_INTVL_HRS +fi +# #----------------------------------------------------------------------- # # Restore the shell options saved at the beginning of this script/func- @@ -960,10 +967,6 @@ Done. { restore_shell_opts; } > /dev/null 2>&1 } - - - - # #----------------------------------------------------------------------- # @@ -1060,6 +1063,3 @@ Stopping. " exit 1 fi - - - From ea5192b295524def194fb317eccbc6d4d5f79dff Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 13 Oct 2020 16:02:26 -0500 Subject: [PATCH 17/39] Modifications to more easily specify slurm partitions. * Remove the workflow variables QUEUE_DEFAULT_TAG, QUEUE_HPSS_TAG, and QUEUE_FCST_TAG which are currently used to determine whether QUEUE_DEFAULT, QUEUE_HPSS, and QUEUE_FCST specify the names of queue/QOS's or slurm partitions. * Add the workflow variables PARTITION_DEFAULT_TAG, PARTITION_HPSS_TAG, and PARTITION_FCST_TAG. These will be used to specify slurm partitions only, and the variables QUEUE_DEFAULT, QUEUE_HPSS, and QUEUE_FCST will be used to specify queues/QOS's only. --- ush/config_defaults.sh | 81 +++++++++++++++++++++++----------- ush/generate_FV3LAM_wflow.sh | 38 ++++++++++++++-- ush/setup.sh | 67 +++++++++++++++++++++++++--- ush/templates/FV3LAM_wflow.xml | 9 ++-- 4 files changed, 154 insertions(+), 41 deletions(-) diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index 87f25e4ae..30f6bd32c 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -52,35 +52,62 @@ RUN_ENVIR="nco" # machine. # # QUEUE_DEFAULT: -# The default queue to which workflow tasks are submitted. If a task -# does not have a specific variable that specifies the queue to which it -# will be submitted (e.g. QUEUE_HPSS, QUEUE_FCST; see below), it will be -# submitted to the queue specified by this variable. If this is not set -# or is set to an empty string, it will be (re)set to a machine-dependent -# value. +# The default queue or QOS (if using the slurm job scheduler, where QOS +# is Quality of Service) to which workflow tasks are submitted. If a +# task does not have a specific variable that specifies the queue to which +# it will be submitted (e.g. QUEUE_HPSS, QUEUE_FCST; see below), it will +# be submitted to the queue specified by this variable. If this is not +# set or is set to an empty string, it will be (re)set to a machine- +# dependent value. # -# QUEUE_DEFAULT_TAG: -# The rocoto xml tag to use for specifying the default queue. For most -# platforms this should be "queue" +## QUEUE_DEFAULT_TAG: +## The rocoto xml tag to use for specifying the default queue. For most +## platforms this should be "queue" # # QUEUE_HPSS: -# The queue to which the tasks that get or create links to external model -# files [which are needed to generate initial conditions (ICs) and lateral -# boundary conditions (LBCs)] are submitted. If this is not set or is -# set to an empty string, it will be (re)set to a machine-dependent value. +# The queue or QOS to which the tasks that get or create links to external +# model files [which are needed to generate initial conditions (ICs) and +# lateral boundary conditions (LBCs)] are submitted. If this is not set +# or is set to an empty string, it will be (re)set to a machine-dependent +# value. # -# QUEUE_HPSS_TAG: -# The rocoto xml tag to use for specifying the HPSS queue. For slurm-based -# platforms this is typically "partition", for others it may be "queue" +## QUEUE_HPSS_TAG: +## The rocoto xml tag to use for specifying the HPSS queue. For slurm-based +## platforms this is typically "partition", for others it may be "queue" # # QUEUE_FCST: -# The queue to which the task that runs a forecast is submitted. If this -# is not set or set to an empty string, it will be (re)set to a machine- -# dependent value. +# The queue or QOS to which the task that runs a forecast is submitted. +# If this is not set or set to an empty string, it will be (re)set to a +# machine-dependent value. +# +## QUEUE_FCST_TAG: +## The rocoto xml tag to use for specifying the fcst queue. For most +## platforms this should be "queue" +# +# PARTITION_DEFAULT: +# If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), +# the default partition to which to submit workflow tasks. If a task +# does not have a specific variable that specifies the partition to which +# it will be submitted (e.g. PARTITION_HPSS, PARTITION_FCST; see below), +# it will be submitted to the partition specified by this variable. If +# this is not set or is set to an empty string, it will be (re)set to a +# machine-dependent value. This is not used if SCHED is not set to +# "slurm". +# +# PARTITION_HPSS: +# If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), +# the partition to which the tasks that get or create links to external +# model files [which are needed to generate initial conditions (ICs) and +# lateral boundary conditions (LBCs)] are submitted. If this is not set +# or is set to an empty string, it will be (re)set to a machine-dependent +# value. This is not used if SCHED is not set to "slurm". # -# QUEUE_FCST_TAG: -# The rocoto xml tag to use for specifying the fcst queue. For most -# platforms this should be "queue" +# PARTITION_FCST: +# If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), +# the partition to which the task that runs forecasts is submitted. If +# this is not set or set to an empty string, it will be (re)set to a +# machine-dependent value. This is not used if SCHED is not set to +# "slurm". # # mach_doc_end # @@ -90,11 +117,15 @@ MACHINE="BIG_COMPUTER" ACCOUNT="project_name" SCHED="" QUEUE_DEFAULT="" -QUEUE_DEFAULT_TAG="queue" +#QUEUE_DEFAULT_TAG="queue" QUEUE_HPSS="" -QUEUE_HPSS_TAG="partition" +#QUEUE_HPSS_TAG="partition" QUEUE_FCST="" -QUEUE_FCST_TAG="queue" +#QUEUE_FCST_TAG="queue" + +PARTITION_DEFAULT="" +PARTITION_HPSS="" +PARTITION_FCST="" # #----------------------------------------------------------------------- # diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 0244cd7cd..c400cfd76 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -159,6 +159,37 @@ if [ "${DO_ENSEMBLE}" = "TRUE" ]; then slash_ensmem_subdir="/mem#${ensmem_indx_name}#" fi +# +# To see if the following is enough (i.e. to see whether the if-statements +# below are really needed), have to run with the following lines uncommented +# on systems that don't use slurm. +# The following seem to work ok on orion, i.e. passing an empty partition +# setting in the rocoto xml, like this: +# This causes rocoto/slurm to submit to the default partition (called "orion"). +# +#partition_default_spec="${PARTITION_DEFAULT}" +#partition_hpss_spec="${PARTITION_HPSS}" +#partition_fcst_spec="${PARTITION_FCST}" + +partition_default_spec="\"\"" +if [ ! -z "${PARTITION_DEFAULT}" ]; then + partition_default_spec="${PARTITION_DEFAULT}" +fi + +partition_hpss_spec="\"\"" +if [ ! -z "${PARTITION_HPSS}" ]; then + partition_hpss_spec="${PARTITION_HPSS}" +fi + +partition_fcst_spec="\"\"" +if [ ! -z "${PARTITION_FCST}" ]; then + partition_fcst_spec="${PARTITION_FCST}" +fi + +# 'queue_default_tag': ${QUEUE_DEFAULT_TAG} +# 'queue_hpss_tag': ${QUEUE_HPSS_TAG} +# 'queue_fcst_tag': ${QUEUE_FCST_TAG} + settings="\ # # Parameters needed by the job scheduler. @@ -166,11 +197,11 @@ settings="\ 'account': $ACCOUNT 'sched': $SCHED 'queue_default': ${QUEUE_DEFAULT} - 'queue_default_tag': ${QUEUE_DEFAULT_TAG} 'queue_hpss': ${QUEUE_HPSS} - 'queue_hpss_tag': ${QUEUE_HPSS_TAG} 'queue_fcst': ${QUEUE_FCST} - 'queue_fcst_tag': ${QUEUE_FCST_TAG} + 'partition_default_spec': ${partition_default_spec} + 'partition_hpss_spec': ${partition_hpss_spec} + 'partition_fcst_spec': ${partition_fcst_spec} 'machine': ${MACHINE} # # Workflow task names. @@ -201,7 +232,6 @@ settings="\ # 'ncores_run_fcst': ${PE_MEMBER01} 'native_run_fcst': --cpus-per-task 4 --exclusive - 'partition_run_fcst': sjet,vjet,kjet,xjet # # Number of logical processes per node for each task. If running without # threading, this is equal to the number of MPI processes per node. diff --git a/ush/setup.sh b/ush/setup.sh index 51ce38c6f..7938597be 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -344,7 +344,7 @@ case $MACHINE in SCHED="lsfcray" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} - QUEUE_HPSS_TAG="queue" # lsfcray does not support "partition" tag +# QUEUE_HPSS_TAG="queue" # lsfcray does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"dev"} ;; @@ -353,31 +353,52 @@ case $MACHINE in SCHED="lsf" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} - QUEUE_HPSS_TAG="queue" # lsf does not support "partition" tag +# QUEUE_HPSS_TAG="queue" # lsf does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"dev"} ;; "HERA") - NCORES_PER_NODE=24 # Should this be 40? Need to check heradocs. + NCORES_PER_NODE=40 SCHED="${SCHED:-slurm}" + + PARTITION_DEFAULT=${PARTITION_DEFAULT:-"hera"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + + PARTITION_HPSS=${PARTITION_HPSS:-"service"} QUEUE_HPSS=${QUEUE_HPSS:-"service"} +# QUEUE_HPSS_TAG="queue" + + PARTITION_FCST=${PARTITION_FCST:-"hera"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; "ORION") NCORES_PER_NODE=40 SCHED="${SCHED:-slurm}" + +# PARTITION_DEFAULT=${PARTITION_DEFAULT:-"orion"} + PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} + + PARTITION_HPSS=${PARTITION_HPSS:-"service"} + QUEUE_HPSS=${QUEUE_HPSS:-"batch"} +# QUEUE_HPSS_TAG="queue" + + PARTITION_FCST=${PARTITION_FCST:-"orion"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; "JET") NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" + + PARTITION_DEFAULT=${PARTITION_DEFAULT:-"sjet,vjet,kjet,xjet"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} + + PARTITION_HPSS=${PARTITION_HPSS:-"service"} QUEUE_HPSS=${QUEUE_HPSS:-"service"} + + PARTITION_FCST=${PARTITION_FCST:-"sjet,vjet,kjet,xjet"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; @@ -394,7 +415,7 @@ case $MACHINE in SCHED="${SCHED:-pbspro}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"regular"} QUEUE_HPSS=${QUEUE_HPSS:-"regular"} - QUEUE_HPSS_TAG="queue" # pbspro does not support "partition" tag +# QUEUE_HPSS_TAG="queue" # pbspro does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"regular"} ;; @@ -407,6 +428,40 @@ case $MACHINE in ;; esac + + +# Is the following needed??? +# +#if [ "$SCHED" = "slurm" ]; then +# +# if [ -z "${PARTITION_DEFAULT}" ]; then +# print_err_msg_exit "\ +#When SCHED is set to \"slurm\", the variable specifying the default +#slurm partition to which to submit tasks (PARTITION_DEFAULT) cannot be +#empty: +# SCHED = \"$SCHED\" +# PARTITION_DEFAULT = \"${PARTITION_DEFAULT}\"" +# fi +# +# if [ -z "${PARTITION_HPSS}" ]; then +# print_err_msg_exit "\ +#When SCHED is set to \"slurm\", the variable specifying the slurm +#partition to which to submit the tasks that fetch/copy external model +#files (PARTITION_HPSS) cannot be empty: +# SCHED = \"$SCHED\" +# PARTITION_HPSS = \"${PARTITION_HPSS}\"" +# fi +# +# if [ -z "${PARTITION_FCST}" ]; then +# print_err_msg_exit "\ +#When SCHED is set to \"slurm\", the variable specifying the slurm +#partition to which to submit the forecast task (PARTITION_FCST) cannot +#be empty: +# SCHED = \"$SCHED\" +# PARTITION_DEFAULT = \"${PARTITION_FCST}\"" +# fi +# +#fi # #----------------------------------------------------------------------- # @@ -749,7 +804,7 @@ case $MACHINE in "ORION") FIXgsm=${FIXgsm:-"/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/fix_orog"} + TOPO_DIR=${TOPO_DIR:-"/work/noaa/fv3-cam/emc.campara/fix_fv3cam/fix_orog"} SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/work/noaa/gsd-fv3-dev/gsketefia/UFS/climo_fields_netcdf"} ;; diff --git a/ush/templates/FV3LAM_wflow.xml b/ush/templates/FV3LAM_wflow.xml index 4fbc7ae05..c0343f3aa 100644 --- a/ush/templates/FV3LAM_wflow.xml +++ b/ush/templates/FV3LAM_wflow.xml @@ -63,9 +63,9 @@ tasks other than GET_EXTRN_ICS_TN, GET_EXTRN_LBCS_TN, and RUN_FCST_TN; the "HPSS" type is used for the GET_EXTRN_ICS_TN and GET_EXTRN_LBCS_TN tasks; and the "FCST" type is used for the RUN_FCST_TN task. --> -&ACCOUNT;<{{ queue_default_tag }}>&QUEUE_DEFAULT;"> -&ACCOUNT;<{{ queue_hpss_tag }}>&QUEUE_HPSS;"> -&ACCOUNT;<{{ queue_fcst_tag }}>&QUEUE_FCST;"> +&ACCOUNT;&QUEUE_DEFAULT;{{ partition_default_spec }}"> +&ACCOUNT;&QUEUE_HPSS;{{ partition_hpss_spec }}"> +&ACCOUNT;&QUEUE_FCST;{{ partition_fcst_spec }}"> ]> @@ -343,9 +343,6 @@ MODULES_RUN_TASK_FP script. {% if machine in ["JET", "HERA"] %} {{ ncores_run_fcst }} {{ native_run_fcst }} - {% if machine == "JET" %} - {{ partition_run_fcst }} - {% endif %} {% else %} {{ nnodes_run_fcst }}:ppn={{ ppn_run_fcst }} &NCORES_PER_NODE; From a94a89e2965fba200fb3976592532b9d6721a8d9 Mon Sep 17 00:00:00 2001 From: Yunheng Wang <47898913+ywangwof@users.noreply.github.com> Date: Tue, 13 Oct 2020 16:21:44 -0500 Subject: [PATCH 18/39] Wrapped global_equiv_resol exec_fp with APRUN just as other commands do and inserted CASE statements for Stampede (#303) --- scripts/exregional_make_grid.sh | 2 +- ush/get_extrn_mdl_file_dir_info.sh | 3 +++ ush/set_extrn_mdl_params.sh | 6 ++++++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index c7b850005..13276835e 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -429,7 +429,7 @@ cubed-sphere grid equivalent resolution does not exist: Please ensure that you've built this executable." fi -${exec_fp} "${grid_fp}" || \ +$APRUN ${exec_fp} "${grid_fp}" || \ print_err_msg_exit "\ Call to executable (exec_fp) that calculates the regional grid's global uniform cubed-sphere grid equivalent resolution returned with nonzero exit diff --git a/ush/get_extrn_mdl_file_dir_info.sh b/ush/get_extrn_mdl_file_dir_info.sh index ae1300634..47c42cea6 100755 --- a/ush/get_extrn_mdl_file_dir_info.sh +++ b/ush/get_extrn_mdl_file_dir_info.sh @@ -603,6 +603,9 @@ has not been specified for this external model and machine combination: "CHEYENNE") sysdir="$sysbasedir/gfs.${yyyymmdd}/${hh}" ;; + "STAMPEDE") + sysdir="$sysbasedir" + ;; *) print_err_msg_exit "\ The system directory in which to look for external model output files diff --git a/ush/set_extrn_mdl_params.sh b/ush/set_extrn_mdl_params.sh index 02fbbbf00..7a5b8104d 100644 --- a/ush/set_extrn_mdl_params.sh +++ b/ush/set_extrn_mdl_params.sh @@ -95,6 +95,9 @@ else "ODIN") EXTRN_MDL_SYSBASEDIR_ICS="/scratch/ywang/test_runs/FV3_regional/gfs" ;; + "STAMPEDE") + EXTRN_MDL_SYSBASEDIR_ICS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" + ;; "CHEYENNE") EXTRN_MDL_SYSBASEDIR_ICS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; @@ -240,6 +243,9 @@ else "CHEYENNE") EXTRN_MDL_SYSBASEDIR_LBCS="/glade/p/ral/jntp/UFS_CAM/COMGFS" ;; + "STAMPEDE") + EXTRN_MDL_SYSBASEDIR_LBCS="/scratch/00315/tg455890/GDAS/20190530/2019053000_mem001" + ;; esac ;; From 3d6e1df5203a6ef7f193e43af85ff21f3f8c88a6 Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Tue, 13 Oct 2020 15:31:52 -0600 Subject: [PATCH 19/39] Remove the USE_CCPP variable (#308) ## DESCRIPTION OF CHANGES: This PR removes the USE_CCPP variable from all scripts and other files. The workflow only supports running the FV3 model with CCPP, so USE_CCPP is deprecated. ## TESTS CONDUCTED: Ran one WE2E test (regional_002) on hera. Succeeded. ## ISSUE (optional): This resolves Issue #196. --- scripts/exregional_make_ics.sh | 75 +++++++++--------- scripts/exregional_run_fcst.sh | 15 ++-- .../baseline_configs/config.DOT_OR_USCORE.sh | 1 - .../config.community_ensemble_008mems.sh | 1 - .../config.community_ensemble_2mems.sh | 1 - ...get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh | 1 - ...get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh | 1 - ...ig.get_extrn_files_from_hpss_HRRRX_RAPX.sh | 1 - ...fig.get_extrn_files_from_hpss_RAPX_RAPX.sh | 1 - ....grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh | 1 - ...g.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh | 1 - .../config.grid_GSD_HRRR_AK_50km.sh | 1 - .../config.grid_GSD_RAP13km.sh | 1 - .../config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh | 1 - .../config.grid_RRFS_AK_13km_RAPX_RAPX.sh | 1 - .../config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh | 1 - .../config.grid_RRFS_AK_3km_RAPX_RAPX.sh | 1 - ...nfig.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh | 1 - .../config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh | 1 - ...nfig.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh | 1 - .../config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh | 1 - ...onfig.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh | 1 - .../config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh | 1 - ...ig.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh | 1 - ...onfig.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh | 1 - .../config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh | 1 - ...config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh | 1 - .../config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh | 1 - ...config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh | 1 - tests/baseline_configs/config.nco_conus.sh | 1 - .../baseline_configs/config.nco_conus_c96.sh | 1 - ...co_conus_c96__suite_FV3_GFS_2017_gfdlmp.sh | 1 - tests/baseline_configs/config.nco_ensemble.sh | 1 - tests/baseline_configs/config.new_ESGgrid.sh | 1 - tests/baseline_configs/config.new_GFDLgrid.sh | 1 - ..._USE_GFDLgrid_RES_IN_FILENAMES_eq_FALSE.sh | 1 - ...d_USE_GFDLgrid_RES_IN_FILENAMES_eq_TRUE.sh | 1 - .../config.pregen_grid_orog_sfc_climo.sh | 1 - tests/baseline_configs/config.regional_001.sh | 1 - tests/baseline_configs/config.regional_002.sh | 1 - .../config.suite_FV3_CPT_v0.sh | 1 - .../config.suite_FV3_GFS_v15p2.sh | 1 - .../config.suite_FV3_GFS_v16beta.sh | 1 - .../config.suite_FV3_GSD_SAR.sh | 1 - .../config.suite_FV3_GSD_v0.sh | 1 - .../config.suite_FV3_RRFS_v1beta.sh | 1 - .../config.user_download_extrn_files.sh | 1 - tests/baselines_list.txt | 15 +++- ush/config.community.sh | 1 - ush/config.nco.sh | 1 - ush/config_defaults.sh | 32 ++------ ush/generate_FV3LAM_wflow.sh | 39 +++------- ush/load_modules_run_task.sh | 14 ---- ush/set_ozone_param.sh | 23 ++---- ush/setup.sh | 77 ++++--------------- ush/valid_param_vals.sh | 2 - 56 files changed, 93 insertions(+), 246 deletions(-) diff --git a/scripts/exregional_make_ics.sh b/scripts/exregional_make_ics.sh index c89e458fe..04cc14652 100755 --- a/scripts/exregional_make_ics.sh +++ b/scripts/exregional_make_ics.sh @@ -352,21 +352,19 @@ case "${EXTRN_MDL_NAME_ICS}" in fn_grib2="${EXTRN_MDL_FNS[0]}" input_type="grib2" # -# Set soil levels based on LSM in CCPP SDF (RUC-LSM or Noah/Noah MP) +# Set soil levels based on LSM in CCPP SDF (RUC-LSM or Noah/Noah MP). # - if [ "${USE_CCPP}" = "TRUE" ]; then - if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then - nsoill_out="4" - elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - nsoill_out="9" - fi + if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then + nsoill_out="4" + elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + nsoill_out="9" fi # # These geogrid files need to be moved to more permanent locations. @@ -397,20 +395,18 @@ case "${EXTRN_MDL_NAME_ICS}" in fn_grib2="${EXTRN_MDL_FNS[0]}" input_type="grib2" # -# Set soil levels based on CCPP SDF +# Set soil levels based on CCPP SDF. # - if [ "${USE_CCPP}" = "TRUE" ]; then - if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then - nsoill_out="4" - elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - nsoill_out="9" - fi + if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then + nsoill_out="4" + elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + nsoill_out="9" fi # # These geogrid files need to be moved to more permanent locations. @@ -441,20 +437,19 @@ case "${EXTRN_MDL_NAME_ICS}" in input_type="grib2" # -# Use Thompson climatology for ice- and water-friendly aerosols if CCPP suite uses Thompson MP +# Use Thompson climatology for ice- and water-friendly aerosols if CCPP +# suite uses Thompson MP # - if [ "${USE_CCPP}" = "TRUE" ]; then - if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then - thomp_mp_climo_file="" - elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - thomp_mp_climo_file="${FIXam}/Thompson_MP_MONTHLY_CLIMO.nc" - fi + if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_CPT_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v15p2" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_v16beta" ]; then + thomp_mp_climo_file="" + elif [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + thomp_mp_climo_file="${FIXam}/Thompson_MP_MONTHLY_CLIMO.nc" fi nsoill_out="4" #If the CCPP suites uses RUC-LSM, the scheme will interpolate from 4 to 9 soil levels. diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 75bf3588a..2168b985f 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -437,16 +437,11 @@ else ln_vrfy -sf ${relative_or_null} ${FV3_NML_FP} ${run_dir} fi -if [ "${USE_CCPP}" = "TRUE" ]; then - - ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} - - if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - ln_vrfy -sf ${relative_or_null} $EXPTDIR/CCN_ACTIVATE.BIN ${run_dir} - fi - +ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} +if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + ln_vrfy -sf ${relative_or_null} $EXPTDIR/CCN_ACTIVATE.BIN ${run_dir} fi # #----------------------------------------------------------------------- diff --git a/tests/baseline_configs/config.DOT_OR_USCORE.sh b/tests/baseline_configs/config.DOT_OR_USCORE.sh index 0b7c202c6..2f80f2bef 100644 --- a/tests/baseline_configs/config.DOT_OR_USCORE.sh +++ b/tests/baseline_configs/config.DOT_OR_USCORE.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.community_ensemble_008mems.sh b/tests/baseline_configs/config.community_ensemble_008mems.sh index a0a75a139..8a4068f44 100644 --- a/tests/baseline_configs/config.community_ensemble_008mems.sh +++ b/tests/baseline_configs/config.community_ensemble_008mems.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.community_ensemble_2mems.sh b/tests/baseline_configs/config.community_ensemble_2mems.sh index 00450be06..6032fca71 100644 --- a/tests/baseline_configs/config.community_ensemble_2mems.sh +++ b/tests/baseline_configs/config.community_ensemble_2mems.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh index c0d56966d..4acc7545e 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh index 1fbf5962c..904b899b0 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_GSMGFS_GSMGFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh index 5e786809a..a5ead9f08 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh b/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh index 393c8bc0b..1e32f3d03 100644 --- a/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh +++ b/tests/baseline_configs/config.get_extrn_files_from_hpss_RAPX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh index 0d0b0e736..d4e014c3c 100644 --- a/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="CONUS_25km_GFDLgrid" GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh index c41026343..39a39cb82 100644 --- a/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="CONUS_3km_GFDLgrid" GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_GSD_HRRR_AK_50km.sh b/tests/baseline_configs/config.grid_GSD_HRRR_AK_50km.sh index b6a041892..204884dc1 100644 --- a/tests/baseline_configs/config.grid_GSD_HRRR_AK_50km.sh +++ b/tests/baseline_configs/config.grid_GSD_HRRR_AK_50km.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="GSD_HRRR_AK_50km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_GSD_RAP13km.sh b/tests/baseline_configs/config.grid_GSD_RAP13km.sh index a565e3aae..f46a8f895 100644 --- a/tests/baseline_configs/config.grid_GSD_RAP13km.sh +++ b/tests/baseline_configs/config.grid_GSD_RAP13km.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="GSD_RAP13km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_v0" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh index 57da4b332..f15dbf8cf 100644 --- a/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_AK_13km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_AK_13km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh index 630271e55..f3d92e400 100644 --- a/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_AK_13km_RAPX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_AK_13km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh index 02e9f97ee..02ebccb82 100644 --- a/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_AK_3km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_AK_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh index c3cb06e8f..6bed997f4 100644 --- a/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_AK_3km_RAPX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_AK_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh index b30f7f457..81f6bbbe0 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_13km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh index e5e302975..fc450b49f 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_13km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh index 68511e5cb..35162b55d 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh index 4047e11fd..41cf5423c 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh index 15d70793c..171db735f 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh index 751172472..d46c101fd 100644 --- a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh index 68c1a1581..faf2d1992 100644 --- a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_SUBCONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh index 85ed27905..75b19fee7 100644 --- a/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.grid_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_SUBCONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="3" diff --git a/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh index 4e28b83af..c7248904e 100644 --- a/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_25km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh index 0bd17e582..b58db4315 100644 --- a/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp_regional" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh index 523194b41..d39e689d3 100644 --- a/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_CONUS_3km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="RRFS_CONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh index 1bb952e72..f0cb3da8a 100644 --- a/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh +++ b/tests/baseline_configs/config.nco_RRFS_SUBCONUS_3km_HRRRX_RAPX.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="RRFS_SUBCONUS_3km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_conus.sh b/tests/baseline_configs/config.nco_conus.sh index 54549494e..dba68fead 100644 --- a/tests/baseline_configs/config.nco_conus.sh +++ b/tests/baseline_configs/config.nco_conus.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="conus" # This maps to PREDEF_GRID_NAME="EMC_CONUS_3km". GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp_regional" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_conus_c96.sh b/tests/baseline_configs/config.nco_conus_c96.sh index b0b82f1e0..5f3f58bca 100644 --- a/tests/baseline_configs/config.nco_conus_c96.sh +++ b/tests/baseline_configs/config.nco_conus_c96.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="conus_c96" # This maps to PREDEF_GRID_NAME="EMC_CONUS_coarse". GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp_regional" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_conus_c96__suite_FV3_GFS_2017_gfdlmp.sh b/tests/baseline_configs/config.nco_conus_c96__suite_FV3_GFS_2017_gfdlmp.sh index 5534594aa..2b1f1ec03 100644 --- a/tests/baseline_configs/config.nco_conus_c96__suite_FV3_GFS_2017_gfdlmp.sh +++ b/tests/baseline_configs/config.nco_conus_c96__suite_FV3_GFS_2017_gfdlmp.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="conus_c96" # This maps to PREDEF_GRID_NAME="EMC_CONUS_coarse". GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.nco_ensemble.sh b/tests/baseline_configs/config.nco_ensemble.sh index 9464a4899..83c9188c7 100644 --- a/tests/baseline_configs/config.nco_ensemble.sh +++ b/tests/baseline_configs/config.nco_ensemble.sh @@ -5,7 +5,6 @@ EMC_GRID_NAME="conus_c96" # This maps to PREDEF_GRID_NAME="EMC_CONUS_coarse". GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp_regional" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.new_ESGgrid.sh b/tests/baseline_configs/config.new_ESGgrid.sh index a62c4010d..45c315172 100644 --- a/tests/baseline_configs/config.new_ESGgrid.sh +++ b/tests/baseline_configs/config.new_ESGgrid.sh @@ -35,7 +35,6 @@ WRTCMP_lat_lwr_left="22.41403305" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp_regional" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.new_GFDLgrid.sh b/tests/baseline_configs/config.new_GFDLgrid.sh index d712cf2df..3cc8b620e 100644 --- a/tests/baseline_configs/config.new_GFDLgrid.sh +++ b/tests/baseline_configs/config.new_GFDLgrid.sh @@ -52,7 +52,6 @@ if [ "$QUILTING" = "TRUE" ]; then WRTCMP_dlat="0.24" fi -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_FALSE.sh b/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_FALSE.sh index 134325580..f6bd589e4 100644 --- a/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_FALSE.sh +++ b/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_FALSE.sh @@ -50,7 +50,6 @@ if [ "$QUILTING" = "TRUE" ]; then WRTCMP_dlat="0.24" fi -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_TRUE.sh b/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_TRUE.sh index 57f64337a..ee7e3144a 100644 --- a/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_TRUE.sh +++ b/tests/baseline_configs/config.new_GFDLgrid__GFDLgrid_USE_GFDLgrid_RES_IN_FILENAMES_eq_TRUE.sh @@ -50,7 +50,6 @@ if [ "$QUILTING" = "TRUE" ]; then WRTCMP_dlat="0.24" fi -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh b/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh index e08418601..225a60b3e 100644 --- a/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh +++ b/tests/baseline_configs/config.pregen_grid_orog_sfc_climo.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.regional_001.sh b/tests/baseline_configs/config.regional_001.sh index 4f6c92ceb..d58093fb1 100644 --- a/tests/baseline_configs/config.regional_001.sh +++ b/tests/baseline_configs/config.regional_001.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.regional_002.sh b/tests/baseline_configs/config.regional_002.sh index 678975ecc..d93294178 100644 --- a/tests/baseline_configs/config.regional_002.sh +++ b/tests/baseline_configs/config.regional_002.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_CPT_v0.sh b/tests/baseline_configs/config.suite_FV3_CPT_v0.sh index d23e50841..5746ca00f 100644 --- a/tests/baseline_configs/config.suite_FV3_CPT_v0.sh +++ b/tests/baseline_configs/config.suite_FV3_CPT_v0.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_CPT_v0" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh b/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh index 692db567c..03b1d6e98 100644 --- a/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh +++ b/tests/baseline_configs/config.suite_FV3_GFS_v15p2.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v15p2" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh b/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh index 554b8a727..39a1217f1 100644 --- a/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh +++ b/tests/baseline_configs/config.suite_FV3_GFS_v16beta.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_v16beta" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh b/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh index 613d1b786..fa8783a80 100644 --- a/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh +++ b/tests/baseline_configs/config.suite_FV3_GSD_SAR.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_SAR" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_GSD_v0.sh b/tests/baseline_configs/config.suite_FV3_GSD_v0.sh index 9193847fe..e8bee0888 100644 --- a/tests/baseline_configs/config.suite_FV3_GSD_v0.sh +++ b/tests/baseline_configs/config.suite_FV3_GSD_v0.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GSD_v0" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh b/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh index 63b2d6404..90a1aad41 100644 --- a/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh +++ b/tests/baseline_configs/config.suite_FV3_RRFS_v1beta.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_RRFS_v1beta" FCST_LEN_HRS="06" diff --git a/tests/baseline_configs/config.user_download_extrn_files.sh b/tests/baseline_configs/config.user_download_extrn_files.sh index 3a1b32819..5c0049d08 100644 --- a/tests/baseline_configs/config.user_download_extrn_files.sh +++ b/tests/baseline_configs/config.user_download_extrn_files.sh @@ -5,7 +5,6 @@ PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" diff --git a/tests/baselines_list.txt b/tests/baselines_list.txt index 7946d6aa0..9c2297087 100644 --- a/tests/baselines_list.txt +++ b/tests/baselines_list.txt @@ -5,9 +5,22 @@ get_extrn_files_from_hpss_FV3GFS_FV3GFS get_extrn_files_from_hpss_GSMGFS_GSMGFS get_extrn_files_from_hpss_HRRRX_RAPX get_extrn_files_from_hpss_RAPX_RAPX +grid_CONUS_25km_GFDLgrid_FV3GFS_FV3GFS +grid_CONUS_3km_GFDLgrid_FV3GFS_FV3GFS grid_GSD_HRRR_AK_50km -grid_RRFS_CONUS_13km grid_GSD_RAP13km +grid_RRFS_AK_13km_FV3GFS_FV3GFS +grid_RRFS_AK_13km_RAPX_RAPX +grid_RRFS_AK_3km_FV3GFS_FV3GFS +grid_RRFS_AK_3km_RAPX_RAPX +grid_RRFS_CONUS_13km_FV3GFS_FV3GFS +grid_RRFS_CONUS_13km_HRRRX_RAPX +grid_RRFS_CONUS_25km_FV3GFS_FV3GFS +grid_RRFS_CONUS_25km_HRRRX_RAPX +grid_RRFS_CONUS_3km_FV3GFS_FV3GFS +grid_RRFS_CONUS_3km_HRRRX_RAPX +grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS +grid_RRFS_SUBCONUS_3km_HRRRX_RAPX nco_RRFS_CONUS_25km_HRRRX_RAPX nco_RRFS_CONUS_3km_FV3GFS_FV3GFS nco_RRFS_CONUS_3km_HRRRX_RAPX diff --git a/ush/config.community.sh b/ush/config.community.sh index 5c71641d8..1b5b9018a 100644 --- a/ush/config.community.sh +++ b/ush/config.community.sh @@ -14,7 +14,6 @@ PREEXISTING_DIR_METHOD="rename" PREDEF_GRID_NAME="RRFS_CONUS_25km" GRID_GEN_METHOD="ESGgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="6" LBC_SPEC_INTVL_HRS="6" diff --git a/ush/config.nco.sh b/ush/config.nco.sh index 6f176789c..fd8cd98ca 100644 --- a/ush/config.nco.sh +++ b/ush/config.nco.sh @@ -15,7 +15,6 @@ EMC_GRID_NAME="conus_c96" # For now (20200130), this is maps to PREDEF_GRID_NAM GRID_GEN_METHOD="GFDLgrid" QUILTING="TRUE" -USE_CCPP="TRUE" CCPP_PHYS_SUITE="FV3_GFS_2017_gfdlmp" FCST_LEN_HRS="06" LBC_SPEC_INTVL_HRS="6" diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index a80bff088..e5fa2d4be 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -452,38 +452,16 @@ EXTRN_MDL_FILES_LBCS=( "LBCS_file1" "LBCS_file2" "..." ) # # Set CCPP-associated parameters. Definitions: # -# USE_CCPP: -# Flag controlling whether or not a CCPP-enabled version of the forecast -# model will be run. Note that the user is responsible for ensuring that -# a CCPP-enabled forecast model executable is built and placed at the -# correct location (that is part of the build process). -# # CCPP_PHYS_SUITE: -# If USE_CCPP has been set to "TRUE", this variable defines the physics -# suite that will run using CCPP. The choice of physics suite determines -# the forecast model's namelist file, the diagnostics table file, the -# field table file, and the XML physics suite definition file that are -# staged in the experiment directory or the cycle directories under it. -# If USE_CCPP is set to "FALSE", the only physics suite that can be run -# is the GFS. -# -# Note that it is up to the user to ensure that the CCPP-enabled forecast -# model executable is built with either the dynamic build (which can -# handle any CCPP physics package but is slower to run) or the static -# build with the correct physics package. If using a static build, the -# forecast will fail if the physics package specified in the experiment's -# variable defintions file (GLOBAL_VAR_DEFNS_FN) is not the same as the -# one that was used for the static build. -# -# OZONE_PARAM_NO_CCPP: -# The ozone parameterization to use if NOT using a CCPP-enabled forecast -# model executable. +# The physics suite that will run using CCPP (Common Community Physics +# Package). The choice of physics suite determines the forecast model's +# namelist file, the diagnostics table file, the field table file, and +# the XML physics suite definition file that are staged in the experiment +# directory or the cycle directories under it. # #----------------------------------------------------------------------- # -USE_CCPP="FALSE" CCPP_PHYS_SUITE="FV3_GSD_v0" -OZONE_PARAM_NO_CCPP="ozphys" # #----------------------------------------------------------------------- # diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index daad082e3..8ffe98768 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -510,33 +510,27 @@ print_info_msg "$VERBOSE" " ory..." cp_vrfy "${NEMS_CONFIG_TMPL_FP}" "${NEMS_CONFIG_FP}" # -# If using CCPP ... -# -if [ "${USE_CCPP}" = "TRUE" ]; then -# # Copy the CCPP physics suite definition file from its location in the # clone of the FV3 code repository to the experiment directory (EXPT- # DIR). # - print_info_msg "$VERBOSE" " +print_info_msg "$VERBOSE" " Copying the CCPP physics suite definition XML file from its location in the forecast model directory sturcture to the experiment directory..." - cp_vrfy "${CCPP_PHYS_SUITE_IN_CCPP_FP}" "${CCPP_PHYS_SUITE_FP}" +cp_vrfy "${CCPP_PHYS_SUITE_IN_CCPP_FP}" "${CCPP_PHYS_SUITE_FP}" # -# If using the GSD_v0 or GSD_SAR physics suite, copy the fixed file con- -# taining cloud condensation nuclei (CCN) data that is needed by the -# Thompson microphysics parameterization to the experiment directory. +# If using a physics suite that includes the Thompson microphysics +# parameterization, copy the fixed file containing cloud condensation +# nuclei (CCN) data that is needed by that parameterization. # - if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - print_info_msg "$VERBOSE" " +if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + print_info_msg "$VERBOSE" " Copying the fixed file containing cloud condensation nuclei (CCN) data (needed by the Thompson microphysics parameterization) to the experiment directory..." - cp_vrfy "${FIXgsm}/CCN_ACTIVATE.BIN" "$EXPTDIR" - fi - + cp_vrfy "${FIXgsm}/CCN_ACTIVATE.BIN" "$EXPTDIR" fi # #----------------------------------------------------------------------- @@ -552,8 +546,7 @@ fi # #----------------------------------------------------------------------- # -if [ "${USE_CCPP}" = "TRUE" ] && \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then +if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then mv_vrfy "${CCPP_PHYS_SUITE_FP}.tmp" "${CCPP_PHYS_SUITE_FP}" fi @@ -588,15 +581,7 @@ fi # #----------------------------------------------------------------------- # -if [ "${USE_CCPP}" = "TRUE" ]; then - exec_fn="NEMS.exe" -else - print_err_msg_exit "\ -Running this workflow without CCPP is not supported at this time. -Please set USE_CCPP=TRUE in your config.sh file. -" -fi - +exec_fn="NEMS.exe" exec_fp="${SR_WX_APP_TOP_DIR}/bin/${exec_fn}" #Check for the old build location for fv3 executable if [ ! -f "${exec_fp}" ]; then diff --git a/ush/load_modules_run_task.sh b/ush/load_modules_run_task.sh index 6e523ce3e..fb66658fd 100755 --- a/ush/load_modules_run_task.sh +++ b/ush/load_modules_run_task.sh @@ -172,21 +172,7 @@ modulefile_name="${task_name}" default_modules_dir="$HOMErrfs/modulefiles" default_modulefile_name="${machine}.default" use_default_modulefile=0 -# Dom says that a correct modules.fv3 file is generated by the forecast -# model build regardless of whether building with or without CCPP. -# Thus, we can have a symlink named "run_fcst" that points to that file -# regardless of the setting of USE_CCPP. But this requires that we then -# test the non-CCPP-enabled version, which we've never done. Leave this -# for another time... -#if [ "${task_name}" = "run_fcst" ]; then -# if [ "${USE_CCPP}" = "TRUE" ]; then -# modulefile_name=${modulefile_name}_ccpp -# else -# modulefile_name=${modulefile_name}_no_ccpp -# fi -#fi # - #----------------------------------------------------------------------- # # This comment needs to be updated: diff --git a/ush/set_ozone_param.sh b/ush/set_ozone_param.sh index b08b8bffa..df2dfa704 100644 --- a/ush/set_ozone_param.sh +++ b/ush/set_ozone_param.sh @@ -66,7 +66,6 @@ function set_ozone_param() { # local valid_args=( \ "ccpp_phys_suite_fp" \ -"ozone_param_no_ccpp" \ "output_varname_ozone_param" \ ) process_args valid_args "$@" @@ -114,9 +113,8 @@ function set_ozone_param() { # being used, then we set the variable ozone_param to the string # "ozphys". # -# If the forecast model executable is CCPP-enabled, then we check the -# CCPP physics suite file to determine the parameterization being used. -# If this file contains the line +# We check the CCPP physics suite definition file (SDF) to determine the +# parameterization being used. If this file contains the line # # ozphys_2015 # @@ -125,21 +123,14 @@ function set_ozone_param() { # # ozphys # -# then the after-2015 parameterization is being used. (The suite file -# should contain exactly one of these lines; not both or neither; check -# for this.) If the forecast model executable is not CCPP-enabled, then -# the ozone parameterization must be specified by the user. This user- -# specified value is passed in as an argument (ozone_param_no_ccpp), and -# ozone_param simply gets set to this value. +# then the after-2015 parameterization is being used. (The SDF should +# contain exactly one of these lines; not both nor neither; we check for +# this.) # #----------------------------------------------------------------------- # - if [ "${USE_CCPP}" = "FALSE" ]; then - ozone_param="${ozone_param_no_ccpp}" - else - regex_search="^[ ]*(ozphys.*)<\/scheme>[ ]*$" - ozone_param=$( sed -r -n -e "s/${regex_search}/\1/p" "${ccpp_phys_suite_fp}" ) - fi + regex_search="^[ ]*(ozphys.*)<\/scheme>[ ]*$" + ozone_param=$( sed -r -n -e "s/${regex_search}/\1/p" "${ccpp_phys_suite_fp}" ) if [ "${ozone_param}" = "ozphys_2015" ]; then fixgsm_ozone_fn="ozprdlos_2015_new_sbuvO3_tclm15_nuchem.f77" diff --git a/ush/setup.sh b/ush/setup.sh index d55b90d7d..9e13c6a19 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -538,38 +538,15 @@ check_var_valid_value \ # #----------------------------------------------------------------------- # -# Make sure USE_CCPP is set to a valid value. +# Make sure CCPP_PHYS_SUITE is set to a valid value. # #----------------------------------------------------------------------- # -check_var_valid_value "USE_CCPP" "valid_vals_USE_CCPP" -# -# Set USE_CCPP to either "TRUE" or "FALSE" so we don't have to consider -# other valid values later on. -# -USE_CCPP=${USE_CCPP^^} -if [ "$USE_CCPP" = "TRUE" ] || \ - [ "$USE_CCPP" = "YES" ]; then - USE_CCPP="TRUE" -elif [ "$USE_CCPP" = "FALSE" ] || \ - [ "$USE_CCPP" = "NO" ]; then - USE_CCPP="FALSE" -fi -# -#----------------------------------------------------------------------- -# -# If USE_CCPP is set to "TRUE", make sure CCPP_PHYS_SUITE is set to a -# valid value. -# -#----------------------------------------------------------------------- -# -if [ "${USE_CCPP}" = "TRUE" ] && [ ! -z ${CCPP_PHYS_SUITE} ]; then - err_msg="\ +err_msg="\ The CCPP physics suite specified in CCPP_PHYS_SUITE is not supported: CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\"" - check_var_valid_value \ - "CCPP_PHYS_SUITE" "valid_vals_CCPP_PHYS_SUITE" "${err_msg}" -fi +check_var_valid_value \ + "CCPP_PHYS_SUITE" "valid_vals_CCPP_PHYS_SUITE" "${err_msg}" # #----------------------------------------------------------------------- # @@ -578,8 +555,7 @@ fi # #----------------------------------------------------------------------- # -if [ "${USE_CCPP}" = "TRUE" ] && \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ]; then +if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ]; then if [ "${EXTRN_MDL_NAME_ICS}" != "GSMGFS" -a \ "${EXTRN_MDL_NAME_ICS}" != "FV3GFS" ] || \ @@ -713,8 +689,7 @@ NUM_CYCLES="${#ALL_CDATES[@]}" # # UFS_WTHR_MDL_DIR: # Directory in which the (NEMS-enabled) FV3-LAM application is located. -# This directory includes subdirectories for FV3, NEMS, and FMS. If -# USE_CCPP is set to "TRUE", it also includes a subdirectory for CCPP. +# This directory includes subdirectories for FV3, NEMS, and FMS. # #----------------------------------------------------------------------- # @@ -1220,10 +1195,7 @@ fi # #----------------------------------------------------------------------- # -dot_ccpp_phys_suite_or_null="" -if [ "${USE_CCPP}" = "TRUE" ]; then - dot_ccpp_phys_suite_or_null=".${CCPP_PHYS_SUITE}" -fi +dot_ccpp_phys_suite_or_null=".${CCPP_PHYS_SUITE}" DATA_TABLE_TMPL_FN="${DATA_TABLE_FN}" DIAG_TABLE_TMPL_FN="${DIAG_TABLE_FN}${dot_ccpp_phys_suite_or_null}" @@ -1261,20 +1233,14 @@ NEMS_CONFIG_TMPL_FP="${TEMPLATE_DIR}/${NEMS_CONFIG_TMPL_FN}" # #----------------------------------------------------------------------- # -CCPP_PHYS_SUITE_FN="" -CCPP_PHYS_SUITE_IN_CCPP_FP="" -CCPP_PHYS_SUITE_FP="" - -if [ "${USE_CCPP}" = "TRUE" ]; then - CCPP_PHYS_SUITE_FN="suite_${CCPP_PHYS_SUITE}.xml" - CCPP_PHYS_SUITE_IN_CCPP_FP="${UFS_WTHR_MDL_DIR}/FV3/ccpp/suites/${CCPP_PHYS_SUITE_FN}" - CCPP_PHYS_SUITE_FP="${EXPTDIR}/${CCPP_PHYS_SUITE_FN}" - if [ ! -f "${CCPP_PHYS_SUITE_IN_CCPP_FP}" ]; then - print_err_msg_exit "\ +CCPP_PHYS_SUITE_FN="suite_${CCPP_PHYS_SUITE}.xml" +CCPP_PHYS_SUITE_IN_CCPP_FP="${UFS_WTHR_MDL_DIR}/FV3/ccpp/suites/${CCPP_PHYS_SUITE_FN}" +CCPP_PHYS_SUITE_FP="${EXPTDIR}/${CCPP_PHYS_SUITE_FN}" +if [ ! -f "${CCPP_PHYS_SUITE_IN_CCPP_FP}" ]; then + print_err_msg_exit "\ The CCPP suite definition file (CCPP_PHYS_SUITE_IN_CCPP_FP) does not exist in the local clone of the ufs-weather-model: CCPP_PHYS_SUITE_IN_CCPP_FP = \"${CCPP_PHYS_SUITE_IN_CCPP_FP}\"" - fi fi # #----------------------------------------------------------------------- @@ -2165,14 +2131,6 @@ NNODES_RUN_FCST=$(( (PE_MEMBER01 + PPN_RUN_FCST - 1)/PPN_RUN_FCST )) # #----------------------------------------------------------------------- # -# Make sure that OZONE_PARAM_NO_CCPP is set to a valid value. -# -#----------------------------------------------------------------------- -# -check_var_valid_value "OZONE_PARAM_NO_CCPP" "valid_vals_OZONE_PARAM_NO_CCPP" -# -#----------------------------------------------------------------------- -# # Create a new experiment directory. Note that at this point we are # guaranteed that there is no preexisting experiment directory. # @@ -2208,8 +2166,7 @@ mkdir_vrfy -p "$EXPTDIR" # #----------------------------------------------------------------------- # -if [ "${USE_CCPP}" = "TRUE" ] && \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then +if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then CCPP_PHYS_SUITE_FP="${CCPP_PHYS_SUITE_FP}.tmp" cp_vrfy "${CCPP_PHYS_SUITE_IN_CCPP_FP}" "${CCPP_PHYS_SUITE_FP}" @@ -2250,7 +2207,6 @@ in the suite definition file (CCPP_PHYS_SUITE_FP) failed: # set_ozone_param \ ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_FP}" \ - ozone_param_no_ccpp="OZONE_PARAM_NO_CCPP" \ output_varname_ozone_param="OZONE_PARAM" CCPP_PHYS_SUITE_FP="${CCPP_PHYS_SUITE_FP%.tmp}" @@ -2271,7 +2227,6 @@ else # set_ozone_param \ ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_IN_CCPP_FP}" \ - ozone_param_no_ccpp="OZONE_PARAM_NO_CCPP" \ output_varname_ozone_param="OZONE_PARAM" @@ -2769,10 +2724,8 @@ fi # #----------------------------------------------------------------------- # -# Name of the ozone parameterization. If USE_CCPP is set to "FALSE", -# then this will be equal to OZONE_PARAM_NO_CCPP. If USE_CCPP is set to -# "TRUE", then the value this gets set to depends on the CCPP physics -# suite being used. +# Name of the ozone parameterization. The value this gets set to depends +# on the CCPP physics suite being used. # #----------------------------------------------------------------------- # diff --git a/ush/valid_param_vals.sh b/ush/valid_param_vals.sh index f7590e0dd..2aad5c51d 100644 --- a/ush/valid_param_vals.sh +++ b/ush/valid_param_vals.sh @@ -37,7 +37,6 @@ valid_vals_EMC_GRID_NAME=( \ "RRFS_SUBCONUS_3km" \ "GSD_RAP13km" \ ) -valid_vals_USE_CCPP=("TRUE" "true" "YES" "yes" "FALSE" "false" "NO" "no") valid_vals_CCPP_PHYS_SUITE=( \ "FV3_CPT_v0" \ "FV3_GFS_2017_gfdlmp" \ @@ -48,7 +47,6 @@ valid_vals_CCPP_PHYS_SUITE=( \ "FV3_GFS_v16beta" \ "FV3_RRFS_v1beta" \ ) -valid_vals_OZONE_PARAM_NO_CCPP=("ozphys_2015" "ozphys") valid_vals_GFDLgrid_RES=("48" "96" "192" "384" "768" "1152" "3072") valid_vals_EXTRN_MDL_NAME_ICS=("GSMGFS" "FV3GFS" "RAPX" "HRRRX" "NAM") valid_vals_EXTRN_MDL_NAME_LBCS=("GSMGFS" "FV3GFS" "RAPX" "HRRRX" "NAM") From 172500eb316699dab408d4fe575d66385c699867 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 13 Oct 2020 17:19:27 -0500 Subject: [PATCH 20/39] Remove USE_CCPP variable in preparation for merge with develop branch. --- scripts/exregional_run_fcst.sh | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 5dd04f437..8481877e5 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -444,16 +444,11 @@ else ln_vrfy -sf ${relative_or_null} ${FV3_NML_FP} ${run_dir} fi -if [ "${USE_CCPP}" = "TRUE" ]; then - - ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} - - if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - ln_vrfy -sf ${relative_or_null} $EXPTDIR/CCN_ACTIVATE.BIN ${run_dir} - fi - +ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} +if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ + [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then + ln_vrfy -sf ${relative_or_null} $EXPTDIR/CCN_ACTIVATE.BIN ${run_dir} fi # #----------------------------------------------------------------------- From 73714fb81f6486e4cbea4bf49b856395267e49c1 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 13 Oct 2020 21:51:48 -0500 Subject: [PATCH 21/39] On Orion, set the default value of PARTITION_DEFAULT to "orion" instead of a null string (which was used for testing). --- ush/setup.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ush/setup.sh b/ush/setup.sh index 5ddc167df..ecd1de52a 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -397,8 +397,7 @@ case $MACHINE in NCORES_PER_NODE=40 SCHED="${SCHED:-slurm}" -# PARTITION_DEFAULT=${PARTITION_DEFAULT:-"orion"} - PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} + PARTITION_DEFAULT=${PARTITION_DEFAULT:-"orion"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} PARTITION_HPSS=${PARTITION_HPSS:-"service"} From 42e5eb54139e9da7ec5e09c2f72de8d631d61a20 Mon Sep 17 00:00:00 2001 From: BenjaminBlake-NOAA <52074832+BenjaminBlake-NOAA@users.noreply.github.com> Date: Wed, 14 Oct 2020 07:55:05 -0400 Subject: [PATCH 22/39] Changes needed to run the regional workflow on WCOSS (#310) * Changes needed to run the regional workflow on WCOSS * Update exregional_make_sfc_climo.sh Co-authored-by: Benjamin.Blake EMC --- scripts/exregional_make_grid.sh | 14 +++++++++++++- scripts/exregional_make_orog.sh | 22 ++++++++++++++++++++-- scripts/exregional_make_sfc_climo.sh | 17 ++++++++++++----- ush/setup.sh | 16 ++-------------- 4 files changed, 47 insertions(+), 22 deletions(-) diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index 13276835e..639bf3ab0 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -103,7 +103,7 @@ export OMP_STACKSIZE=2048m case $MACHINE in -"WCOSS_C" | "WCOSS") +"WCOSS_CRAY") # { save_shell_opts; set +x; } > /dev/null 2>&1 @@ -121,6 +121,18 @@ case $MACHINE in ulimit -a ;; +"WCOSS_DELL_P3") +# + { save_shell_opts; set +x; } > /dev/null 2>&1 + + module list + + { restore_shell_opts; } > /dev/null 2>&1 + + export APRUN="mpirun" + + ulimit -s unlimited + ;; "HERA") # diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index 61639c3b3..fece0763e 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -99,7 +99,7 @@ export OMP_STACKSIZE=2048m case $MACHINE in -"WCOSS_C" | "WCOSS") +"WCOSS_CRAY") # { save_shell_opts; set +x; } > /dev/null 2>&1 @@ -117,6 +117,11 @@ case $MACHINE in ulimit -a ;; +"WCOSS_DELL_P3") + ulimit -s unlimited + ulimit -a + APRUN="mpirun" + ;; "HERA") ulimit -s unlimited @@ -286,7 +291,7 @@ Starting orography file generation..." case $MACHINE in -"WCOSS_C" | "WCOSS") +"WCOSS_CRAY") # # On WCOSS and WCOSS_C, use cfp to run multiple tiles simulatneously for # the orography. For now, we have only one tile in the regional case, @@ -312,6 +317,19 @@ ${tmp_dir}" \ ;; +"WCOSS_DELL_P3") + + ufs_utils_ushdir="${UFS_UTILS_DIR}/ush" + res="0" # What should this be set to??? + + "${exec_fp}" < "${input_redirect_fn}" || \ + print_err_msg_exit "\ +Call to executable (exec_fp) that generates the raw orography file returned +with nonzero exit code: + exec_fp = \"${exec_fp}\"" + ;; + + "CHEYENNE" | "HERA" | "JET" | "ODIN" | "STAMPEDE") $APRUN "${exec_fp}" < "${input_redirect_fn}" || \ print_err_msg_exit "\ diff --git a/scripts/exregional_make_sfc_climo.sh b/scripts/exregional_make_sfc_climo.sh index c581f040a..b7709a615 100755 --- a/scripts/exregional_make_sfc_climo.sh +++ b/scripts/exregional_make_sfc_climo.sh @@ -128,14 +128,21 @@ EOF # case $MACHINE in -"WCOSS_C") -# This could be wrong. Just a guess since I don't have access to this machine. +"WCOSS_CRAY") APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} ;; -"WCOSS") -# This could be wrong. Just a guess since I don't have access to this machine. - APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} +"WCOSS_DELL_P3") + +# Specify computational resources. + export NODES=2 + export ntasks=48 + export ptile=24 + export threads=1 + export MP_LABELIO=yes + export OMP_NUM_THREADS=$threads + + APRUN="mpirun" ;; "HERA") diff --git a/ush/setup.sh b/ush/setup.sh index 9e13c6a19..1bd70a6ed 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -720,25 +720,13 @@ case $MACHINE in "WCOSS_CRAY") FIXgsm=${FIXgsm:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_sfc_climo"} ;; "WCOSS_DELL_P3") FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - -"DELL") - FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - -"THEIA") - FIXgsm=${FIXgsm:-"/scratch4/NCEPDEV/global/save/glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/scratch4/NCEPDEV/global/save/glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/scratch4/NCEPDEV/da/noscrub/George.Gayno/climo_fields_netcdf"} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_sfc_climo"} ;; "HERA") From 960e5ff9fe26159a9330807d4dbb1bdbc8ec95ce Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 14 Oct 2020 13:51:51 -0500 Subject: [PATCH 23/39] Manual merging with develop branch to make later conflict resolution via mergetool easier. --- scripts/exregional_make_grid.sh | 14 +++++--- scripts/exregional_make_orog.sh | 48 ++++++++++++++++------------ scripts/exregional_make_sfc_climo.sh | 15 ++++++--- ush/setup.sh | 10 ++---- 4 files changed, 48 insertions(+), 39 deletions(-) diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index 7ea5f499c..8f025bbc5 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -99,23 +99,27 @@ export OMP_STACKSIZE=2048m # case $MACHINE in - "WCOSS_C" | "WCOSS") + "WCOSS_CRAY") { save_shell_opts; set +x; } > /dev/null 2>&1 - . $MODULESHOME/init/sh module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 module list - { restore_shell_opts; } > /dev/null 2>&1 - export NODES=1 export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" export KMP_AFFINITY=disabled - ulimit -s unlimited ulimit -a ;; + "WCOSS_DELL_P3") + { save_shell_opts; set +x; } > /dev/null 2>&1 + module list + { restore_shell_opts; } > /dev/null 2>&1 + export APRUN="mpirun" + ulimit -s unlimited + ;; + "HERA") APRUN="time" ;; diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index 045da170f..2b8c07dfe 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -98,21 +98,23 @@ export OMP_STACKSIZE=2048m # case $MACHINE in - "WCOSS_C" | "WCOSS") + "WCOSS_CRAY") { save_shell_opts; set +x; } > /dev/null 2>&1 - . $MODULESHOME/init/sh module load PrgEnv-intel cfp-intel-sandybridge/1.1.0 module list - { restore_shell_opts; } > /dev/null 2>&1 - export NODES=1 export APRUN="aprun -n 1 -N 1 -j 1 -d 1 -cc depth" export KMP_AFFINITY=disabled + ulimit -s unlimited + ulimit -a + ;; + "WCOSS_DELL_P3") ulimit -s unlimited ulimit -a + APRUN="mpirun" ;; "HERA") @@ -287,21 +289,18 @@ cat "${input_redirect_fn}" print_info_msg "$VERBOSE" " Starting orography file generation..." - case $MACHINE in - -"WCOSS_C" | "WCOSS") + "WCOSS_CRAY") # # On WCOSS and WCOSS_C, use cfp to run multiple tiles simulatneously for # the orography. For now, we have only one tile in the regional case, # but in the future we will have more. First, create an input file for # cfp. # - ufs_utils_ushdir="${UFS_UTILS_DIR}/ush" - res="0" # What should this be set to??? - - printf "%s\n" "\ + ufs_utils_ushdir="${UFS_UTILS_DIR}/ush" + res="0" # What should this be set to??? + printf "%s\n" "\ ${ufs_utils_ushdir}/${orog_gen_scr} \ $res \ ${TILE_RGNL} \ @@ -310,21 +309,28 @@ ${raw_dir} \ ${UFS_UTILS_DIR} \ ${TOPO_DIR} \ ${tmp_dir}" \ - >> ${tmp_dir}/orog.file1 - - aprun -j 1 -n 4 -N 4 -d 6 -cc depth cfp ${tmp_dir}/orog.file1 - rm_vrfy ${tmp_dir}/orog.file1 - ;; - + >> ${tmp_dir}/orog.file1 + aprun -j 1 -n 4 -N 4 -d 6 -cc depth cfp ${tmp_dir}/orog.file1 + rm_vrfy ${tmp_dir}/orog.file1 + ;; -"CHEYENNE" | "HERA" | "JET" | "ODIN" | "STAMPEDE" | "ORION") - $APRUN "${exec_fp}" < "${input_redirect_fn}" || \ - print_err_msg_exit "\ + "WCOSS_DELL_P3") + ufs_utils_ushdir="${UFS_UTILS_DIR}/ush" + res="0" # What should this be set to??? + "${exec_fp}" < "${input_redirect_fn}" || \ + print_err_msg_exit "\ Call to executable (exec_fp) that generates the raw orography file returned with nonzero exit code: exec_fp = \"${exec_fp}\"" - ;; + ;; + "CHEYENNE" | "HERA" | "ORION" | "JET" | "ODIN" | "STAMPEDE") + $APRUN "${exec_fp}" < "${input_redirect_fn}" || \ + print_err_msg_exit "\ +Call to executable (exec_fp) that generates the raw orography file returned +with nonzero exit code: + exec_fp = \"${exec_fp}\"" + ;; esac # diff --git a/scripts/exregional_make_sfc_climo.sh b/scripts/exregional_make_sfc_climo.sh index 0e4067f0f..31f2c877f 100755 --- a/scripts/exregional_make_sfc_climo.sh +++ b/scripts/exregional_make_sfc_climo.sh @@ -128,14 +128,19 @@ EOF # case $MACHINE in - "WCOSS_C") -# This could be wrong. Just a guess since I don't have access to this machine. + "WCOSS_CRAY") APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} ;; - "WCOSS") -# This could be wrong. Just a guess since I don't have access to this machine. - APRUN=${APRUN:-"aprun -j 1 -n 6 -N 6"} + "WCOSS_DELL_P3") +# Specify computational resources. + export NODES=2 + export ntasks=48 + export ptile=24 + export threads=1 + export MP_LABELIO=yes + export OMP_NUM_THREADS=$threads + APRUN="mpirun" ;; "HERA") diff --git a/ush/setup.sh b/ush/setup.sh index ecd1de52a..2099c4fd7 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -776,19 +776,13 @@ case $MACHINE in "WCOSS_CRAY") FIXgsm=${FIXgsm:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/gpfs/hps3/emc/global/noscrub/emc.glopara/git/fv3gfs/fix/fix_sfc_climo"} ;; "WCOSS_DELL_P3") FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} - ;; - - "DELL") - FIXgsm=${FIXgsm:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_am"} - TOPO_DIR=${TOPO_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_orog"} - SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-""} + SFC_CLIMO_INPUT_DIR=${SFC_CLIMO_INPUT_DIR:-"/gpfs/dell2/emc/modeling/noscrub/emc.glopara/git/fv3gfs/fix/fix_sfc_climo"} ;; "HERA") From 051133a6c5d7ff13be5f9e7bc28ea90a72195429 Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Thu, 15 Oct 2020 15:08:01 -0600 Subject: [PATCH 24/39] Remove unused/outdated code (#313) ## DESCRIPTION OF CHANGES: * In setup.sh and generate_FV3LAM_wflow.sh, remove temporary codes that fix bugs in the FV3_GFS_2017_gfdlmp_regional suite definition file because those bugs have been fixed (in the ufs-weather-model repo). * In setup.sh, remove block of code that is no longer necessary because chgres_cube can now initialize from external model data with either 4 or 9 soil levels, and run with LSMs of either 4 or 9 soil levels. * Remove modifications to LD_LIBRARY_PATH in exregional_run_fcst.sh. * For the make_ics and make_lbcs tasks, move the setting of APRUN and other machine-specific actions from the J-job to the ex-script in order to be consistent with the other workflow tasks. * Fix indentation and edit comments. * Remove unused file load_fv3gfs_modules.sh. ## TESTS CONDUCTED: Ran two WE2E tests on hera, new_ESGgrid and new_GFDLgrid: * new_ESGgrid uses the FV3_GFS_2017_gfdlmp_regional suite. The test was successful. * new_GFDLgrid uses the FV3_GFS_2017_gfdlmp suite. The test was successful. ## ISSUE (optional): This resolves issue #198. --- jobs/JREGIONAL_MAKE_ICS | 45 +---------- jobs/JREGIONAL_MAKE_LBCS | 46 +---------- scripts/exregional_make_ics.sh | 83 +++++++++++++++----- scripts/exregional_make_lbcs.sh | 79 +++++++++++++++---- scripts/exregional_run_fcst.sh | 4 - ush/generate_FV3LAM_wflow.sh | 17 ----- ush/load_fv3gfs_modules.sh | 42 ---------- ush/setup.sh | 131 ++++---------------------------- 8 files changed, 145 insertions(+), 302 deletions(-) delete mode 100755 ush/load_fv3gfs_modules.sh diff --git a/jobs/JREGIONAL_MAKE_ICS b/jobs/JREGIONAL_MAKE_ICS index 4ca00af53..01027b4ac 100755 --- a/jobs/JREGIONAL_MAKE_ICS +++ b/jobs/JREGIONAL_MAKE_ICS @@ -49,48 +49,6 @@ for the FV3 (in NetCDF format). # #----------------------------------------------------------------------- # -# Set machine-dependent parameters. -# -#----------------------------------------------------------------------- -# -case "$MACHINE" in - - "WCOSS_CRAY") - ulimit -s unlimited - APRUN="aprun -b -j1 -n48 -N12 -d1 -cc depth" - ;; - - "WCOSS_DELL_P3") - ulimit -s unlimited - APRUN="mpirun" - ;; - - "HERA") - ulimit -s unlimited - APRUN="srun" - ;; - - "JET") - ulimit -s unlimited - APRUN="srun" - ;; - - "ODIN") - APRUN="srun" - ;; - - "CHEYENNE") - nprocs=$(( NNODES_MAKE_ICS*PPN_MAKE_ICS )) - APRUN="mpirun -np $nprocs" - ;; - "STAMPEDE") - APRUN="ibrun" - ;; - -esac -# -#----------------------------------------------------------------------- -# # Set the name of and create the directory in which the output from this # script will be placed (if that directory doesn't already exist). # @@ -106,8 +64,7 @@ mkdir_vrfy -p "${ics_dir}" #----------------------------------------------------------------------- # $SCRIPTSDIR/exregional_make_ics.sh \ - ics_dir="${ics_dir}" \ - APRUN="${APRUN}" || \ + ics_dir="${ics_dir}" || \ print_err_msg_exit "\ Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed." # diff --git a/jobs/JREGIONAL_MAKE_LBCS b/jobs/JREGIONAL_MAKE_LBCS index 43bd27b5d..b46d0e950 100755 --- a/jobs/JREGIONAL_MAKE_LBCS +++ b/jobs/JREGIONAL_MAKE_LBCS @@ -49,49 +49,6 @@ hour zero). # #----------------------------------------------------------------------- # -# Set machine-dependent parameters. -# -#----------------------------------------------------------------------- -# -case "$MACHINE" in - - "WCOSS_CRAY") - ulimit -s unlimited - APRUN="aprun -b -j1 -n48 -N12 -d1 -cc depth" - ;; - - "WCOSS_DELL_P3") - ulimit -s unlimited - APRUN="mpirun" - ;; - - "HERA") - ulimit -s unlimited - APRUN="srun" - ;; - - "JET") - ulimit -s unlimited - APRUN="srun" - ;; - - "ODIN") - APRUN="srun" - ;; - - "CHEYENNE") - nprocs=$(( NNODES_MAKE_LBCS*PPN_MAKE_LBCS )) - APRUN="mpirun -np $nprocs" - ;; - - "STAMPEDE") - APRUN="ibrun" - ;; - -esac -# -#----------------------------------------------------------------------- -# # Set the name of and create the directory in which the output from this # script will be placed (if it doesn't already exist). # @@ -107,8 +64,7 @@ mkdir_vrfy -p "${lbcs_dir}" #----------------------------------------------------------------------- # $SCRIPTSDIR/exregional_make_lbcs.sh \ - lbcs_dir="${lbcs_dir}" \ - APRUN="${APRUN}" || \ + lbcs_dir="${lbcs_dir}" || \ print_err_msg_exit "\ Call to ex-script corresponding to J-job \"${scrfunc_fn}\" failed." # diff --git a/scripts/exregional_make_ics.sh b/scripts/exregional_make_ics.sh index 04cc14652..7463de5fb 100755 --- a/scripts/exregional_make_ics.sh +++ b/scripts/exregional_make_ics.sh @@ -57,7 +57,6 @@ This is the ex-script for the task that generates initial condition # valid_args=( \ "ics_dir" \ -"APRUN" \ ) process_args valid_args "$@" # @@ -73,6 +72,49 @@ print_input_args valid_args # #----------------------------------------------------------------------- # +# Set machine-dependent parameters. +# +#----------------------------------------------------------------------- +# +case "$MACHINE" in + + "WCOSS_CRAY") + ulimit -s unlimited + APRUN="aprun -b -j1 -n48 -N12 -d1 -cc depth" + ;; + + "WCOSS_DELL_P3") + ulimit -s unlimited + APRUN="mpirun" + ;; + + "HERA") + ulimit -s unlimited + APRUN="srun" + ;; + + "JET") + ulimit -s unlimited + APRUN="srun" + ;; + + "ODIN") + APRUN="srun" + ;; + + "CHEYENNE") + nprocs=$(( NNODES_MAKE_ICS*PPN_MAKE_ICS )) + APRUN="mpirun -np $nprocs" + ;; + + "STAMPEDE") + APRUN="ibrun" + ;; + +esac +# +#----------------------------------------------------------------------- +# # Source the file containing definitions of variables associated with the # external model for ICs. # @@ -102,26 +144,33 @@ cd_vrfy $workdir varmap_file="" case "${CCPP_PHYS_SUITE}" in - -"FV3_GFS_2017_gfdlmp" | "FV3_GFS_2017_gfdlmp_regional" | "FV3_GFS_v16beta" | \ -"FV3_GFS_v15p2" | "FV3_CPT_v0" ) - varmap_file="GFSphys_var_map.txt" - ;; -"FV3_GSD_v0" | "FV3_GSD_SAR" | \ -"FV3_RRFS_v1beta" ) - if [ "${EXTRN_MDL_NAME_ICS}" = "RAPX" ] || [ "${EXTRN_MDL_NAME_ICS}" = "HRRRX" ]; then +# + "FV3_GFS_2017_gfdlmp" | \ + "FV3_GFS_2017_gfdlmp_regional" | \ + "FV3_GFS_v16beta" | \ + "FV3_GFS_v15p2" | "FV3_CPT_v0" ) + varmap_file="GFSphys_var_map.txt" + ;; +# + "FV3_GSD_v0" | \ + "FV3_GSD_SAR" | \ + "FV3_RRFS_v1beta" ) + if [ "${EXTRN_MDL_NAME_ICS}" = "RAPX" ] || \ + [ "${EXTRN_MDL_NAME_ICS}" = "HRRRX" ]; then varmap_file="GSDphys_var_map.txt" - elif [ "${EXTRN_MDL_NAME_ICS}" = "NAM" ] || [ "${EXTRN_MDL_NAME_ICS}" = "FV3GFS" ] || \ - [ "${EXTRN_MDL_NAME_ICS}" = "GSMGFS" ]; then + elif [ "${EXTRN_MDL_NAME_ICS}" = "NAM" ] || \ + [ "${EXTRN_MDL_NAME_ICS}" = "FV3GFS" ] || \ + [ "${EXTRN_MDL_NAME_ICS}" = "GSMGFS" ]; then varmap_file="GFSphys_var_map.txt" - fi - ;; -*) - print_err_msg_exit "\ + fi + ;; +# + *) + print_err_msg_exit "\ A variable mapping table has not yet been defined for this physics suite: CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\"" - ;; - + ;; +# esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_make_lbcs.sh b/scripts/exregional_make_lbcs.sh index 6f074ae5d..7967c68dd 100755 --- a/scripts/exregional_make_lbcs.sh +++ b/scripts/exregional_make_lbcs.sh @@ -57,7 +57,6 @@ hour zero). # valid_args=( \ "lbcs_dir" \ -"APRUN" \ ) process_args valid_args "$@" # @@ -73,6 +72,49 @@ print_input_args valid_args # #----------------------------------------------------------------------- # +# Set machine-dependent parameters. +# +#----------------------------------------------------------------------- +# +case "$MACHINE" in + + "WCOSS_CRAY") + ulimit -s unlimited + APRUN="aprun -b -j1 -n48 -N12 -d1 -cc depth" + ;; + + "WCOSS_DELL_P3") + ulimit -s unlimited + APRUN="mpirun" + ;; + + "HERA") + ulimit -s unlimited + APRUN="srun" + ;; + + "JET") + ulimit -s unlimited + APRUN="srun" + ;; + + "ODIN") + APRUN="srun" + ;; + + "CHEYENNE") + nprocs=$(( NNODES_MAKE_LBCS*PPN_MAKE_LBCS )) + APRUN="mpirun -np $nprocs" + ;; + + "STAMPEDE") + APRUN="ibrun" + ;; + +esac +# +#----------------------------------------------------------------------- +# # Source the file containing definitions of variables associated with the # external model for LBCs. # @@ -102,26 +144,33 @@ cd_vrfy $workdir varmap_file="" case "${CCPP_PHYS_SUITE}" in - -"FV3_GFS_2017_gfdlmp" | "FV3_GFS_2017_gfdlmp_regional" | "FV3_GFS_v16beta" | \ -"FV3_GFS_v15p2" | "FV3_CPT_v0" ) - varmap_file="GFSphys_var_map.txt" - ;; -"FV3_GSD_v0" | "FV3_GSD_SAR" | \ -"FV3_RRFS_v1beta" ) - if [ "${EXTRN_MDL_NAME_LBCS}" = "RAPX" ] || [ "${EXTRN_MDL_NAME_LBCS}" = "HRRRX" ]; then +# + "FV3_GFS_2017_gfdlmp" | \ + "FV3_GFS_2017_gfdlmp_regional" | \ + "FV3_GFS_v16beta" | \ + "FV3_GFS_v15p2" | "FV3_CPT_v0" ) + varmap_file="GFSphys_var_map.txt" + ;; +# + "FV3_GSD_v0" | \ + "FV3_GSD_SAR" | \ + "FV3_RRFS_v1beta" ) + if [ "${EXTRN_MDL_NAME_LBCS}" = "RAPX" ] || \ + [ "${EXTRN_MDL_NAME_LBCS}" = "HRRRX" ]; then varmap_file="GSDphys_var_map.txt" - elif [ "${EXTRN_MDL_NAME_LBCS}" = "NAM" ] || [ "${EXTRN_MDL_NAME_LBCS}" = "FV3GFS" ] || \ - [ "${EXTRN_MDL_NAME_LBCS}" = "GSMGFS" ]; then + elif [ "${EXTRN_MDL_NAME_LBCS}" = "NAM" ] || \ + [ "${EXTRN_MDL_NAME_LBCS}" = "FV3GFS" ] || \ + [ "${EXTRN_MDL_NAME_LBCS}" = "GSMGFS" ]; then varmap_file="GFSphys_var_map.txt" - fi - ;; -*) + fi + ;; +# + *) print_err_msg_exit "\ A variable mapping table has not yet been defined for this physics suite: CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\"" ;; - +# esac # #----------------------------------------------------------------------- diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 2168b985f..8c86f4db1 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -106,7 +106,6 @@ case $MACHINE in ulimit -s unlimited ulimit -a APRUN="srun" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" OMP_NUM_THREADS=4 ;; # @@ -114,7 +113,6 @@ case $MACHINE in ulimit -s unlimited ulimit -a APRUN="srun" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" OMP_NUM_THREADS=4 ;; # @@ -132,7 +130,6 @@ case $MACHINE in module list nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) APRUN="mpirun -np $nprocs" - LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" ;; # @@ -141,7 +138,6 @@ case $MACHINE in module list APRUN="ibrun -np ${PE_MEMBER01}" - #LD_LIBRARY_PATH="${UFS_WTHR_MDL_DIR}/FV3/ccpp/lib${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}" ;; esac diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 8ffe98768..02140cfe3 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -532,23 +532,6 @@ Copying the fixed file containing cloud condensation nuclei (CCN) data directory..." cp_vrfy "${FIXgsm}/CCN_ACTIVATE.BIN" "$EXPTDIR" fi -# -#----------------------------------------------------------------------- -# -# This if-statement is a temporary fix that makes corrections to the suite -# definition file for the "FV3_GFS_2017_gfdlmp_regional" physics suite -# that EMC uses. -# -# IMPORTANT: -# This if-statement must be removed once these corrections are made to -# the suite definition file in the dtc/develop branch of the NCAR fork -# of the fv3atm repository. -# -#----------------------------------------------------------------------- -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then - mv_vrfy "${CCPP_PHYS_SUITE_FP}.tmp" "${CCPP_PHYS_SUITE_FP}" -fi diff --git a/ush/load_fv3gfs_modules.sh b/ush/load_fv3gfs_modules.sh deleted file mode 100755 index f95b0237a..000000000 --- a/ush/load_fv3gfs_modules.sh +++ /dev/null @@ -1,42 +0,0 @@ -#!/bin/sh -#set -x - -############################################################### -# Setup runtime environment by loading modules -ulimit_s=$( ulimit -S -s ) -ulimit -S -s 10000 - -# Find module command and purge: -source "$HOMEgfs/modulefiles/module-setup.sh.inc" - -# Load our modules: -module use "$HOMEgfs/modulefiles" - -if [[ -d /lfs4 ]] ; then - # We are on NOAA Jet - module load module_base.jet -elif [[ -d /scratch3 ]] ; then - # We are on NOAA Theia - module load module_base.theia -elif [[ -d /gpfs/hps && -e /etc/SuSE-release ]] ; then - # We are on NOAA Luna or Surge - module load module_base.wcoss_c -elif [[ -L /usrx && "$( readlink /usrx 2> /dev/null )" =~ dell ]] ; then - # We are on NOAA Mars or Venus - module load module_base.wcoss_dell_p3 -elif [[ -d /dcom && -d /hwrf ]] ; then - # We are on NOAA Tide or Gyre - module load module_base.wcoss -elif [[ -d /glade ]] ; then - # We are on NCAR Yellowstone - module load module_base.cheyenne -elif [[ -d /lustre && -d /ncrc ]] ; then - # We are on GAEA. - module load module_base.gaea -else - echo WARNING: UNKNOWN PLATFORM -fi - -# Restore stack soft limit: -ulimit -S -s "$ulimit_s" -unset ulimit_s diff --git a/ush/setup.sh b/ush/setup.sh index 1bd70a6ed..d25fdd6c0 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -550,31 +550,6 @@ check_var_valid_value \ # #----------------------------------------------------------------------- # -# If using CCPP with the GFS_2017_gfdlmp physics suite, only allow -# "GSMGFS" and "FV3GFS" as the external models for ICs and LBCs. -# -#----------------------------------------------------------------------- -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp" ]; then - - if [ "${EXTRN_MDL_NAME_ICS}" != "GSMGFS" -a \ - "${EXTRN_MDL_NAME_ICS}" != "FV3GFS" ] || \ - [ "${EXTRN_MDL_NAME_LBCS}" != "GSMGFS" -a \ - "${EXTRN_MDL_NAME_LBCS}" != "FV3GFS" ]; then - print_info_msg "$VERBOSE" " -The following combination of physics suite and external model(s) for ICs -and LBCs is not allowed: - CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\" - EXTRN_MDL_NAME_ICS = \"${EXTRN_MDL_NAME_ICS}\" - EXTRN_MDL_NAME_LBCS = \"${EXTRN_MDL_NAME_LBCS}\" -For this physics suite, the only external models that the workflow cur- -rently allows are \"GSMGFS\" and \"FV3GFS\"." - fi - -fi -# -#----------------------------------------------------------------------- -# # Check that DATE_FIRST_CYCL and DATE_LAST_CYCL are strings consisting # of exactly 8 digits. # @@ -985,6 +960,7 @@ drag related orography files for the FV3_RRFS_v1beta is empty: fi fi # +# #----------------------------------------------------------------------- # # If the base directory (EXPT_BASEDIR) in which the experiment subdirectory @@ -1202,7 +1178,7 @@ NEMS_CONFIG_TMPL_FP="${TEMPLATE_DIR}/${NEMS_CONFIG_TMPL_FN}" # #----------------------------------------------------------------------- # -# If using CCPP, set: +# Set: # # 1) the variable CCPP_PHYS_SUITE_FN to the name of the CCPP physics # suite definition file. @@ -1216,9 +1192,6 @@ NEMS_CONFIG_TMPL_FP="${TEMPLATE_DIR}/${NEMS_CONFIG_TMPL_FN}" # each cycle, the forecast launch script will create a link in the cycle # run directory to the copy of this file at CCPP_PHYS_SUITE_FP. # -# Note that if not using CCPP, the variables described above will get -# set to null strings. -# #----------------------------------------------------------------------- # CCPP_PHYS_SUITE_FN="suite_${CCPP_PHYS_SUITE}.xml" @@ -1233,6 +1206,17 @@ fi # #----------------------------------------------------------------------- # +# Call the function that sets the ozone parameterization being used and +# modifies associated parameters accordingly. +# +#----------------------------------------------------------------------- +# +set_ozone_param \ + ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_IN_CCPP_FP}" \ + output_varname_ozone_param="OZONE_PARAM" +# +#----------------------------------------------------------------------- +# # Set the full paths to those forecast model input files that are cycle- # independent, i.e. they don't include information about the cycle's # starting day/time. These are: @@ -2131,95 +2115,6 @@ mkdir_vrfy -p "$EXPTDIR" -# -#----------------------------------------------------------------------- -# -# This if-statement is a temporary fix that makes corrections to the suite -# definition file for the "FV3_GFS_2017_gfdlmp_regional" physics suite -# that EMC uses. The corrections are: -# -# 1) Add a "fast_physics" group name to the beginning of the file. -# 2) Replace the ozphys parameterization with the ozphys_2015 parameterization. -# -# Note that this must be done before the call to the function set_ozone_param -# below because that function reads in the ozone parameterization in the -# suite definition file in order to set the ozone parameterization being -# used in the experiment; thus, the suite definition file must have the -# correct ozone parameterization specified before the call to set_ozone_param. -# -# IMPORTANT: -# This if-statement must be removed once these corrections are made to -# the suite definition file in the dtc/develop branch of the NCAR fork -# of the fv3atm repository. -# -#----------------------------------------------------------------------- -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_GFS_2017_gfdlmp_regional" ]; then - - CCPP_PHYS_SUITE_FP="${CCPP_PHYS_SUITE_FP}.tmp" - cp_vrfy "${CCPP_PHYS_SUITE_IN_CCPP_FP}" "${CCPP_PHYS_SUITE_FP}" - - grep "fast_physics" "${CCPP_PHYS_SUITE_FP}" || { \ - fast_phys_group='\ - \ - \ - fv_sat_adj\ - \ - ' ; - sed -i -r "5i${fast_phys_group}" "${CCPP_PHYS_SUITE_FP}" || \ - print_err_msg_exit "\ -Attempt to insert the \"fast_physics\" group into the suite definition -file (CCPP_PHYS_SUITE_FP) failed: - CCPP_PHYS_SUITE_FP = \"${CCPP_PHYS_SUITE_FP}\"" ; - } - - grep "ozphys" "${CCPP_PHYS_SUITE_FP}" && { \ - sed -i "s/ozphys/ozphys_2015/g" "${CCPP_PHYS_SUITE_FP}" || \ - print_err_msg_exit "\ -Attempt to replace the \"ozphys\" scheme with the \"ozphys_2015\" scheme -in the suite definition file (CCPP_PHYS_SUITE_FP) failed: - CCPP_PHYS_SUITE_FP = \"${CCPP_PHYS_SUITE_FP}\"" ; - } -# -#----------------------------------------------------------------------- -# -# Call the function that sets the ozone parameterization being used and -# modifies associated parameters accordingly. -# -# This is a repeat of the same call in setup.sh. It must be redone because -# the contents of CCPP_PHYS_SUITE_FP have been modified, and the function -# set_ozone_param depends on that file to set elements of the workflow -# arrays CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING and FIXgsm_FILES_TO_COPY_TO_FIXam. -# -#----------------------------------------------------------------------- -# - set_ozone_param \ - ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_FP}" \ - output_varname_ozone_param="OZONE_PARAM" - - CCPP_PHYS_SUITE_FP="${CCPP_PHYS_SUITE_FP%.tmp}" - -else -# -#----------------------------------------------------------------------- -# -# Call the function that sets the ozone parameterization being used and -# modifies associated parameters accordingly. -# -#----------------------------------------------------------------------- -# -# NOTE: -# After the temporary code above in the "if" part of the if-statement is -# removed, this "else" part can be moved back up to before the creation -# of EXPTDIR (above). -# -set_ozone_param \ - ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_IN_CCPP_FP}" \ - output_varname_ozone_param="OZONE_PARAM" - - -fi - From bbe8d58f4bf8c2f72b14e7e2ed435e33470c01ea Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Thu, 15 Oct 2020 18:16:52 -0600 Subject: [PATCH 25/39] Bug fixes. --- ush/setup.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ush/setup.sh b/ush/setup.sh index da6a88cfa..531333b12 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -386,7 +386,7 @@ case $MACHINE in QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} PARTITION_HPSS=${PARTITION_HPSS:-"service"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_HPSS=${QUEUE_HPSS:-"batch"} # QUEUE_HPSS_TAG="queue" PARTITION_FCST=${PARTITION_FCST:-"hera"} @@ -416,7 +416,7 @@ case $MACHINE in QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} PARTITION_HPSS=${PARTITION_HPSS:-"service"} - QUEUE_HPSS=${QUEUE_HPSS:-"service"} + QUEUE_HPSS=${QUEUE_HPSS:-"batch"} PARTITION_FCST=${PARTITION_FCST:-"sjet,vjet,kjet,xjet"} QUEUE_FCST=${QUEUE_FCST:-"batch"} From 345aedf66fbc6159bf0e61f40ed02e2d5472e674 Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Fri, 16 Oct 2020 09:25:47 -0600 Subject: [PATCH 26/39] Add and call a function that checks for use of Thompson microphysics parameterization in the SDF and if so, adjusts certain workflow arrays to contain the names and other associated values of the fixed files needed by this parameterization so that those files are automatically copied and/or linked to. (#319) ## DESCRIPTION OF CHANGES: Add and call a function that checks for use of Thompson microphysics parameterization in the suite definition file (SDF). If not, do nothing. If so, add to the appropriate workflow arrays the names and other associated values of the fixed files needed by this parameterization so that they are automatically copied and/or linked to instead of being regenerated from scratch in the run_fcst task. ## TESTS CONDUCTED: On hera, ran two WE2E tests, one in NCO mode (nco_RRFS_CONUS_25km_HRRRX_RAPX) and the other in community mode (suite_FV3_GSD_v0). These use suites FV3_GSD_SAR and FV3_GSD_v0, respectively, and both of these call Thompson microphysics. Both succeeded. ## ISSUE (optional): This PR resolves issue #297. --- scripts/exregional_run_fcst.sh | 155 ++++++++++++++-------------- ush/generate_FV3LAM_wflow.sh | 19 ---- ush/set_ozone_param.sh | 4 +- ush/set_thompson_mp_fix_files.sh | 168 +++++++++++++++++++++++++++++++ ush/setup.sh | 15 ++- 5 files changed, 261 insertions(+), 100 deletions(-) create mode 100644 ush/set_thompson_mp_fix_files.sh diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index 8c86f4db1..cc92781fc 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -88,57 +88,63 @@ print_input_args valid_args #----------------------------------------------------------------------- # case $MACHINE in -# -"WCOSS_CRAY") -# - ulimit -s unlimited - ulimit -a - APRUN="aprun -b -j1 -n${PE_MEMBER01} -N24 -d1 -cc depth" - ;; -# -"WCOSS_DELL_P3") - ulimit -s unlimited - ulimit -a - APRUN="mpirun -l -np ${PE_MEMBER01}" - ;; -# -"HERA") - ulimit -s unlimited - ulimit -a - APRUN="srun" - OMP_NUM_THREADS=4 - ;; -# -"JET") - ulimit -s unlimited - ulimit -a - APRUN="srun" - OMP_NUM_THREADS=4 - ;; -# -"ODIN") -# - module list - - ulimit -s unlimited - ulimit -a - APRUN="srun -n ${PE_MEMBER01}" - ;; -# -"CHEYENNE") -# - module list - nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) - APRUN="mpirun -np $nprocs" - ;; -# - -"STAMPEDE") -# - module list - APRUN="ibrun -np ${PE_MEMBER01}" - ;; + "WCOSS_CRAY") + ulimit -s unlimited + ulimit -a + APRUN="aprun -b -j1 -n${PE_MEMBER01} -N24 -d1 -cc depth" + ;; + + "WCOSS_DELL_P3") + ulimit -s unlimited + ulimit -a + APRUN="mpirun -l -np ${PE_MEMBER01}" + ;; + + "HERA") + ulimit -s unlimited + ulimit -a + APRUN="srun" + OMP_NUM_THREADS=4 + ;; + + "ORION") + ulimit -s unlimited + ulimit -a + APRUN="srun" + ;; + + "JET") + ulimit -s unlimited + ulimit -a + APRUN="srun" + OMP_NUM_THREADS=4 + ;; + + "ODIN") + module list + ulimit -s unlimited + ulimit -a + APRUN="srun -n ${PE_MEMBER01}" + ;; + + "CHEYENNE") + module list + nprocs=$(( NNODES_RUN_FCST*PPN_RUN_FCST )) + APRUN="mpirun -np $nprocs" + ;; + + "STAMPEDE") + module list + APRUN="ibrun -np ${PE_MEMBER01}" + ;; + + *) + print_err_msg_exit "\ +Run command has not been specified for this machine: + MACHINE = \"$MACHINE\" + APRUN = \"$APRUN\"" + ;; esac # @@ -152,13 +158,13 @@ run_dir="${cycle_dir}${slash_ensmem_subdir}" # #----------------------------------------------------------------------- # -# Create links in the INPUT subdirectory of the current run directory to +# Create links in the INPUT subdirectory of the current run directory to # the grid and (filtered) orography files. # #----------------------------------------------------------------------- # print_info_msg "$VERBOSE" " -Creating links in the INPUT subdirectory of the current run directory to +Creating links in the INPUT subdirectory of the current run directory to the grid and (filtered) orography files ..." @@ -249,14 +255,14 @@ Cannot create symlink because target does not exist: fi # # If using the FV3_RRFS_v1beta physics suite, there are two files (that -# contain statistics of the orography) that are needed by the drag +# contain statistics of the orography) that are needed by the drag # parameterization in that suite. Below, symlinks to these are created # in the run directory. Note that the symlinks must have specific names -# that the FV3 model is hardcoded to recognize ("${CRES}_" and "halo0" +# that the FV3 model is hardcoded to recognize ("${CRES}_" and "halo0" # must be stripped from the file names). We use those below. # if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then -# Symlink to orographic statistics fields file with "${CRES}_" and "halo0" +# Symlink to orographic statistics fields file with "${CRES}_" and "halo0" # stripped from name. target="${FIXLAM}/${CRES}${DOT_OR_USCORE}oro_data_ls.tile${TILE_RGNL}.halo${NH0}.nc" symlink="oro_data_ls.nc" @@ -312,7 +318,7 @@ fi # gfs_bndy*.nc # gfs_ctrl.nc # -# Some of these files (gfs_ctrl.nc, gfs_bndy*.nc) already exist, but +# Some of these files (gfs_ctrl.nc, gfs_bndy*.nc) already exist, but # others do not. Thus, create links with these names to the appropriate # files (in this case the initial condition and surface files only). # @@ -353,9 +359,9 @@ fi #----------------------------------------------------------------------- # # Create links in the current run directory to fixed (i.e. static) files -# in the FIXam directory. These links have names that are set to the +# in the FIXam directory. These links have names that are set to the # names of files that the forecast model expects to exist in the current -# working directory when the forecast model executable is called (and +# working directory when the forecast model executable is called (and # that is just the run directory). # #----------------------------------------------------------------------- @@ -363,7 +369,7 @@ fi cd_vrfy ${run_dir} print_info_msg "$VERBOSE" " -Creating links in the current run directory (run_dir) to fixed (i.e. +Creating links in the current run directory (run_dir) to fixed (i.e. static) files in the FIXam directory: FIXam = \"${FIXam}\" run_dir = \"${run_dir}\"" @@ -397,8 +403,8 @@ done # #----------------------------------------------------------------------- # -# If running this cycle/ensemble member combination more than once (e.g. -# using rocotoboot), remove any time stamp file that may exist from the +# If running this cycle/ensemble member combination more than once (e.g. +# using rocotoboot), remove any time stamp file that may exist from the # previous attempt. # #----------------------------------------------------------------------- @@ -409,13 +415,13 @@ rm_vrfy -f time_stamp.out #----------------------------------------------------------------------- # # Create links in the current run directory to cycle-independent (and -# ensemble-member-independent) model input files in the main experiment +# ensemble-member-independent) model input files in the main experiment # directory. # #----------------------------------------------------------------------- # print_info_msg "$VERBOSE" " -Creating links in the current run directory to cycle-independent model +Creating links in the current run directory to cycle-independent model input files in the main experiment directory..." relative_or_null="" @@ -432,13 +438,6 @@ if [ "${DO_ENSEMBLE}" = TRUE ]; then else ln_vrfy -sf ${relative_or_null} ${FV3_NML_FP} ${run_dir} fi - -ln_vrfy -sf ${relative_or_null} ${CCPP_PHYS_SUITE_FP} ${run_dir} -if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - ln_vrfy -sf ${relative_or_null} $EXPTDIR/CCN_ACTIVATE.BIN ${run_dir} -fi # #----------------------------------------------------------------------- # @@ -451,17 +450,17 @@ create_model_configure_file \ cdate="$cdate" \ nthreads=${OMP_NUM_THREADS:-1} \ run_dir="${run_dir}" || print_err_msg_exit "\ -Call to function to create a model configuration file for the current +Call to function to create a model configuration file for the current cycle's (cdate) run directory (run_dir) failed: cdate = \"${cdate}\" run_dir = \"${run_dir}\"" # #----------------------------------------------------------------------- # -# If running ensemble forecasts, create a link to the cycle-specific -# diagnostic tables file in the cycle directory. Note that this link -# should not be made if not running ensemble forecasts because in that -# case, the cycle directory is the run directory (and we would be creating +# If running ensemble forecasts, create a link to the cycle-specific +# diagnostic tables file in the cycle directory. Note that this link +# should not be made if not running ensemble forecasts because in that +# case, the cycle directory is the run directory (and we would be creating # a symlink with the name of a file that already exists). # #----------------------------------------------------------------------- @@ -486,15 +485,15 @@ export OMP_STACKSIZE=1024m #----------------------------------------------------------------------- # # Run the FV3-LAM model. Note that we have to launch the forecast from -# the current cycle's directory because the FV3 executable will look for -# input files in the current directory. Since those files have been +# the current cycle's directory because the FV3 executable will look for +# input files in the current directory. Since those files have been # staged in the cycle directory, the current directory must be the cycle # directory (which it already is). # #----------------------------------------------------------------------- # $APRUN ${FV3_EXEC_FP} || print_err_msg_exit "\ -Call to executable to run FV3-LAM forecast returned with nonzero exit +Call to executable to run FV3-LAM forecast returned with nonzero exit code." # #----------------------------------------------------------------------- diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 02140cfe3..7391b3456 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -518,25 +518,6 @@ print_info_msg "$VERBOSE" " Copying the CCPP physics suite definition XML file from its location in the forecast model directory sturcture to the experiment directory..." cp_vrfy "${CCPP_PHYS_SUITE_IN_CCPP_FP}" "${CCPP_PHYS_SUITE_FP}" -# -# If using a physics suite that includes the Thompson microphysics -# parameterization, copy the fixed file containing cloud condensation -# nuclei (CCN) data that is needed by that parameterization. -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_v0" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ] || \ - [ "${CCPP_PHYS_SUITE}" = "FV3_GSD_SAR" ]; then - print_info_msg "$VERBOSE" " -Copying the fixed file containing cloud condensation nuclei (CCN) data -(needed by the Thompson microphysics parameterization) to the experiment -directory..." - cp_vrfy "${FIXgsm}/CCN_ACTIVATE.BIN" "$EXPTDIR" -fi - - - - - # #----------------------------------------------------------------------- # diff --git a/ush/set_ozone_param.sh b/ush/set_ozone_param.sh index df2dfa704..5fb90f839 100644 --- a/ush/set_ozone_param.sh +++ b/ush/set_ozone_param.sh @@ -203,9 +203,9 @@ After setting the file name of the ozone production/loss file in the FIXgsm directory (based on the ozone parameterization specified in the CCPP suite definition file), the array specifying the mapping between the symlinks that need to be created in the cycle directories and the -files in the FIXgsm directory is: +files in the FIXam directory is: -CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING = ( \\ + CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING = ( \\ " msg="$msg"$( printf "\"%s\" \\\\\n" "${CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING[@]}" ) msg="$msg"$( printf "\n)" ) diff --git a/ush/set_thompson_mp_fix_files.sh b/ush/set_thompson_mp_fix_files.sh new file mode 100644 index 000000000..a2bd16c48 --- /dev/null +++ b/ush/set_thompson_mp_fix_files.sh @@ -0,0 +1,168 @@ +# +#----------------------------------------------------------------------- +# +# This file defins a function that first checks whether the Thompson +# microphysics parameterization is being called by the selected physics +# suite. If not, it does nothing else. If so, it modifies the workflow +# arrays FIXgsm_FILES_TO_COPY_TO_FIXam and CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING +# to ensure that fixed files needed by this parameterization are copied +# to the FIXam directory and that appropriate symlinks to these files +# are created in the run directories. +# +#----------------------------------------------------------------------- +# +function set_thompson_mp_fix_files() { +# +#----------------------------------------------------------------------- +# +# 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). +# +#----------------------------------------------------------------------- +# + local scrfunc_fp=$( readlink -f "${BASH_SOURCE[0]}" ) + local scrfunc_fn=$( basename "${scrfunc_fp}" ) + local scrfunc_dir=$( dirname "${scrfunc_fp}" ) +# +#----------------------------------------------------------------------- +# +# Get the name of this function. +# +#----------------------------------------------------------------------- +# + local func_name="${FUNCNAME[0]}" +# +#----------------------------------------------------------------------- +# +# 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). +# +#----------------------------------------------------------------------- +# + local valid_args=( \ + "ccpp_phys_suite_fp" \ + ) + 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 +# +#----------------------------------------------------------------------- +# +# Declare local variables. +# +#----------------------------------------------------------------------- +# + local thompson_mp_name \ + regex_search \ + thompson_mp_name_or_null \ + thompson_mp_is_used \ + thompson_mp_fix_files \ + num_files \ + mapping \ + msg +# +#----------------------------------------------------------------------- +# +# Check the suite definition file to see whether the Thompson microphysics +# parameterization is being used. +# +#----------------------------------------------------------------------- +# + thompson_mp_name="mp_thompson" + regex_search="^[ ]*(${thompson_mp_name})<\/scheme>[ ]*$" + thompson_mp_name_or_null=$( sed -r -n -e "s/${regex_search}/\1/p" "${ccpp_phys_suite_fp}" ) + + if [ "${thompson_mp_name_or_null}" = "${thompson_mp_name}" ]; then + thompson_mp_is_used="TRUE" + elif [ -z "${thompson_mp_name_or_null}" ]; then + thompson_mp_is_used="FALSE" + else + print_err_msg_exit "\ +Unexpected value returned for thompson_mp_name_or_null: + thompson_mp_name_or_null = \"${thompson_mp_name_or_null}\" +This variable should be set to either \"${thompson_mp_name}\" or an empty +string." + fi +# +#----------------------------------------------------------------------- +# +# If the Thompson microphysics parameterization is being used, then +# append the names of the fixed files needed by this parameterization to +# the workflow array FIXgsm_FILES_TO_COPY_TO_FIXam, and append to the +# workflow array CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING the mappings +# between these files and the names of the corresponding symlinks that +# need to be created in the run directories. +# +#----------------------------------------------------------------------- +# + if [ "${thompson_mp_is_used}" = "TRUE" ]; then + + thompson_mp_fix_files=( \ + "CCN_ACTIVATE.BIN" \ + "freezeH2O.dat" \ + "qr_acr_qg.dat" \ + "qr_acr_qs.dat" \ + ) + + FIXgsm_FILES_TO_COPY_TO_FIXam+=( "${thompson_mp_fix_files[@]}" ) + + num_files=${#thompson_mp_fix_files[@]} + for (( i=0; i<${num_files}; i++ )); do + mapping="${thompson_mp_fix_files[i]} | ${thompson_mp_fix_files[i]}" + CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING+=( "${mapping}" ) + done + + msg=" +Since the Thompson microphysics parameterization is being used by this +physics suite (CCPP_PHYS_SUITE), the names of the fixed files needed by +this scheme have been appended to the array FIXgsm_FILES_TO_COPY_TO_FIXam, +and the mappings between these files and the symlinks that need to be +created in the cycle directories have been appended to the array +CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING. After these modifications, the +values of these parameters are as follows: + + CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\" + + FIXgsm_FILES_TO_COPY_TO_FIXam = ( \\ +" + msg="$msg"$( printf "\"%s\" \\\\\n" "${FIXgsm_FILES_TO_COPY_TO_FIXam[@]}" ) + msg="$msg"$( printf "\n)" ) + msg="$msg + + CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING = ( \\ +" + msg="$msg"$( printf "\"%s\" \\\\\n" "${CYCLEDIR_LINKS_TO_FIXam_FILES_MAPPING[@]}" ) + msg="$msg"$( printf "\n)" ) + print_info_msg "$msg" + + fi +# +#----------------------------------------------------------------------- +# +# Restore the shell options saved at the beginning of this script/function. +# +#----------------------------------------------------------------------- +# + { restore_shell_opts; } > /dev/null 2>&1 + +} + diff --git a/ush/setup.sh b/ush/setup.sh index d25fdd6c0..058973d5d 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -62,6 +62,7 @@ cd_vrfy ${scrfunc_dir} . ./set_gridparams_ESGgrid.sh . ./link_fix.sh . ./set_ozone_param.sh +. ./set_thompson_mp_fix_files.sh # #----------------------------------------------------------------------- # @@ -2116,7 +2117,19 @@ mkdir_vrfy -p "$EXPTDIR" - +# +#----------------------------------------------------------------------- +# +# Call the function that, if the Thompson microphysics parameterization +# is being called by the physics suite, modifies certain workflow arrays +# to ensure that fixed files needed by this parameterization are copied +# to the FIXam directory and appropriate symlinks to them are created in +# the run directories. +# +#----------------------------------------------------------------------- +# +set_thompson_mp_fix_files \ + ccpp_phys_suite_fp="${CCPP_PHYS_SUITE_IN_CCPP_FP}" From b71dd13929c17fc0790b95ec6cf113efe0278a18 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 16 Oct 2020 18:02:00 -0500 Subject: [PATCH 27/39] Add orion stanzas to the ex-scripts for the make_ics and make_lbcs tasks. This was probably inadvertantly changed during a conflict resolution with another PR. --- scripts/exregional_make_ics.sh | 5 +++++ scripts/exregional_make_lbcs.sh | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/scripts/exregional_make_ics.sh b/scripts/exregional_make_ics.sh index 7463de5fb..e684657b5 100755 --- a/scripts/exregional_make_ics.sh +++ b/scripts/exregional_make_ics.sh @@ -93,6 +93,11 @@ case "$MACHINE" in APRUN="srun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + "JET") ulimit -s unlimited APRUN="srun" diff --git a/scripts/exregional_make_lbcs.sh b/scripts/exregional_make_lbcs.sh index 7967c68dd..61dd0ebff 100755 --- a/scripts/exregional_make_lbcs.sh +++ b/scripts/exregional_make_lbcs.sh @@ -93,6 +93,11 @@ case "$MACHINE" in APRUN="srun" ;; + "ORION") + ulimit -s unlimited + APRUN="srun" + ;; + "JET") ulimit -s unlimited APRUN="srun" From 30dfc8e9efb52ebaa03162127bd5e94890cd81c5 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 16 Oct 2020 19:18:53 -0500 Subject: [PATCH 28/39] Clean up comments; remove commented out code. --- scripts/exregional_make_grid.sh | 2 -- scripts/exregional_make_orog.sh | 2 -- ush/config_defaults.sh | 64 +++++++++++++-------------------- ush/generate_FV3LAM_wflow.sh | 22 ++---------- ush/setup.sh | 48 ------------------------- 5 files changed, 27 insertions(+), 111 deletions(-) diff --git a/scripts/exregional_make_grid.sh b/scripts/exregional_make_grid.sh index 8f025bbc5..a7921b5bb 100755 --- a/scripts/exregional_make_grid.sh +++ b/scripts/exregional_make_grid.sh @@ -82,8 +82,6 @@ print_input_args valid_args # # The orography code runs with threads. On Cray, the code is optimized # for six threads. Do not change. -# Note that OMP_NUM_THREADS and OMP_STACKSIZE only affect the threaded <== I don't think this is true. Remove?? -# executions on Cray; they don't affect executions on theia. # #----------------------------------------------------------------------- # diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index 2b8c07dfe..bcdeb2bee 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -78,8 +78,6 @@ print_input_args valid_args # # The orography code runs with threads. On Cray, the code is optimized # for six threads. Do not change. -# Note that OMP_NUM_THREADS and OMP_STACKSIZE only affect the threaded <== I don't think this is true. Remove?? -# executions on Cray; they don't affect executions on theia. # #----------------------------------------------------------------------- # diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index eb3553464..251d6f061 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -51,39 +51,6 @@ RUN_ENVIR="nco" # order for the experiment generation script to set it depending on the # machine. # -# QUEUE_DEFAULT: -# The default queue or QOS (if using the slurm job scheduler, where QOS -# is Quality of Service) to which workflow tasks are submitted. If a -# task does not have a specific variable that specifies the queue to which -# it will be submitted (e.g. QUEUE_HPSS, QUEUE_FCST; see below), it will -# be submitted to the queue specified by this variable. If this is not -# set or is set to an empty string, it will be (re)set to a machine- -# dependent value. -# -## QUEUE_DEFAULT_TAG: -## The rocoto xml tag to use for specifying the default queue. For most -## platforms this should be "queue" -# -# QUEUE_HPSS: -# The queue or QOS to which the tasks that get or create links to external -# model files [which are needed to generate initial conditions (ICs) and -# lateral boundary conditions (LBCs)] are submitted. If this is not set -# or is set to an empty string, it will be (re)set to a machine-dependent -# value. -# -## QUEUE_HPSS_TAG: -## The rocoto xml tag to use for specifying the HPSS queue. For slurm-based -## platforms this is typically "partition", for others it may be "queue" -# -# QUEUE_FCST: -# The queue or QOS to which the task that runs a forecast is submitted. -# If this is not set or set to an empty string, it will be (re)set to a -# machine-dependent value. -# -## QUEUE_FCST_TAG: -## The rocoto xml tag to use for specifying the fcst queue. For most -## platforms this should be "queue" -# # PARTITION_DEFAULT: # If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), # the default partition to which to submit workflow tasks. If a task @@ -94,6 +61,15 @@ RUN_ENVIR="nco" # machine-dependent value. This is not used if SCHED is not set to # "slurm". # +# QUEUE_DEFAULT: +# The default queue or QOS (if using the slurm job scheduler, where QOS +# is Quality of Service) to which workflow tasks are submitted. If a +# task does not have a specific variable that specifies the queue to which +# it will be submitted (e.g. QUEUE_HPSS, QUEUE_FCST; see below), it will +# be submitted to the queue specified by this variable. If this is not +# set or is set to an empty string, it will be (re)set to a machine- +# dependent value. +# # PARTITION_HPSS: # If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), # the partition to which the tasks that get or create links to external @@ -102,6 +78,13 @@ RUN_ENVIR="nco" # or is set to an empty string, it will be (re)set to a machine-dependent # value. This is not used if SCHED is not set to "slurm". # +# QUEUE_HPSS: +# The queue or QOS to which the tasks that get or create links to external +# model files [which are needed to generate initial conditions (ICs) and +# lateral boundary conditions (LBCs)] are submitted. If this is not set +# or is set to an empty string, it will be (re)set to a machine-dependent +# value. +# # PARTITION_FCST: # If using the slurm job scheduler (i.e. if SCHED is set to "slurm"), # the partition to which the task that runs forecasts is submitted. If @@ -109,6 +92,11 @@ RUN_ENVIR="nco" # machine-dependent value. This is not used if SCHED is not set to # "slurm". # +# QUEUE_FCST: +# The queue or QOS to which the task that runs a forecast is submitted. +# If this is not set or set to an empty string, it will be (re)set to a +# machine-dependent value. +# # mach_doc_end # #----------------------------------------------------------------------- @@ -116,16 +104,12 @@ RUN_ENVIR="nco" MACHINE="BIG_COMPUTER" ACCOUNT="project_name" SCHED="" -QUEUE_DEFAULT="" -#QUEUE_DEFAULT_TAG="queue" -QUEUE_HPSS="" -#QUEUE_HPSS_TAG="partition" -QUEUE_FCST="" -#QUEUE_FCST_TAG="queue" - PARTITION_DEFAULT="" +QUEUE_DEFAULT="" PARTITION_HPSS="" +QUEUE_HPSS="" PARTITION_FCST="" +QUEUE_FCST="" # #----------------------------------------------------------------------- # diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 071bdc4fb..09682b3a0 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -159,18 +159,6 @@ if [ "${DO_ENSEMBLE}" = "TRUE" ]; then slash_ensmem_subdir="/mem#${ensmem_indx_name}#" fi -# -# To see if the following is enough (i.e. to see whether the if-statements -# below are really needed), have to run with the following lines uncommented -# on systems that don't use slurm. -# The following seem to work ok on orion, i.e. passing an empty partition -# setting in the rocoto xml, like this: -# This causes rocoto/slurm to submit to the default partition (called "orion"). -# -#partition_default_spec="${PARTITION_DEFAULT}" -#partition_hpss_spec="${PARTITION_HPSS}" -#partition_fcst_spec="${PARTITION_FCST}" - partition_default_spec="\"\"" if [ ! -z "${PARTITION_DEFAULT}" ]; then partition_default_spec="${PARTITION_DEFAULT}" @@ -186,22 +174,18 @@ if [ ! -z "${PARTITION_FCST}" ]; then partition_fcst_spec="${PARTITION_FCST}" fi -# 'queue_default_tag': ${QUEUE_DEFAULT_TAG} -# 'queue_hpss_tag': ${QUEUE_HPSS_TAG} -# 'queue_fcst_tag': ${QUEUE_FCST_TAG} - settings="\ # # Parameters needed by the job scheduler. # 'account': $ACCOUNT 'sched': $SCHED - 'queue_default': ${QUEUE_DEFAULT} - 'queue_hpss': ${QUEUE_HPSS} - 'queue_fcst': ${QUEUE_FCST} 'partition_default_spec': ${partition_default_spec} + 'queue_default': ${QUEUE_DEFAULT} 'partition_hpss_spec': ${partition_hpss_spec} + 'queue_hpss': ${QUEUE_HPSS} 'partition_fcst_spec': ${partition_fcst_spec} + 'queue_fcst': ${QUEUE_FCST} 'machine': ${MACHINE} # # Workflow task names. diff --git a/ush/setup.sh b/ush/setup.sh index 89121f899..024a14aef 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -366,7 +366,6 @@ case $MACHINE in SCHED="lsfcray" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} -# QUEUE_HPSS_TAG="queue" # lsfcray does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"dev"} ;; @@ -375,21 +374,16 @@ case $MACHINE in SCHED="lsf" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"dev"} QUEUE_HPSS=${QUEUE_HPSS:-"dev_transfer"} -# QUEUE_HPSS_TAG="queue" # lsf does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"dev"} ;; "HERA") NCORES_PER_NODE=40 SCHED="${SCHED:-slurm}" - PARTITION_DEFAULT=${PARTITION_DEFAULT:-"hera"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - PARTITION_HPSS=${PARTITION_HPSS:-"service"} QUEUE_HPSS=${QUEUE_HPSS:-"batch"} -# QUEUE_HPSS_TAG="queue" - PARTITION_FCST=${PARTITION_FCST:-"hera"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; @@ -397,14 +391,10 @@ case $MACHINE in "ORION") NCORES_PER_NODE=40 SCHED="${SCHED:-slurm}" - PARTITION_DEFAULT=${PARTITION_DEFAULT:-"orion"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - PARTITION_HPSS=${PARTITION_HPSS:-"service"} QUEUE_HPSS=${QUEUE_HPSS:-"batch"} -# QUEUE_HPSS_TAG="queue" - PARTITION_FCST=${PARTITION_FCST:-"orion"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; @@ -412,13 +402,10 @@ case $MACHINE in "JET") NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" - PARTITION_DEFAULT=${PARTITION_DEFAULT:-"sjet,vjet,kjet,xjet"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"batch"} - PARTITION_HPSS=${PARTITION_HPSS:-"service"} QUEUE_HPSS=${QUEUE_HPSS:-"batch"} - PARTITION_FCST=${PARTITION_FCST:-"sjet,vjet,kjet,xjet"} QUEUE_FCST=${QUEUE_FCST:-"batch"} ;; @@ -436,7 +423,6 @@ case $MACHINE in SCHED="${SCHED:-pbspro}" QUEUE_DEFAULT=${QUEUE_DEFAULT:-"regular"} QUEUE_HPSS=${QUEUE_HPSS:-"regular"} -# QUEUE_HPSS_TAG="queue" # pbspro does not support "partition" tag QUEUE_FCST=${QUEUE_FCST:-"regular"} ;; @@ -449,40 +435,6 @@ case $MACHINE in ;; esac - - -# Is the following needed??? -# -#if [ "$SCHED" = "slurm" ]; then -# -# if [ -z "${PARTITION_DEFAULT}" ]; then -# print_err_msg_exit "\ -#When SCHED is set to \"slurm\", the variable specifying the default -#slurm partition to which to submit tasks (PARTITION_DEFAULT) cannot be -#empty: -# SCHED = \"$SCHED\" -# PARTITION_DEFAULT = \"${PARTITION_DEFAULT}\"" -# fi -# -# if [ -z "${PARTITION_HPSS}" ]; then -# print_err_msg_exit "\ -#When SCHED is set to \"slurm\", the variable specifying the slurm -#partition to which to submit the tasks that fetch/copy external model -#files (PARTITION_HPSS) cannot be empty: -# SCHED = \"$SCHED\" -# PARTITION_HPSS = \"${PARTITION_HPSS}\"" -# fi -# -# if [ -z "${PARTITION_FCST}" ]; then -# print_err_msg_exit "\ -#When SCHED is set to \"slurm\", the variable specifying the slurm -#partition to which to submit the forecast task (PARTITION_FCST) cannot -#be empty: -# SCHED = \"$SCHED\" -# PARTITION_DEFAULT = \"${PARTITION_FCST}\"" -# fi -# -#fi # #----------------------------------------------------------------------- # From ccc5505263f8ba26da13fce71710dac6e283ffb5 Mon Sep 17 00:00:00 2001 From: Michael Kavulich Date: Tue, 20 Oct 2020 08:33:45 -0600 Subject: [PATCH 29/39] RRFS_v1beta SDF changes after reverting from GSL to GFS GWD suite (#322) (#327) ## DESCRIPTION OF CHANGES: Removed checks on the RRFS_v1beta SDF implemented for use with the GSL GWD suite (now uses the GFS GWD suite). No longer copies staged orography files necessary for the GSL GWD suite. ## TESTS CONDUCTED: Runs to completion on Hera. End-to-end runs DOT_OR_USCORE and suite_FV3_RRFS_v1beta succeeded on Cheyenne. Co-authored-by: JeffBeck-NOAA <55201531+JeffBeck-NOAA@users.noreply.github.com> --- scripts/exregional_make_orog.sh | 19 ------------------ scripts/exregional_run_fcst.sh | 30 ---------------------------- tests/run_experiments.sh | 35 --------------------------------- ush/config_defaults.sh | 20 ------------------- ush/link_fix.sh | 7 ------- ush/setup.sh | 35 --------------------------------- ush/templates/FV3.input.yml | 1 - 7 files changed, 147 deletions(-) diff --git a/scripts/exregional_make_orog.sh b/scripts/exregional_make_orog.sh index fece0763e..77d5b6c21 100755 --- a/scripts/exregional_make_orog.sh +++ b/scripts/exregional_make_orog.sh @@ -360,25 +360,6 @@ raw_orog_fn="${raw_orog_fn_prefix}.${fn_suffix_with_halo}" raw_orog_fp="${raw_dir}/${raw_orog_fn}" mv_vrfy "${raw_orog_fp_orig}" "${raw_orog_fp}" -# -#----------------------------------------------------------------------- -# -# Copy the two orography files needed for the drag suite in the FV3_RRFS_v1beta -# physics suite. -# -# Note that the following is a temporary fix. We need a long-term solution -# that calls a script or program to generates the necessary files (instead -# of copying them). -# -#----------------------------------------------------------------------- -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then - cp_vrfy ${GWD_RRFS_v1beta_DIR}/*_ls*.nc ${OROG_DIR} - cp_vrfy ${GWD_RRFS_v1beta_DIR}/*_ss*.nc ${OROG_DIR} -fi - -print_info_msg "$VERBOSE" " -Orography file generation complete." # #----------------------------------------------------------------------- # diff --git a/scripts/exregional_run_fcst.sh b/scripts/exregional_run_fcst.sh index cc92781fc..e1eeeee2b 100755 --- a/scripts/exregional_run_fcst.sh +++ b/scripts/exregional_run_fcst.sh @@ -254,36 +254,6 @@ Cannot create symlink because target does not exist: target = \"$target\"" fi # -# If using the FV3_RRFS_v1beta physics suite, there are two files (that -# contain statistics of the orography) that are needed by the drag -# parameterization in that suite. Below, symlinks to these are created -# in the run directory. Note that the symlinks must have specific names -# that the FV3 model is hardcoded to recognize ("${CRES}_" and "halo0" -# must be stripped from the file names). We use those below. -# -if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then -# Symlink to orographic statistics fields file with "${CRES}_" and "halo0" -# stripped from name. - target="${FIXLAM}/${CRES}${DOT_OR_USCORE}oro_data_ls.tile${TILE_RGNL}.halo${NH0}.nc" - symlink="oro_data_ls.nc" - if [ -f "${target}" ]; then - ln_vrfy -sf ${relative_or_null} $target $symlink - else - print_err_msg_exit "\ -Cannot create symlink because target does not exist: - target = \"$target}\"" - fi - target="${FIXLAM}/${CRES}${DOT_OR_USCORE}oro_data_ss.tile${TILE_RGNL}.halo${NH0}.nc" - symlink="oro_data_ss.nc" - if [ -f "${target}" ]; then - ln_vrfy -sf ${relative_or_null} $target $symlink - else - print_err_msg_exit "\ -Cannot create symlink because target does not exist: - target = \"$target}\"" - fi -fi -# # Symlink to halo-4 orography file with "${CRES}_" stripped from name. # # If this link is not created, then the code hangs with an error message diff --git a/tests/run_experiments.sh b/tests/run_experiments.sh index 753e6917e..01a27e1b0 100755 --- a/tests/run_experiments.sh +++ b/tests/run_experiments.sh @@ -579,41 +579,6 @@ SFC_CLIMO_DIR=\"${SFC_CLIMO_DIR}\"" # #----------------------------------------------------------------------- # -# If using the FV3_RRFS_v1beta physics suite, set the base directory in -# which the pregenerated orography statistics files needed by the gravity -# wave drag parameterization in this suite are located. -# -#----------------------------------------------------------------------- -# - if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then - - if [ "$MACHINE" = "HERA" ]; then - GWD_RRFS_v1beta_BASEDIR="/scratch2/BMC/det/FV3LAM_pregen/orog" - elif [ "$MACHINE" = "JET" ]; then - GWD_RRFS_v1beta_BASEDIR="/lfs4/BMC/wrfruc/FV3LAM_pregen/orog" - elif [ "$MACHINE" = "CHEYENNE" ]; then - GWD_RRFS_v1beta_BASEDIR="/glade/p/ral/jntp/UFS_CAM/FV3LAM_pregen/orog" - else - print_err_msg_exit "\ -The base directory (GWD_RRFS_v1beta_BASEDIR) containing the pregenerated -orography statistics files needed by the gravity wave drag parameterization -in the FV3_RRFS_v1beta physics suite has not been specified for this -machine (MACHINE): - MACHINE= \"${MACHINE}\"" - fi - - str=${str}" -# -# Base directory containing the pregenerated orography statistics files -# needed by the gravity wave drag parameterization in the FV3_RRFS_v1beta -# physics suite. -# -GWD_RRFS_v1beta_BASEDIR=\"${GWD_RRFS_v1beta_BASEDIR}\"" - - fi -# -#----------------------------------------------------------------------- -# # # #----------------------------------------------------------------------- diff --git a/ush/config_defaults.sh b/ush/config_defaults.sh index e5fa2d4be..8b4ae3225 100644 --- a/ush/config_defaults.sh +++ b/ush/config_defaults.sh @@ -1238,26 +1238,6 @@ HALO_BLEND=0 # #----------------------------------------------------------------------- # -# GWD_RRFS_v1beta_BASEDIR: -# Temporary workflow variable specifies the base directory in which to -# look for certain fixed orography files needed only by the gravity wave -# drag parameterization in the FV3_RRFS_v1beta physics suite. This variable -# is added in order to avoid including hard-coded paths in the workflow -# scripts. Currently, the workflow simply copies the necessary files -# from a subdirectory under this directory (named according to the specified -# predefined grid) to the orography directory (OROG_DIR) under the -# experiment directory. -# -# Note that this variable is only used when using the FV3_RRFS_v1beta -# physics suite. This variable should be removed from the workflow once -# there is a script that generates these files for any grid. -# -#----------------------------------------------------------------------- -# -GWD_RRFS_v1beta_BASEDIR="" -# -#----------------------------------------------------------------------- -# # USE_FVCOM: # Flag set to update surface conditions in FV3-LAM with fields generated # from the Finite Volume Community Ocean Model (FVCOM). This will diff --git a/ush/link_fix.sh b/ush/link_fix.sh index e4bccdd83..dd4e008c9 100755 --- a/ush/link_fix.sh +++ b/ush/link_fix.sh @@ -245,13 +245,6 @@ Creating links in the FIXLAM directory to the grid files..." "C*${DOT_OR_USCORE}oro_data.tile${TILE_RGNL}.halo${NH0}.nc" \ "C*${DOT_OR_USCORE}oro_data.tile${TILE_RGNL}.halo${NH4}.nc" \ ) - if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then - fns+=( \ - "C*${DOT_OR_USCORE}oro_data_ss.tile${TILE_RGNL}.halo${NH0}.nc" \ - "C*${DOT_OR_USCORE}oro_data_ls.tile${TILE_RGNL}.halo${NH0}.nc" \ - ) - fi - fps=( "${fns[@]/#/${OROG_DIR}/}" ) run_task="${RUN_TASK_MAKE_OROG}" ;; diff --git a/ush/setup.sh b/ush/setup.sh index 058973d5d..7a50b5d08 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -930,40 +930,6 @@ fi # #----------------------------------------------------------------------- # -# If using the FV3_RRFS_v1beta physics suite, make sure that the directory -# from which certain fixed orography files will be copied to the experiment -# directory actually exists. Note that this is temporary code. It should -# be removed once there is a script that will create these orography files -# for any grid. -# -#----------------------------------------------------------------------- -# -GWD_RRFS_v1beta_DIR="${GWD_RRFS_v1beta_BASEDIR}/${PREDEF_GRID_NAME}" -if [ "${CCPP_PHYS_SUITE}" = "FV3_RRFS_v1beta" ]; then - if [ -z "${PREDEF_GRID_NAME}" ]; then - print_err_msg_exit "\ -A predefined grid name (PREDEF_GRID_NAME) must be specified when using -the FV3_RRFS_v1beta physic suite: - CCPP_PHYS_SUITE = \"${CCPP_PHYS_SUITE}\" - PREDEF_GRID_NAME = \"${PREDEF_GRID_NAME}\"" - else - if [ ! -d "${GWD_RRFS_v1beta_DIR}" ]; then - print_err_msg_exit "\ -The directory (GWD_RRFS_v1beta_DIR) that should contain the gravity wave -drag-related orography files for the FV3_RRFS_v1beta does not exist: - GWD_RRFS_v1beta_DIR = \"${GWD_RRFS_v1beta_DIR}\"" - elif [ ! "$( ls -A ${GWD_RRFS_v1beta_DIR} )" ]; then - print_err_msg_exit "\ -The directory (GWD_RRFS_v1beta_DIR) that should contain the gravity wave -drag related orography files for the FV3_RRFS_v1beta is empty: - GWD_RRFS_v1beta_DIR = \"${GWD_RRFS_v1beta_DIR}\"" - fi - fi -fi -# -# -#----------------------------------------------------------------------- -# # If the base directory (EXPT_BASEDIR) in which the experiment subdirectory # (EXPT_SUBDIR) will be located does not start with a "/", then it is # either set to a null string or contains a relative directory. In both @@ -2473,7 +2439,6 @@ CYCLE_BASEDIR="${CYCLE_BASEDIR}" GRID_DIR="${GRID_DIR}" OROG_DIR="${OROG_DIR}" SFC_CLIMO_DIR="${SFC_CLIMO_DIR}" -GWD_RRFS_v1beta_DIR="${GWD_RRFS_v1beta_DIR}" NDIGITS_ENSMEM_NAMES="${NDIGITS_ENSMEM_NAMES}" ENSMEM_NAMES=( $( printf "\"%s\" " "${ENSMEM_NAMES[@]}" )) diff --git a/ush/templates/FV3.input.yml b/ush/templates/FV3.input.yml index 268837c01..c9121dd64 100644 --- a/ush/templates/FV3.input.yml +++ b/ush/templates/FV3.input.yml @@ -54,7 +54,6 @@ FV3_RRFS_v1beta: imfshalcnv: -1 IMFDEEPCNV: -1 DO_MYNNSFCLAY: true - GWD_OPT: 3 do_deep: False atmos_model_nml: fdiag: 3 From 26b4089c906398a9a1560886d9eafe4e31cf90a3 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 20 Oct 2020 10:18:19 -0600 Subject: [PATCH 30/39] Move code involving xml from the generate script to the rocoto XML template. --- ush/generate_FV3LAM_wflow.sh | 38 +++++++++++++++++++--------------- ush/templates/FV3LAM_wflow.xml | 19 ++++++++++++++--- 2 files changed, 37 insertions(+), 20 deletions(-) diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 071bdc4fb..00d2ce800 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -171,25 +171,29 @@ fi #partition_hpss_spec="${PARTITION_HPSS}" #partition_fcst_spec="${PARTITION_FCST}" -partition_default_spec="\"\"" -if [ ! -z "${PARTITION_DEFAULT}" ]; then - partition_default_spec="${PARTITION_DEFAULT}" -fi - -partition_hpss_spec="\"\"" -if [ ! -z "${PARTITION_HPSS}" ]; then - partition_hpss_spec="${PARTITION_HPSS}" -fi - -partition_fcst_spec="\"\"" -if [ ! -z "${PARTITION_FCST}" ]; then - partition_fcst_spec="${PARTITION_FCST}" -fi +#partition_default_spec="\"\"" +#if [ ! -z "${PARTITION_DEFAULT}" ]; then +# partition_default_spec="${PARTITION_DEFAULT}" +#fi +# +#partition_hpss_spec="\"\"" +#if [ ! -z "${PARTITION_HPSS}" ]; then +# partition_hpss_spec="${PARTITION_HPSS}" +#fi +# +#partition_fcst_spec="\"\"" +#if [ ! -z "${PARTITION_FCST}" ]; then +# partition_fcst_spec="${PARTITION_FCST}" +#fi # 'queue_default_tag': ${QUEUE_DEFAULT_TAG} # 'queue_hpss_tag': ${QUEUE_HPSS_TAG} # 'queue_fcst_tag': ${QUEUE_FCST_TAG} +# 'partition_default_spec': ${partition_default_spec} +# 'partition_hpss_spec': ${partition_hpss_spec} +# 'partition_fcst_spec': ${partition_fcst_spec} + settings="\ # # Parameters needed by the job scheduler. @@ -199,9 +203,9 @@ settings="\ 'queue_default': ${QUEUE_DEFAULT} 'queue_hpss': ${QUEUE_HPSS} 'queue_fcst': ${QUEUE_FCST} - 'partition_default_spec': ${partition_default_spec} - 'partition_hpss_spec': ${partition_hpss_spec} - 'partition_fcst_spec': ${partition_fcst_spec} + 'partition_default': ${PARTITION_DEFAULT} + 'partition_hpss': ${PARTITION_HPSS} + 'partition_fcst': ${PARTITION_FCST} 'machine': ${MACHINE} # # Workflow task names. diff --git a/ush/templates/FV3LAM_wflow.xml b/ush/templates/FV3LAM_wflow.xml index c0343f3aa..7667e7730 100644 --- a/ush/templates/FV3LAM_wflow.xml +++ b/ush/templates/FV3LAM_wflow.xml @@ -63,9 +63,22 @@ tasks other than GET_EXTRN_ICS_TN, GET_EXTRN_LBCS_TN, and RUN_FCST_TN; the "HPSS" type is used for the GET_EXTRN_ICS_TN and GET_EXTRN_LBCS_TN tasks; and the "FCST" type is used for the RUN_FCST_TN task. --> -&ACCOUNT;&QUEUE_DEFAULT;{{ partition_default_spec }}"> -&ACCOUNT;&QUEUE_HPSS;{{ partition_hpss_spec }}"> -&ACCOUNT;&QUEUE_FCST;{{ partition_fcst_spec }}"> + +{%- if (partition_default != "") %} +&ACCOUNT;&QUEUE_DEFAULT;{{ partition_default }}"> +{%- else %} +&ACCOUNT;&QUEUE_DEFAULT;"> +{%- endif %} +{%- if (partition_hpss != "") %} +&ACCOUNT;&QUEUE_HPSS;{{ partition_hpss }}"> +{%- else %} +&ACCOUNT;&QUEUE_HPSS;"> +{%- endif %} +{%- if (partition_fcst != "") %} +&ACCOUNT;&QUEUE_FCST;{{ partition_fcst }}"> +{%- else %} +&ACCOUNT;&QUEUE_FCST;"> +{%- endif %} ]> From 12bd2e2925609f62ac34c3631ed1b0cab9d50190 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Tue, 20 Oct 2020 10:35:14 -0600 Subject: [PATCH 31/39] Delete unused/commented out lines. --- ush/generate_FV3LAM_wflow.sh | 41 +++--------------------------------- 1 file changed, 3 insertions(+), 38 deletions(-) diff --git a/ush/generate_FV3LAM_wflow.sh b/ush/generate_FV3LAM_wflow.sh index 00d2ce800..4104f4f3f 100755 --- a/ush/generate_FV3LAM_wflow.sh +++ b/ush/generate_FV3LAM_wflow.sh @@ -159,53 +159,18 @@ if [ "${DO_ENSEMBLE}" = "TRUE" ]; then slash_ensmem_subdir="/mem#${ensmem_indx_name}#" fi -# -# To see if the following is enough (i.e. to see whether the if-statements -# below are really needed), have to run with the following lines uncommented -# on systems that don't use slurm. -# The following seem to work ok on orion, i.e. passing an empty partition -# setting in the rocoto xml, like this: -# This causes rocoto/slurm to submit to the default partition (called "orion"). -# -#partition_default_spec="${PARTITION_DEFAULT}" -#partition_hpss_spec="${PARTITION_HPSS}" -#partition_fcst_spec="${PARTITION_FCST}" - -#partition_default_spec="\"\"" -#if [ ! -z "${PARTITION_DEFAULT}" ]; then -# partition_default_spec="${PARTITION_DEFAULT}" -#fi -# -#partition_hpss_spec="\"\"" -#if [ ! -z "${PARTITION_HPSS}" ]; then -# partition_hpss_spec="${PARTITION_HPSS}" -#fi -# -#partition_fcst_spec="\"\"" -#if [ ! -z "${PARTITION_FCST}" ]; then -# partition_fcst_spec="${PARTITION_FCST}" -#fi - -# 'queue_default_tag': ${QUEUE_DEFAULT_TAG} -# 'queue_hpss_tag': ${QUEUE_HPSS_TAG} -# 'queue_fcst_tag': ${QUEUE_FCST_TAG} - -# 'partition_default_spec': ${partition_default_spec} -# 'partition_hpss_spec': ${partition_hpss_spec} -# 'partition_fcst_spec': ${partition_fcst_spec} - settings="\ # # Parameters needed by the job scheduler. # 'account': $ACCOUNT 'sched': $SCHED - 'queue_default': ${QUEUE_DEFAULT} - 'queue_hpss': ${QUEUE_HPSS} - 'queue_fcst': ${QUEUE_FCST} 'partition_default': ${PARTITION_DEFAULT} + 'queue_default': ${QUEUE_DEFAULT} 'partition_hpss': ${PARTITION_HPSS} + 'queue_hpss': ${QUEUE_HPSS} 'partition_fcst': ${PARTITION_FCST} + 'queue_fcst': ${QUEUE_FCST} 'machine': ${MACHINE} # # Workflow task names. From bf652cffb18910b6d2ce084839cac9d5e56f61d0 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 21 Oct 2020 13:37:00 -0600 Subject: [PATCH 32/39] Changes to try to get the PR running on Odin and Stampede (not yet complete). * Remove the QUEUE_... statements in config.community.sh because they are overriding the default values for the machine in setup.sh. * Add new lines for PARTITION_... in the case-statement in setup.sh that sets the default values of PARTITION_... and QUEUE_.... For now, set the default values to blanks. These need to be properly specified, but I don't know the names of the partitions (nor QOS's) on these two machines. Probably Yunheng will need to fill these out and test. --- ush/config.community.sh | 4 ---- ush/setup.sh | 6 ++++++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/ush/config.community.sh b/ush/config.community.sh index 1b5b9018a..e63716cf9 100644 --- a/ush/config.community.sh +++ b/ush/config.community.sh @@ -2,10 +2,6 @@ MACHINE="hera" ACCOUNT="an_account" EXPT_SUBDIR="test_community" -QUEUE_DEFAULT="batch" -QUEUE_HPSS="service" -QUEUE_FCST="batch" - VERBOSE="TRUE" RUN_ENVIR="community" diff --git a/ush/setup.sh b/ush/setup.sh index 4b9727b64..d33a73d16 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -413,8 +413,11 @@ case $MACHINE in "ODIN") NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" + PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} + PARTITION_HPSS=${PARTITION_HPSS:-""} QUEUE_HPSS=${QUEUE_HPSS:-""} + PARTITION_FCST=${PARTITION_FCST:-""} QUEUE_FCST=${QUEUE_FCST:-""} ;; @@ -429,8 +432,11 @@ case $MACHINE in "STAMPEDE") NCORES_PER_NODE=68 SCHED="slurm" + PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} + PARTITION_HPSS=${PARTITION_HPSS:-""} QUEUE_HPSS=${QUEUE_HPSS:-"development"} + PARTITION_FCST=${PARTITION_FCST:-""} QUEUE_FCST=${QUEUE_FCST:-"normal"} ;; From 4fcf764ba5b7e7e4151e72bbdc94243f26f467df Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 21 Oct 2020 15:52:16 -0500 Subject: [PATCH 33/39] Fix in run_post.sh wrapper script to use 3-digit forecast hour instead of 2. --- ush/wrappers/run_post.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ush/wrappers/run_post.sh b/ush/wrappers/run_post.sh index 174cc62b5..1c8f3d4df 100755 --- a/ush/wrappers/run_post.sh +++ b/ush/wrappers/run_post.sh @@ -10,6 +10,6 @@ export ENSMEM_INDX="" num_fcst_hrs=${FCST_LEN_HRS} for (( i=0; i<=$((num_fcst_hrs)); i++ )); do - export fhr=`printf "%02i" ${i}` + export fhr=`printf "%03i" ${i}` ${JOBSDIR}/JREGIONAL_RUN_POST done From 11fa204dc2e1985c746372d159960df00a602039 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 21 Oct 2020 17:31:49 -0500 Subject: [PATCH 34/39] Set the PARTITION_... variables on Odin and Stampede as specified by Yunheng Wang. Still need to set QUEUE_... for these machines. --- ush/setup.sh | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ush/setup.sh b/ush/setup.sh index d33a73d16..ab2b20c52 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -413,11 +413,11 @@ case $MACHINE in "ODIN") NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" - PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} + PARTITION_DEFAULT=${PARTITION_DEFAULT:-"workq"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} - PARTITION_HPSS=${PARTITION_HPSS:-""} + PARTITION_HPSS=${PARTITION_HPSS:-"workq"} QUEUE_HPSS=${QUEUE_HPSS:-""} - PARTITION_FCST=${PARTITION_FCST:-""} + PARTITION_FCST=${PARTITION_FCST:-"workq"} QUEUE_FCST=${QUEUE_FCST:-""} ;; @@ -432,11 +432,11 @@ case $MACHINE in "STAMPEDE") NCORES_PER_NODE=68 SCHED="slurm" - PARTITION_DEFAULT=${PARTITION_DEFAULT:-""} + PARTITION_DEFAULT=${PARTITION_DEFAULT:-"normal"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} - PARTITION_HPSS=${PARTITION_HPSS:-""} + PARTITION_HPSS=${PARTITION_HPSS:-"normal"} QUEUE_HPSS=${QUEUE_HPSS:-"development"} - PARTITION_FCST=${PARTITION_FCST:-""} + PARTITION_FCST=${PARTITION_FCST:-"normal"} QUEUE_FCST=${QUEUE_FCST:-"normal"} ;; From b487e27a8e157b4500294d635b3f0223ad050ab4 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 21 Oct 2020 19:31:56 -0500 Subject: [PATCH 35/39] Set the QUEUE_... variables for Odin and Stampede as specified by Yunheng Wang. --- ush/setup.sh | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/ush/setup.sh b/ush/setup.sh index ab2b20c52..f9d0c1789 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -414,11 +414,11 @@ case $MACHINE in NCORES_PER_NODE=24 SCHED="${SCHED:-slurm}" PARTITION_DEFAULT=${PARTITION_DEFAULT:-"workq"} - QUEUE_DEFAULT=${QUEUE_DEFAULT:-""} + QUEUE_DEFAULT=${QUEUE_DEFAULT:-"workq"} PARTITION_HPSS=${PARTITION_HPSS:-"workq"} - QUEUE_HPSS=${QUEUE_HPSS:-""} + QUEUE_HPSS=${QUEUE_HPSS:-"workq"} PARTITION_FCST=${PARTITION_FCST:-"workq"} - QUEUE_FCST=${QUEUE_FCST:-""} + QUEUE_FCST=${QUEUE_FCST:-"workq"} ;; "CHEYENNE") @@ -435,7 +435,7 @@ case $MACHINE in PARTITION_DEFAULT=${PARTITION_DEFAULT:-"normal"} QUEUE_DEFAULT=${QUEUE_DEFAULT:-"normal"} PARTITION_HPSS=${PARTITION_HPSS:-"normal"} - QUEUE_HPSS=${QUEUE_HPSS:-"development"} + QUEUE_HPSS=${QUEUE_HPSS:-"normal"} PARTITION_FCST=${PARTITION_FCST:-"normal"} QUEUE_FCST=${QUEUE_FCST:-"normal"} ;; From db938415881e08a83293b1aeb467e76ac71d49e4 Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Wed, 21 Oct 2020 22:25:51 -0500 Subject: [PATCH 36/39] Clean up indentation of error messages (they shouldn't be indented). --- ush/load_modules_run_task.sh | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/ush/load_modules_run_task.sh b/ush/load_modules_run_task.sh index e8654e807..b469e5d77 100755 --- a/ush/load_modules_run_task.sh +++ b/ush/load_modules_run_task.sh @@ -275,23 +275,23 @@ Call to \"module use\" command failed." # if [ ${use_default_modulefile} -eq 0 ]; then - module use "${modules_dir}" || print_err_msg_exit "\ - Call to \"module use\" command failed." + module use -a "${modules_dir}" || print_err_msg_exit "\ +Call to \"module use\" command failed." - module load ${modulefile_name} || print_err_msg_exit "\ - Loading of module file (modulefile_name; in directory specified by mod- - ules_dir) for the specified task (task_name) failed: - task_name = \"${task_name}\" - modulefile_name = \"${modulefile_name}\" - modules_dir = \"${modules_dir}\"" + module load "${modulefile_name}" || print_err_msg_exit "\ +Loading of module file (modulefile_name; in directory specified by mod- +ules_dir) for the specified task (task_name) failed: + task_name = \"${task_name}\" + modulefile_name = \"${modulefile_name}\" + modules_dir = \"${modules_dir}\"" else # using default modulefile - module load ${default_modulefile_name} || print_err_msg_exit "\ - Loading of default module file failed: - task_name = \"${task_name}\" - default_modulefile_name = \"${default_modulefile_name}\" - default_modules_dir = \"${default_modules_dir}\"" + module load "${default_modulefile_name}" || print_err_msg_exit "\ +Loading of default module file failed: + task_name = \"${task_name}\" + default_modulefile_name = \"${default_modulefile_name}\" + default_modules_dir = \"${default_modules_dir}\"" fi From bca0857bb5a5700119a8e2a6273f07c0bf6f9e77 Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Fri, 23 Oct 2020 10:54:31 -0600 Subject: [PATCH 37/39] Adjust RRFS_CONUS_... grids (#294) ## DESCRIPTION OF CHANGES: * Adjust RRFS_CONUS_25km, RRFS_CONUS_13km, and RRFS_CONUS_3km grid parameters so that: * All grids, including their 4-cell-wide halos, lie completely within the HRRRX domain. * All grids have dimensions nx and ny that factor "nicely", i.e. they don't have factors greather than 7. * The write-component grids corresponding to these three native grids cover as much of the native grids as possible without going outside of the native grid boundaries. The updated NCL scripts (see below) were used to generate the write-component grid parameters. * For the RRFS_CONUS_13km grid, reduce the time step (DT_ATMOS) from 180sec to 45sec. This is necessary to get a successful forecast with the GSD_SAR suite, and thus likely also the RRFS_v1beta suite. * Modify WE2E testing system as follows: * Add new tests with the RRFS_CONUS_25km, RRFS_CONUS_13km, and RRFS_CONUS_3km grids that use the GFS_v15p2 and RRFS_v1beta suites (which are now the ones officially supported in the first release of the short-range weather app) instead of the GFS_v16beta and GSD_SAR suites, respectively. * For clarity, rename the test configuration files that use the GFS_v16beta and GSD_SAR suites so they include the suite name. * Update list of WE2E tests (baselines_list.txt). * Update the NCL plotting scripts to be able to plot grids with the latest version of the workflow. ## TESTS CONDUCTED: On hera, ran tests with all three grids with the GFS_v15p2 and RRFS_v1beta suites (a total of 6 tests). All were successful. --- ..._ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh | 18 + ...s_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} | 0 ...13km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} | 0 ...m_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh | 18 + ..._ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh | 18 + ...s_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} | 0 ...25km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} | 0 ...m_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh | 18 + ..._ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh | 18 + ...s_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} | 0 ..._3km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} | 0 ...m_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh | 18 + tests/baselines_list.txt | 18 +- ...calc_wrtcmp_grid_params_lambert_cnfrml.ncl | 43 +- ...calc_wrtcmp_grid_params_rotated_latlon.ncl | 132 +- ush/NCL/find_wrtcmp_grid_params.ncl | 67 +- ush/NCL/lib/append_to_snumeric_array.ncl | 130 ++ ush/NCL/lib/interpol_extrapol_linear.ncl | 52 + ush/NCL/plot_FV3LAM_field_native.ncl | 86 +- ush/NCL/plot_grid.ncl | 1511 +++++++---------- ush/NCL/plot_horiz_field.ncl | 65 +- ush/NCL/process_plot_params.ncl | 2 +- ush/NCL/read_FV3LAM_grid_native.ncl | 335 ++-- ush/NCL/read_FV3LAM_grid_wrtcmp.ncl | 229 ++- ush/set_predef_grid_params.sh | 48 +- 25 files changed, 1651 insertions(+), 1175 deletions(-) create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh rename tests/baseline_configs/{config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh => config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} (100%) rename tests/baseline_configs/{config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh => config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} (100%) create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh rename tests/baseline_configs/{config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh => config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} (100%) rename tests/baseline_configs/{config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh => config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} (100%) create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh rename tests/baseline_configs/{config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh => config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh} (100%) rename tests/baseline_configs/{config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh => config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh} (100%) create mode 100644 tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh create mode 100644 ush/NCL/lib/append_to_snumeric_array.ncl create mode 100644 ush/NCL/lib/interpol_extrapol_linear.ncl diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh new file mode 100644 index 000000000..ba82a4111 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_GFS_v15p2" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_13km_FV3GFS_FV3GFS.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_13km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh new file mode 100644 index 000000000..cf21b53a7 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_13km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_RRFS_v1beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh new file mode 100644 index 000000000..cfdf4a643 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_25km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_GFS_v15p2" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_25km_FV3GFS_FV3GFS.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_25km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh new file mode 100644 index 000000000..1e8030413 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_25km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_RRFS_v1beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh new file mode 100644 index 000000000..9c442dab3 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_GFS_v15p2" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20190701" +DATE_LAST_CYCL="20190701" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="FV3GFS" +EXTRN_MDL_NAME_LBCS="FV3GFS" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_3km_FV3GFS_FV3GFS.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh similarity index 100% rename from tests/baseline_configs/config.grid_RRFS_CONUS_3km_HRRRX_RAPX.sh rename to tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR.sh diff --git a/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh new file mode 100644 index 000000000..ee0535721 --- /dev/null +++ b/tests/baseline_configs/config.grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta.sh @@ -0,0 +1,18 @@ +RUN_ENVIR="community" +PREEXISTING_DIR_METHOD="rename" + +PREDEF_GRID_NAME="RRFS_CONUS_3km" +GRID_GEN_METHOD="ESGgrid" +QUILTING="TRUE" + +CCPP_PHYS_SUITE="FV3_RRFS_v1beta" +FCST_LEN_HRS="06" +LBC_SPEC_INTVL_HRS="3" + +DATE_FIRST_CYCL="20200801" +DATE_LAST_CYCL="20200801" +CYCL_HRS=( "00" ) + +EXTRN_MDL_NAME_ICS="HRRRX" +EXTRN_MDL_NAME_LBCS="RAPX" +USE_USER_STAGED_EXTRN_FILES="TRUE" diff --git a/tests/baselines_list.txt b/tests/baselines_list.txt index 9c2297087..c620625f7 100644 --- a/tests/baselines_list.txt +++ b/tests/baselines_list.txt @@ -13,12 +13,18 @@ grid_RRFS_AK_13km_FV3GFS_FV3GFS grid_RRFS_AK_13km_RAPX_RAPX grid_RRFS_AK_3km_FV3GFS_FV3GFS grid_RRFS_AK_3km_RAPX_RAPX -grid_RRFS_CONUS_13km_FV3GFS_FV3GFS -grid_RRFS_CONUS_13km_HRRRX_RAPX -grid_RRFS_CONUS_25km_FV3GFS_FV3GFS -grid_RRFS_CONUS_25km_HRRRX_RAPX -grid_RRFS_CONUS_3km_FV3GFS_FV3GFS -grid_RRFS_CONUS_3km_HRRRX_RAPX +grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2 +grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta +grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR +grid_RRFS_CONUS_13km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta +grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2 +grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta +grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR +grid_RRFS_CONUS_25km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta +grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2 +grid_RRFS_CONUS_3km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v16beta +grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_GSD_SAR +grid_RRFS_CONUS_3km_ics_HRRRX_lbcs_RAPX_suite_RRFS_v1beta grid_RRFS_SUBCONUS_3km_FV3GFS_FV3GFS grid_RRFS_SUBCONUS_3km_HRRRX_RAPX nco_RRFS_CONUS_25km_HRRRX_RAPX diff --git a/ush/NCL/calc_wrtcmp_grid_params_lambert_cnfrml.ncl b/ush/NCL/calc_wrtcmp_grid_params_lambert_cnfrml.ncl index d747f33d0..2a917a126 100644 --- a/ush/NCL/calc_wrtcmp_grid_params_lambert_cnfrml.ncl +++ b/ush/NCL/calc_wrtcmp_grid_params_lambert_cnfrml.ncl @@ -28,7 +28,7 @@ local lon_ctr, lat_ctr, lat1, lat2, \ num_gap_cells, \ dx, x_SW, x_NE, Lx, Lx_ovr_dx, nx, frac_x, x_increment, \ dy, y_SW, y_NE, Ly, Ly_ovr_dy, ny, frac_y, y_increment, \ - sphr_coords, lon_SW, lat_SW, \ + sphr_coords, lonctr_ll_cell, latctr_ll_cell, \ param_names, num_params, param_names_and_vals, trailing_comments, \ np, param_name, param_value, param_value_str, \ regex_search, regex_print, sed_cmd, \ @@ -119,8 +119,8 @@ begin ; dx = dx_native dy = dy_native -; num_margin_cells = 1 - num_margin_cells = 5 + num_margin_cells = 1 +; num_margin_cells = 5 ; num_margin_cells = 100 ; ; ********************************************************************** @@ -156,16 +156,16 @@ begin ; ; ********************************************************************** ; - y_S_native_max = max((/y_SW_native, y_S_native, y_SE_native/)) y_N_native_min = min((/y_NW_native, y_N_native, y_NE_native/)) y_S = y_S_native_max + num_margin_cells*dy y_N = y_N_native_min - num_margin_cells*dy - y_S_tmp = y_S - y_N_tmp = y_N - y_S = -min(abs((/y_S_tmp, y_N_tmp/))) +; The following forces the write-component domain in Lambert conformal +; space (i.e. the xy-plane) to be symmetric (about (x,y)=(0,0)) in the y +; direction. Can't remember why I wanted to enforece this... + y_S = -min(abs((/y_S, y_N/))) y_N = -y_S Ly = y_N - y_S @@ -178,23 +178,28 @@ begin ; ; ********************************************************************** ; -; Calculate the spherical coordinates of the southwest corner of the na- -; tive grid from its Lambert coordinates. +; Calculate the spherical coordinates of the southwest corner of the +; native grid from its Lambert coordinates. +; +; Note that the coordinates that the write-component takes as input are +; those of the center of the grid cell at the lower-left corner of the +; grid. However, the Lambert coordinates (x_W, y_S) caluclated above +; are those of the lower-left vertex (not center) of that cell. Thus, +; we first add half a grid distance in the x and y directions to the +; Lambert coordinates of the vertex to obtain the Lambert coordinates of +; the cell center. We then convert the result to spherical coordinates. ; ; ********************************************************************** ; - x_W = x_W + 0.5*dx - x_E = x_E - 0.5*dx - - y_S = y_S + 0.5*dy - y_N = y_N - 0.5*dy + xctr_ll_cell = x_W + 0.5*dx + yctr_ll_cell = y_S + 0.5*dy sphr_coords \ := convert_lambert_cnfrml_coords_to_sphr( \ lon_ctr, lat_ctr, lat1, lat2, rad_Earth, angle_units, \ - x_W, y_S) - lon_SW = sphr_coords@lon - lat_SW = sphr_coords@lat + xctr_ll_cell, yctr_ll_cell) + lonctr_ll_cell = sphr_coords@lon + latctr_ll_cell = sphr_coords@lat ; ; ********************************************************************** ; @@ -280,10 +285,10 @@ begin param_value := ny fmt_str = "%10.0f" else if (strcmp_exact(param_name, "lon1")) then - param_value := lon_SW + param_value := lonctr_ll_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "lat1")) then - param_value := lat_SW + param_value := latctr_ll_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "dx")) then param_value := dx diff --git a/ush/NCL/calc_wrtcmp_grid_params_rotated_latlon.ncl b/ush/NCL/calc_wrtcmp_grid_params_rotated_latlon.ncl index 4038b69ca..250442161 100644 --- a/ush/NCL/calc_wrtcmp_grid_params_rotated_latlon.ncl +++ b/ush/NCL/calc_wrtcmp_grid_params_rotated_latlon.ncl @@ -12,6 +12,7 @@ loadscript(lib_location + "strpad.ncl") loadscript(lib_location + "repeat_str.ncl") loadscript(lib_location + "calc_rotated_sphr_coords_from_sphr.ncl") loadscript(lib_location + "calc_sphr_coords_from_rotated_sphr.ncl") +loadscript(lib_location + "convert_from_to_sphr_coords_to_from_rotated_sphr.ncl") undef("calc_wrtcmp_grid_params_rotated_latlon") @@ -61,23 +62,79 @@ begin ; lon_ctr = lon_ctr_native lat_ctr = lat_ctr_native - lat1 = lat_ctr - lat2 = lat_ctr ; ; ********************************************************************** ; -; Calculate the Lambert coordinates of the southwest corner of the na- -; tive grid from its spherical coordinates. +; The following is a manual intervention to ensure that the first elements +; of lon_tile_corners_face_midpts_native and lat_tile_corners_face_midpts_native +; represent the southwest corner of the grid. If that is already the case, +; i_start should be set to 0. +; +; Note that this will not be the case for a GFDLgrid type of grid because +; for that case, tile 6 on which the regional grid (tile 7) is based starts +; its numbering such that the northeast corner of the tile is (i,j) = (0,0), +; and i increases going west while j increases going south. For that case, +; i_start must be set to 4 (since the northwest corner is the first element +; and thus has an index of 0, so we have to march four points forward - +; to the midpoint of the north face, then to the northwest corner, then +; to the midpoint of the west face, and finally to the southwest corner). +; +; The following may also be needed for grids (of either GFDLgrid or ESGgrid +; type) that straddle the international date line (which is the case if +; they include one or the other pole). The RAP domain is such an example. +; In such cases, the order of the coordinates must be manually verified +; and possbily fixed using the code below. +; +; ********************************************************************** +; +if (False) +;if (True) + +print("") +print("(lon_tile_corners_face_midpts_native, lat_tile_corners_face_midpts_native) = " + \ + lon_tile_corners_face_midpts_native + ", " + \ + lat_tile_corners_face_midpts_native) +pause + + i_start = 4 + + nn = dimsizes(lon_tile_corners_face_midpts_native) + i_end = i_start + nn - 1 + + i_vec = ispan(i_start, i_end, 1) + i_vec = where(i_vec .gt. nn-1, i_vec - nn, i_vec) + + lon_tile_corners_face_midpts_native := lon_tile_corners_face_midpts_native(i_vec) + lat_tile_corners_face_midpts_native := lat_tile_corners_face_midpts_native(i_vec) +print("") +print("(lon_tile_corners_face_midpts_native, lat_tile_corners_face_midpts_native) = " + \ + lon_tile_corners_face_midpts_native + ", " + \ + lat_tile_corners_face_midpts_native) +pause + +end if + + +; +; ********************************************************************** +; +; Calculate the rotated spherical coordinates of the southwest corner of +; the native grid from its spherical coordinates. ; ; ********************************************************************** ; - lambert_coords \ - := calc_rotated_sphr_coords_from_sphr( \ - lon_ctr, lat_ctr, lat1, lat2, angle_units, \ + rotated_sphr_coords \ + := convert_from_to_sphr_coords_to_from_rotated_sphr( \ + lon_ctr, lat_ctr, angle_units, 1, \ lon_tile_corners_face_midpts_native, \ lat_tile_corners_face_midpts_native) - x_tile_corners_face_midpts_native = lambert_coords@x - y_tile_corners_face_midpts_native = lambert_coords@y + x_tile_corners_face_midpts_native = rotated_sphr_coords@lon_out + y_tile_corners_face_midpts_native = rotated_sphr_coords@lat_out +;print("") +;print("(x_tile_corners_face_midpts_native, y_tile_corners_face_midpts_native) = " + \ +; x_tile_corners_face_midpts_native + ", " + \ +; y_tile_corners_face_midpts_native) +;pause i = 0 x_SW_native = x_tile_corners_face_midpts_native(i) @@ -117,10 +174,13 @@ begin ; ; ********************************************************************** ; - dx = dx_native - dy = dy_native -; num_margin_cells = 1 - num_margin_cells = 5 + +; Calculate grid size in degrees along the rotated spherical coordinates. + dx = (dx_native/rad_Earth)*degs_per_rad + dy = (dy_native/rad_Earth)*degs_per_rad + + num_margin_cells = 1 +; num_margin_cells = 5 ; num_margin_cells = 100 ; ; ********************************************************************** @@ -162,9 +222,7 @@ begin y_S = y_S_native_max + num_margin_cells*dy y_N = y_N_native_min - num_margin_cells*dy - y_S_tmp = y_S - y_N_tmp = y_N - y_S = -min(abs((/y_S_tmp, y_N_tmp/))) + y_S = -min(abs((/y_S, y_N/))) y_N = -y_S Ly = y_N - y_S @@ -177,23 +235,29 @@ begin ; ; ********************************************************************** ; -; Calculate the spherical coordinates of the southwest corner of the na- -; tive grid from its Lambert coordinates. +; Calculate the spherical coordinates of the southwest corner of the +; native grid from its Lambert coordinates. ; ; ********************************************************************** ; - x_W = x_W + 0.5*dx - x_E = x_E - 0.5*dx + lon_ctr_ll_cell = x_W + 0.5*dx + lat_ctr_ll_cell = y_S + 0.5*dy + + lon_ctr_ur_cell = x_E - 0.5*dx + lat_ctr_ur_cell = y_N - 0.5*dy + +; dlon = dx*degs_per_rad +; dlat = dy*degs_per_rad - y_S = y_S + 0.5*dy - y_N = y_N - 0.5*dy + dlon = dx + dlat = dy - sphr_coords \ - := calc_sphr_coords_from_rotated_sphr( \ - lon_ctr, lat_ctr, lat1, lat2, rad_Earth, angle_units, \ - x_W, y_S) - lon_SW = sphr_coords@lon - lat_SW = sphr_coords@lat +; sphr_coords \ +; := calc_sphr_coords_from_rotated_sphr( \ +; lon_ctr, lat_ctr, lat1, lat2, rad_Earth, angle_units, \ +; x_W, y_S) +; lon_SW = sphr_coords@lon +; lat_SW = sphr_coords@lat ; ; ********************************************************************** ; @@ -265,22 +329,22 @@ begin param_value := lat_ctr fmt_str = "%16.8f" else if (strcmp_exact(param_name, "lon1")) then - param_value := lon_SW + param_value := lon_ctr_ll_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "lat1")) then - param_value := lat_SW + param_value := lat_ctr_ll_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "lon2")) then - param_value := lon_SW + param_value := lon_ctr_ur_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "lat2")) then - param_value := lat_SW + param_value := lat_ctr_ur_cell fmt_str = "%16.8f" else if (strcmp_exact(param_name, "dlon")) then - param_value := dx + param_value := dlon fmt_str = "%16.8f" else if (strcmp_exact(param_name, "dlat")) then - param_value := dy + param_value := dlat fmt_str = "%16.8f" else diff --git a/ush/NCL/find_wrtcmp_grid_params.ncl b/ush/NCL/find_wrtcmp_grid_params.ncl index c70045d13..d7b3d97c9 100644 --- a/ush/NCL/find_wrtcmp_grid_params.ncl +++ b/ush/NCL/find_wrtcmp_grid_params.ncl @@ -9,6 +9,21 @@ ;help = True expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/test_latest_20191002/expt_dirs/test_sheleg_GSD_HRRR3km_01" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_GSD_HRRR13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR_3km_works03" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR_3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_SUBCONUS_3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_CONUS_25km_GFDLgrid" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_CONUS_3km_GFDLgrid" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_3km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_13km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_13km_old001" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try01/grid_RRFS_CONUS_13km_HRRRX_RAPX" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try01/grid_RRFS_CONUS_3km_FV3GFS_FV3GFS" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try03/grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try03/grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2" + ; ; ********************************************************************** @@ -85,16 +100,17 @@ begin var_defns_fp = expt_dir + "/var_defns.sh" param_names = (/ \ -"WRTCMP_PARAMS_TEMPLATE_FP", \ +"WRTCMP_PARAMS_TMPL_FP", \ "WRTCMP_output_grid", \ -"gtype", \ +"GTYPE", \ "CRES", \ -"delx", \ -"dely", \ -"nh4_T7" /) +"ESGgrid_DELX", \ +"ESGgrid_DELY", \ +"NH4" /) num_params = dimsizes(param_names) do np=0, num_params-1 +print("np = " + np) param_name = param_names(np) regex_search = "^\s*" + param_name + "=(" + char_dq + "([^" \ @@ -104,23 +120,28 @@ begin + "s/" + regex_search + "/" + regex_print + "/p" + char_sq \ + " " + var_defns_fp sed_output = systemfunc(sed_cmd) +print("sed_output = " + sed_output) ; ; Convert the output from the sed command (which will be a string) to ; the appropriate NCL data type. ; - if (strcmp_exact(param_name, "WRTCMP_PARAMS_TEMPLATE_FP")) then - WRTCMP_PARAMS_TEMPLATE_FP = tostring(sed_output) + if (strcmp_exact(param_name, "WRTCMP_PARAMS_TMPL_FP")) then + WRTCMP_PARAMS_TMPL_FP = tostring(sed_output) else if (strcmp_exact(param_name, "WRTCMP_output_grid")) then WRTCMP_output_grid = tostring(sed_output) - else if (strcmp_exact(param_name, "gtype")) then - gtype = tostring(sed_output) + else if (strcmp_exact(param_name, "GTYPE")) then + GTYPE = tostring(sed_output) else if (strcmp_exact(param_name, "CRES")) then CRES = tostring(sed_output) - else if (strcmp_exact(param_name, "delx")) then + else if (strcmp_exact(param_name, "ESGgrid_DELX")) then dx_native = todouble(sed_output) - else if (strcmp_exact(param_name, "dely")) then +;dx_native = 25122.693954919 ; Need if using the CONUS_25km_GFDLgrid grid +;dx_native = 2964.19334212185 ; Need if using the CONUS_3km_GFDLgrid grid + else if (strcmp_exact(param_name, "ESGgrid_DELY")) then dy_native = todouble(sed_output) - else if (strcmp_exact(param_name, "nh4_T7")) then +;dy_native = 25122.693954919 ; Need if using the CONUS_25km_GFDLgrid grid +;dy_native = 2964.19334212185 ; Need if using the CONUS_3km_GFDLgrid grid + else if (strcmp_exact(param_name, "NH4")) then nhalo_T7 = tointeger(sed_output) else @@ -145,11 +166,12 @@ begin ; ; ********************************************************************** ; -; Check that gtype has the proper value. +; Check that GTYPE has the proper value. ; ; ********************************************************************** ; - if (strcmp_exact(gtype, "regional")) then +print("AAAAAAAAAAAAAAAAAAAAAAAAAAA") + if (strcmp_exact(GTYPE, "regional")) then inds_tiles_to_plot = (/ 7 /) @@ -157,9 +179,9 @@ begin msg := char_nl + \ "ERROR: " + curnt_script_proc_func_name + ":" + char_nl + \ -"This script is designed to handle only regional grids. Thus, gtype" + char_nl + \ +"This script is designed to handle only regional grids. Thus, GTYPE" + char_nl + \ "may only be set to " + char_dq + "regional" + char_dq + ":" + char_nl + \ -" gtype = " + char_dq + gtype + char_dq + char_nl + \ +" GTYPE = " + char_dq + GTYPE + char_dq + char_nl + \ "Stopping." + char_nl print("" + msg) @@ -173,12 +195,13 @@ begin ; ; ********************************************************************** ; +print("BBBBBBBBBBBBBBBBBBBBBBBBBBB") remove_rgnl_halo = True get_tile_bdies = False grid_info := read_FV3LAM_grid_native( \ expt_dir, \ - gtype, \ + GTYPE, \ CRES, \ inds_tiles_to_plot, \ get_tile_bdies, \ @@ -192,6 +215,14 @@ begin = grid_info@lon_tile_corners_face_midpts_all_tiles lat_tile_corners_face_midpts_tiles_to_plot \ = grid_info@lat_tile_corners_face_midpts_all_tiles + +;lon_tile_corners_face_midpts_tiles_to_plot \ +;= where(lon_tile_corners_face_midpts_tiles_to_plot .gt. 0.0d+0, \ +; lon_tile_corners_face_midpts_tiles_to_plot - 360.0d+0, \ +; lon_tile_corners_face_midpts_tiles_to_plot) +;print("lon_tile_corners_face_midpts_tiles_to_plot, lat_tile_corners_face_midpts_tiles_to_plot = " + \ +; lon_tile_corners_face_midpts_tiles_to_plot + ", " + lat_tile_corners_face_midpts_tiles_to_plot) +;pause ; ; ********************************************************************** ; @@ -202,7 +233,7 @@ begin ; ********************************************************************** ; wrtcmp_config_fp = expt_dir + "/aaaa" - sys_output = systemfunc("cp " + WRTCMP_PARAMS_TEMPLATE_FP + \ + sys_output = systemfunc("cp " + WRTCMP_PARAMS_TMPL_FP + \ " " + wrtcmp_config_fp) ; ; ********************************************************************** diff --git a/ush/NCL/lib/append_to_snumeric_array.ncl b/ush/NCL/lib/append_to_snumeric_array.ncl new file mode 100644 index 000000000..5734024b0 --- /dev/null +++ b/ush/NCL/lib/append_to_snumeric_array.ncl @@ -0,0 +1,130 @@ +; +; ********************************************************************** +; +; File name: append_to_snumeric_array.ncl +; Author: Gerard Ketefian +; +; Description: +; ^^^^^^^^^^^ +; This function appends to the snumeric array orig_array the snumeric +; array array_to_append. The result is saved in new_array and returned. +; Note that if the two arrays are not of the same snumeric type, then +; array_to_append is converted to the type of orig_array before appending +; it to orig_array. +; +; ********************************************************************** +; +loadscript(lib_location + "strcmp_exact.ncl") + +undef("append_to_snumeric_array") + +function append_to_snumeric_array( \ + orig_array:snumeric, array_to_append:snumeric) + +local dims_orig_array, \ + num_dims_orig_array, \ + dims_orig_array_str, \ +\ + dims_array_to_append, \ + num_dims_array_to_append, \ + dims_array_to_append_str, \ +\ + msg, \ +\ + num_dims, \ + dims_compare, \ + right_dims_equal, \ +\ + tmp, \ + new_array + +begin +; +; ********************************************************************** +; +; Get the dimensions and the number of dimensions of the two input arrays. +; +; ********************************************************************** +; + dims_orig_array := dimsizes(orig_array) + num_dims_orig_array := dimsizes(dims_orig_array) + dims_orig_array_str \ + := "(/ " + str_join(tostring(dims_orig_array), ", ") + " /)" + + dims_array_to_append := dimsizes(array_to_append) + num_dims_array_to_append := dimsizes(dims_array_to_append) + dims_array_to_append_str \ + := "(/ " + str_join(tostring(dims_array_to_append), ", ") + " /)" +; +; ********************************************************************** +; +; Check that the two input arrays have the same number of dimensions. +; +; ********************************************************************** +; + if (num_dims_array_to_append .ne. num_dims_orig_array) then + msg = "" + char_nl + \ +"Error:" + char_nl + \ +"The number of dimensions of orig_array (num_dims_orig_array) and of " + char_nl + \ +"array_to_append (num_dims_array_to_append) must be the same:" + char_nl + \ +" dims_orig_array = " + dims_orig_array_str + char_nl + \ +" dims_array_to_append = " + dims_array_to_append_str + char_nl + \ +" num_dims_orig_array = " + num_dims_orig_array + char_nl + \ +" num_dims_array_to_append = " + num_dims_array_to_append + char_nl + \ +"Stopping." + print("" + msg) + exit + end if +; +; ********************************************************************** +; +; Check that all dimensions in the two input arrays after (i.e. to the +; right of) the first dimension are identical. +; +; ********************************************************************** +; + num_dims = num_dims_orig_array + if (num_dims .gt. 1) then + dims_compare := (dims_orig_array .eq. dims_array_to_append) + right_dims_equal := all(dims_compare(1:)) + else + right_dims_equal := True + end if + + if (.not. right_dims_equal) then + msg = "" + char_nl + \ +"Error:" + char_nl + \ +"All dimensions of orig_array and array_to_append after the first dimension" + char_nl + \ +"must be equal:" + char_nl + \ +" dims_orig_array = " + dims_orig_array_str + char_nl + \ +" dims_array_to_append = " + dims_array_to_append_str + char_nl + \ +"Stopping." + print("" + msg) + exit + end if +; +; ********************************************************************** +; +; If necessary, convert the type of array_to_append to that of orig_array. +; +; ********************************************************************** +; + tmp := array_to_append + if (.not. strcmp_exact(typeof(tmp), typeof(orig_array))) then + tmp := totype(tmp, typeof(orig_array)) + end if +; +; ********************************************************************** +; +; Append array_to_append to orig_array and save the result in new_array. +; Then return new_array. +; +; ********************************************************************** +; + new_array := array_append_record(orig_array, tmp, 0) + + return(new_array) + +end + + diff --git a/ush/NCL/lib/interpol_extrapol_linear.ncl b/ush/NCL/lib/interpol_extrapol_linear.ncl new file mode 100644 index 000000000..9f5afcfdc --- /dev/null +++ b/ush/NCL/lib/interpol_extrapol_linear.ncl @@ -0,0 +1,52 @@ +; +; ********************************************************************** +; +; File name: interpol_extrapol_linear.ncl +; Author: Gerard Ketefian +; +; Description: +; ^^^^^^^^^^^ +; This function compares each element of the string array str_array to +; the string (scalar) str. It returns a variable (match_found) that +; will be set to True if at least one element of str_array is identical +; to str and False otherwise (i.e. it will be set to False if none of +; the elements of str_array are identical to str). This function also +; returns (as an attribute of match_found) a 1-D logical array (exact_- +; match) having the same dimensions as str_array that will be True at +; those indices at which str_array is identical to str and False every- +; where else. +; +; Note that str_array may be a scalar string, in which case this func- +; tion simply compares two strings. If the two strings are identical, +; then this function returns True in match_found as well as its attri- +; bute match_found@str_array (which in this case will be a scalar). If +; the two strings are not identical, then match_found and match_found@- +; match_by_elem will both be False. +; +; ********************************************************************** +; +undef("interpol_extrapol_linear") + +function interpol_extrapol_linear( \ + x1[*]:snumeric, y1[*]:snumeric, \ + x2[*]:snumeric, y2[*]:snumeric, \ + x[*]:snumeric) + +local slope, y_int, y + +begin +; +; ********************************************************************** +; +; Perform linear interpolation and return the result. +; +; ********************************************************************** +; + slope := (y2 - y1)/(x2 - x1) + y_int := (x2*y1 - x1*y2)/(x2 - x1) + y := slope*x + y_int + return(y) + +end + + diff --git a/ush/NCL/plot_FV3LAM_field_native.ncl b/ush/NCL/plot_FV3LAM_field_native.ncl index a28dc77e6..11facf61c 100644 --- a/ush/NCL/plot_FV3LAM_field_native.ncl +++ b/ush/NCL/plot_FV3LAM_field_native.ncl @@ -18,11 +18,14 @@ ;help = True -expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3LAM_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR25km" -expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3LAM_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR13km" -expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3LAM_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR3km" -expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3LAM_demo_PASPBL_20190725/expt_dirs/test_GSD_HAFSV0.A" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3SAR_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR25km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3SAR_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3SAR_demo_PASPBL_20190725/expt_dirs/test_GSD_HRRR3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/FV3SAR_demo_PASPBL_20190725/expt_dirs/test_GSD_HAFSV0.A" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_001_old001" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_003_works01" +CDATE="2019052000" tile_inds := (/ 1, 7, 4 /) ;tile_inds := (/ 1, 4 /) @@ -48,6 +51,7 @@ file_basename = "atmos_static" file_basename = "fv3_history2d" file_basename = "phyf000" +file_basename = "C401_oro_data.tile7.halo0.nc" ; This is a temporary change for plotting ICs. ;file_basename = "sfc_data.tile7" @@ -63,7 +67,7 @@ field_name = "sqrt_cell_area" ;field_name = "angle_cell_dx" ;field_name = "angle_cell_dy" -;field_name = "orog_raw" +field_name = "orog_raw" ;field_name = "orog_filt" ;field_name = "time" @@ -74,7 +78,7 @@ field_name = "sqrt_cell_area" ;field_name = "spfh" ;field_name = "cnwat" ;field_name = "zsurf" -field_name = "sltyp" +;field_name = "sltyp" ;field_name = "slc" ;field_name = "smc" ;field_name = "stc" @@ -86,16 +90,17 @@ field_name = "sltyp" ;field_name = "rainwat" ;field_name = "none" +;field_name = "c0" map_proj = "cyln" -;map_proj = "ortho" +map_proj = "ortho" ; ; This should be set to (0,0) for "cyln" map projection. ; map_proj_ctr = (/ 0.0, 0.0 /) ; This should be set to (0,0) for "cyln" map projection. ;map_proj_ctr = (/ -106.0, 54.0 /) ; RAP domain. -;map_proj_ctr = (/ -97.5, 38.5 /) ; HRRR domain. +map_proj_ctr = (/ -97.5, 38.5 /) ; HRRR domain. ;map_proj_ctr = (/ 6.0, 54.0 /) ; RAP domain corner. @@ -141,7 +146,7 @@ remove_rgnl_halo = True show_RAP_bdy = True -;show_RAP_bdy = False +show_RAP_bdy = False RAP_bdy_color = "red" @@ -159,7 +164,8 @@ field_name_RAP = "sqrt_cell_area" ; This is for HRRR grib2 file. field_name_RAP = "VGTYP_P0_L1_GLC0" -RAP_dir = "/scratch1/BMC/fim/Gerard.Ketefian/regional_FV3_EMC_visit_20180509" +;RAP_dir = "/scratch1/BMC/fim/Gerard.Ketefian/regional_FV3_EMC_visit_20180509" +RAP_dir = "/scratch1/BMC/gsd-fv3-dev/Gerard.Ketefian/regional_FV3_EMC_visit_20180509" ;RAP_grid_fn = "/home/Gerard/fv3_regional/fv3sar_workflow/ush/NCL/plot_grid.ncl" ;RAP_grid_fn = "/scratch3/BMC/fim/Gerard.Ketefian/regional_FV3_EMC_visit_20180509/geo_em.d01.RAP.nc" ;RAP_grid_fn = RAP_dir + "/geo_em.d01.RAP.nc" @@ -226,6 +232,7 @@ load "plot_horiz_field.ncl" load "set_file_field_names.ncl" load "get_wrtcmp_grid.ncl" load "calc_wrtcmp_grid_params_lambert_cnfrml.ncl" +load "calc_wrtcmp_grid_params.ncl" load "make_plot_titles.ncl" begin @@ -505,14 +512,15 @@ end if show_wrtcmp_grid = False show_wrtcmp_bdy = True -; show_wrtcmp_bdy = False + show_wrtcmp_bdy = False wrtcmp_bdy_color = "green" ; rd := "/scratch3/BMC/det/Gerard.Ketefian/UFS_CAM_test_instructions/expt_dirs/NX1800_NY1120_A0p21423_Kmns0p23209_HRRR_test_cycl_slurm_01/2017090700" ; rd := "/scratch3/BMC/det/Gerard.Ketefian" - rd := run_dir + "/2019052000" +; rd := run_dir + "/2019052000" + rd := expt_dir + "/" + CDATE + "00" wrtcmp_config_fn := rd + "/model_configure" ; wrtcmp_config_tmpl_fn = wrtcmp_config_fn + ".tmpl" @@ -523,6 +531,7 @@ end if ; ; ********************************************************************** ; +;if (False) then if (show_wrtcmp_grid .or. show_wrtcmp_bdy) then print("") print("wrtcmp_config_fn = " + char_dq + wrtcmp_config_fn + char_dq) @@ -546,20 +555,23 @@ pause print("lat_grid_cntr_wrtcmp = " + lat_grid_cntr_wrtcmp + " deg") pause - - out := calc_wrtcmp_grid_params( \ - wrtcmp_config_fn, \ - lon_ctr_native, lat_ctr_native, \ - lon_tile_corners_face_midpts_native, \ - lat_tile_corners_face_midpts_native, \ - dx_native, dy_native, \ - angle_units) - -print("") -print("out = " + out) -pause +;lon_ctr_native = lon_grid_cntr_wrtcmp +;lat_ctr_native = lat_grid_cntr_wrtcmp +; +; out := calc_wrtcmp_grid_params( \ +; wrtcmp_config_fn, \ +; lon_ctr_native, lat_ctr_native, \ +; lon_tile_corners_face_midpts_native, \ +; lat_tile_corners_face_midpts_native, \ +; dx_native, dy_native, \ +; angle_units) +; +;print("") +;print("out = " + out) +;pause end if +;end if ; ; ********************************************************************** ; @@ -989,6 +1001,8 @@ pause horiz_area_units) file_names_by_tile := file_field_info@file_names_by_tile +;file_names_by_tile := expt_dir + "/fix_sar/C401_oro_data.tile7.halo0.nc" +file_names_by_tile := expt_dir + "/fix_lam/C401_oro_data.tile7.halo0.nc" field_names_by_tile := file_field_info@field_names_by_tile func_xy_only := file_field_info@func_xy_only func_xyz_only := file_field_info@func_xyz_only @@ -1045,6 +1059,8 @@ pause ) else +print("") +print("XXXXXXXXXXX") field_info \ := read_FV3LAM_field_native( \ @@ -1130,6 +1146,7 @@ inds_tiles_to_plot_str + " ..." ; ********************************************************************** ; field_unstruc_all_grids := field_unstruc +print("AAAAAAA dimsizes(field_unstruc_all_grids) = " + dimsizes(field_unstruc_all_grids)) ; ; ********************************************************************** ; @@ -1146,6 +1163,10 @@ inds_tiles_to_plot_str + " ..." ; ; ********************************************************************** ; +field_name_RAP = "AAAA" +field_desc_RAP = "BBBB" +field_units_RAP = "CCCC" + if (show_RAP_grid .or. plot_RAP_field) then ; ; ********************************************************************** @@ -1198,6 +1219,8 @@ inds_tiles_to_plot_str + " ..." field_unstruc_all_grids \ := array_append_record( \ field_unstruc_RAP, field_unstruc_all_grids, 0) +print("") +print("BBBBBB dimsizes(field_unstruc_all_grids) = " + dimsizes(field_unstruc_all_grids)) end if ; @@ -1263,6 +1286,7 @@ inds_tiles_to_plot_str + " ..." ; ; ********************************************************************** ; +nn=0 title_info \ := make_plot_titles( \ inds_tiles_to_plot, \ @@ -1282,6 +1306,9 @@ inds_tiles_to_plot_str + " ..." left_str := title_info@left_str main_str := title_info@main_str right_str := title_info@right_str +left_str := "" +main_str := "" +right_str := "" ; ; ********************************************************************** ; @@ -1437,9 +1464,10 @@ inds_tiles_to_plot_str + " ..." extrnl_tag = "extrnl" bdy_plot_order := new(num_bdies_to_plot, "string") -bdy_plot_order(0) = wrtcmp_tag -bdy_plot_order(1) = extrnl_tag -bdy_plot_order(2) = native_tag +;bdy_plot_order(0) = wrtcmp_tag +;bdy_plot_order(1) = extrnl_tag +;bdy_plot_order(2) = native_tag +bdy_plot_order(0) = native_tag indx_ptr_start := new(num_bdies_to_plot, "integer") indx_ptr_end := new(num_bdies_to_plot, "integer") @@ -1601,6 +1629,10 @@ end if ; Temporarily make the field all missing/fill values, so we can see grids/boundaries. ;field_unstruc_all_grids = field_unstruc_all_grids@_FillValue +print("nx_all_grids = " + nx_all_grids) +print("") +print("CCCCCCC dimsizes(field_unstruc_all_grids) = " + dimsizes(field_unstruc_all_grids)) + plot_info := plot_horiz_field( \ fn_graphics, \ nx_all_grids, ny_all_grids, \ diff --git a/ush/NCL/plot_grid.ncl b/ush/NCL/plot_grid.ncl index 6f9a10e2a..5c5f903b8 100644 --- a/ush/NCL/plot_grid.ncl +++ b/ush/NCL/plot_grid.ncl @@ -20,20 +20,91 @@ ;run_dir = "ABCD" ;run_dir = "/home/Gerard/fv3_regional/fv3sar_workflow/ush/NCL" -run_dir = "/scratch3/BMC/det/Gerard.Ketefian/UFS_CAM_test_instructions/expt_dirs/NX1734_NY1008_A0p21423_Kmns0p23209_HRRR_test_HRRRgrid02" -run_dir = "/scratch3/BMC/det/Gerard.Ketefian/UFS_CAM_test_instructions/expt_dirs/NX1800_NY1120_A0p21423_Kmns0p23209_HRRR_test_cycl_slurm_01" +;run_dir = "/scratch3/BMC/det/Gerard.Ketefian/UFS_CAM_test_instructions/expt_dirs/NX1734_NY1008_A0p21423_Kmns0p23209_HRRR_test_HRRRgrid02" +;run_dir = "/scratch3/BMC/det/Gerard.Ketefian/UFS_CAM_test_instructions/expt_dirs/NX1800_NY1120_A0p21423_Kmns0p23209_HRRR_test_cycl_slurm_01" + +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_001_old001" +expt_dir = "/scratch2/BMC/det/beck/SAR-FV3/run_dirs/real_time2" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_007" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/GFDLgrid_debug_verif" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/GFDLgrid_debug_verif_preprocess_good" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/GFDLgrid_AK_3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/new_JPgrid" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/RTMA_grid_25km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_003" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/GSD_RAP13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/GSD_RAP13km_works02" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/RRFS_HRRR3km_from_regional_003" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/regional_002_GSD_HRRR3km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/expt_dirs/nco_GSD_HRRR3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_rrfs_v1beta/expt_dirs/regional_002" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_rrfs_v1beta/expt_dirs/FV3_RRFS_v1beta" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_rrfs_v1beta/expt_dirs/FV3_RRFS_v1beta_3km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/regional_002_25km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/regional_002_13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_rrfs_v1beta/expt_dirs/subconus" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_rrfs_v1beta/expt_dirs/nco_GSD_SUBCONUS3km_HRRRX_RAPX_works01" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_WE2E_testing/expt_dirs/try13/regional_002" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_WE2E_testing/expt_dirs/try13/nco_GSD_HRRR3km_HRRRX_RAPX" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_WE2E_testing/expt_dirs/try15/suite_FV3_GSD_SAR_3km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_GSD_HRRR13km" CDATE="2017090712" +CDATE="2019052000" +;CDATE="2020031212" +;CDATE="2017090700" +CDATE="2019070100" +;CDATE="2020080100" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR_3km_works03" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR_3km" +CDATE="2019052000" -tile_inds := (/ 1, 7, 4 /) +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_GSD_HRRR13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_CONUS_13km" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_CONUS_13km_HRRRX_RAPX" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try01/grid_RRFS_CONUS_13km_FV3GFS_FV3GFS" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try03/grid_RRFS_CONUS_13km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2" +CDATE="2019070100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try01/grid_RRFS_CONUS_13km_HRRRX_RAPX" +;CDATE="2020080100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try01/grid_RRFS_CONUS_3km_FV3GFS_FV3GFS" +;CDATE="2019070100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_SUBCONUS_3km" +;CDATE="2019070100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_CONUS_3km_GFDLgrid" +;CDATE="2019070100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_CONUS_25km_GFDLgrid" +expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_bugfix_adjust_CONUS_grids/expt_dirs/try03/grid_RRFS_CONUS_25km_ics_FV3GFS_lbcs_FV3GFS_suite_GFS_v15p2" +CDATE="2019070100" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/suite_FV3_GSD_SAR" +;CDATE="2019052000" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_3km" +;CDATE="2019052000" + +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_13km" +;expt_dir = "/scratch2/BMC/det/Gerard.Ketefian/UFS_CAM/PR_feature_predef_grids/expt_dirs/try01/grid_RRFS_AK_13km_old001" +;CDATE="2019052000" + + +run_dir = expt_dir + "/" + CDATE +print("AAAAAA run_dir = " + run_dir) + +;tile_inds := (/ 1, 7, 4 /) ;tile_inds := (/ 1, 4 /) ;tile_inds := (/ 5, 6 /) -tile_inds := (/ 5, 7 /) +;tile_inds := (/ 5, 7 /) ;tile_inds := (/ 5, 6, 7 /) ;tile_inds := (/ 5 /) ;tile_inds := (/ 6 /) -;tile_inds := (/ 7 /) +tile_inds := (/ 7 /) ;tile_inds := (/ 6, 7 /) ;subreg_limits := (/ -180, 180, -90, 90 /) @@ -53,15 +124,22 @@ tile_inds := (/ 5, 7 /) remove_rgnl_halo = True ;remove_rgnl_halo = False -;plot_RAP_field = True -plot_RAP_field = False +plot_RAP_field = True +;plot_RAP_field = False + +field_name_RAP = "XLAT_M" +;field_name_RAP = "cell_area" +;field_name_RAP = "VGTYP_P0_L1_GLC0" +show_RAP_bdy = True RAP_bdy_color = "red" RAP_dir = "/scratch3/BMC/fim/Gerard.Ketefian/regional_FV3_EMC_visit_20180509" +RAP_dir = "/scratch1/BMC/gsd-fv3-dev/Gerard.Ketefian/regional_FV3_EMC_visit_20180509" ;RAP_grid_fn = "/home/Gerard/fv3_regional/fv3sar_workflow/ush/NCL/plot_grid.ncl" ;RAP_grid_fn = "/scratch3/BMC/fim/Gerard.Ketefian/regional_FV3_EMC_visit_20180509/geo_em.d01.RAP.nc" RAP_grid_fn = RAP_dir + "/geo_em.d01.RAP.nc" +RAP_grid_fn = RAP_dir + "/geo_em.d01.HRRR.nc" map_proj = "cyln" @@ -74,6 +152,7 @@ map_proj_ctr = (/ 0.0, 0.0 /) ; This should be set to (0,0) for "cyln" map proje ;map_proj_ctr = (/ -97.5, 38.5 /) ; HRRR domain. ;map_proj_ctr = (/ 6.0, 54.0 /) ; RAP domain corner. +;map_proj_ctr = (/ -161.5, 63.0 /) ; Alaska ;map_proj_ctr = (/ -98.5, 30.0 /) @@ -84,14 +163,142 @@ plot_subreg = True ;subreg_limits := (/ -180, 180, -90, 90 /) ;subreg_limits := (/ -75, -45, 30, 60 /) + + + +subreg_limits := (/ -128, -67, 23, 51 /) ; HRRR domain if using "cyln" map projection. subreg_limits := (/ -135, -60, 20, 55 /) ; HRRR domain if using "cyln" map projection. ;subreg_limits := (/ -125, -70, 20, 55 /) ; HRRR domain if using "ortho" map projection. -;subreg_limits := (/ -145, -90, 30, 60 /) ; Northwest corner of HRRR domain. -;subreg_limits := (/ -135, -125, 40, 50 /) ; Northwest corner of HRRR domain, zoomed. -;subreg_limits := (/ -123, -121, 48, 50 /) ; Northwest corner of HRRR domain, zoomed more. -;subreg_limits := (/ -120, -115, 30, 35 /) -;subreg_limits := (/ -125, -120, 15, 25 /) ; Southwest corner of HRRR domain. -subreg_limits := (/ -120, -75, 20, 55 /) ; Center of HRRR domain. +;subreg_limits := (/ -105, -95, 20, 30 /) ; Center of southern edge of HRRR domain. + +;subreg_limits := (/ -128, -118, 32, 42 /) ; Center of western edge of HRRR domain. + +;subreg_limits := (/ -120, -75, 20, 55 /) ; Center of HRRR domain, zoomed. +;subreg_limits := (/ -110, -85, 30, 45 /) ; Center of HRRR domain, zoomed more. +;subreg_limits := (/ -100, -97, 36, 39 /) ; Center of HRRR domain, zoomed more. + +;subreg_limits := (/ -135, -60, 20, 55 /) + + + +; Zoom in on midpoint of southern edge of CONUS domain. +;subreg_limits := (/ -103.5, -93.5, 22.5, 26.5 /) ; 10deg x 4deg +;subreg_limits := (/ -100.0, -95.0, 24.0, 26.0 /) ; 5deg x 2deg +;subreg_limits := (/ -99.5, -97.5, 24, 25 /) ; 2deg x 1deg +;subreg_limits := (/ -99, -98, 24.15, 24.65 /) ; 1deg x 0.5deg + +; Zoom in on midpoint of eastern edge of CONUS domain. +;subreg_limits := (/ -71, -66, 33.5, 38.5 /) ; 5deg x 5deg + +; Zoom in on midpoint of northern edge of CONUS domain. +;subreg_limits := (/ -103.5, -93.5, 50.2, 54.2 /) ; 10deg x 4deg +;subreg_limits := (/ -100.0, -95.0, 51.3, 53.3 /) ; 5deg x 2deg +;subreg_limits := (/ -99.5, -97.5, 51.9, 52.9 /) ; 2deg x 1deg +;subreg_limits := (/ -99, -98, 52.3, 52.8 /) ; 1deg x 0.5deg + +; Zoom in on midpoint of western edge of CONUS domain. +;subreg_limits := (/ -128, -123, 33.5, 38.5 /) ; 5deg x 5deg + +; Zoom in on northwest corner of CONUS domain. +;subreg_limits := (/ -129, -99, 32, 52 /) ; 20deg x 20deg +;subreg_limits := (/ -131, -121, 40, 50 /) ; 10deg x 10deg +;subreg_limits := (/ -133, -128, 44, 49 /) ; 5deg x 5deg +;subreg_limits := (/ -133.5, -131.5, 46.2, 48.2 /) ; 2deg x 2deg +;subreg_limits := (/ -134, -133, 47, 48 /) ; 1deg x 1deg + +; Zoom in on southwest corner of CONUS domain. +;subreg_limits := (/ -125, -105, 22, 42 /) ; 20deg x 20deg +;subreg_limits := (/ -124, -114, 22, 32 /) ; 10deg x 10deg +;subreg_limits := (/ -124, -119, 21, 26 /) ; 5deg x 5deg +;subreg_limits := (/ -123.3, -121.3, 21.2, 23.2 /) ; 2deg x 2deg +;subreg_limits := (/ -123.1, -122.1, 21.2, 22.2 /) ; 1deg x 1deg +;subreg_limits := (/ -122.95, -122.45, 21.45, 21.95 /) ; 0.5deg x 0.5deg +;subreg_limits := (/ -122.9, -122.8, 21.45, 21.55 /) ; 0.1deg x 0.1deg +;subreg_limits := (/ -122.85, -122.83, 21.49, 21.51 /) ; 0.02deg x 0.02deg + +; Zoom in on southeast corner of CONUS domain. +;subreg_limits := (/ -68, -88, 22, 42 /) ; 20deg x 20deg +;subreg_limits := (/ -70, -80, 20, 30 /) ; 10deg x 10deg +;subreg_limits := (/ -71, -76, 21, 26 /) ; 5deg x 5deg +;subreg_limits := (/ -71.9, -73.9, 21.4, 23.4 /) ; 2deg x 2deg +;subreg_limits := (/ -72, -73, 21.2, 22.2 /) ; 1deg x 1deg +;subreg_limits := (/ -72.0, -72.5, 21.45, 21.95 /) ; 0.5deg x 0.5deg +;subreg_limits := (/ -72.1, -72.2, 21.45, 21.55 /) ; 0.1deg x 0.1deg +;subreg_limits := (/ -72.15, -72.17, 21.49, 21.51 /) ; 0.02deg x 0.02deg + +; Zoom in on northeast corner of CONUS domain. +;subreg_limits := (/ -66, -86, 32, 52 /) ; 20deg x 20deg +;subreg_limits := (/ -64, -74, 40, 50 /) ; 10deg x 10deg. +;subreg_limits := (/ -62, -67, 44, 49 /) ; 5deg x 5deg. +;subreg_limits := (/ -61.5, -63.5, 46.2, 48.2 /) ; 2deg x 2deg. +;subreg_limits := (/ -61.2, -62.2, 47, 48 /) ; 1deg x 1deg. + + + + +; EMC's 25km BIG CONUS grid. +;subreg_limits := (/ -145, -50, 10, 65 /) + +; Zoom in on northwest corner of BIG CONUS domain. +;subreg_limits := (/ -139, -136, 51, 54 /) ; 3deg x 3deg + +; Zoom in on southwest corner of BIG CONUS domain. +;subreg_limits := (/ -123, -120, 14, 17 /) ; 3deg x 3deg + +; Zoom in on southeast corner of BIG CONUS domain. +;subreg_limits := (/ -75, -72, 14, 17 /) ; 3deg x 3deg + +; Zoom in on northeast corner of BIG CONUS domain. +;subreg_limits := (/ -59, -56, 51, 54 /) ; 3deg x 3deg + + + + +; EMC's 3km BIG CONUS grid. +;subreg_limits := (/ -145, -50, 10, 65 /) + +; Zoom in on northwest corner of BIG CONUS domain. +;subreg_limits := (/ -137, -134, 47, 50 /) ; 3deg x 3deg + +; Zoom in on southwest corner of BIG CONUS domain. +;subreg_limits := (/ -125, -122, 18.5, 21.5 /) ; 3deg x 3deg + +; Zoom in on southeast corner of BIG CONUS domain. +;subreg_limits := (/ -74, -71, 18.5, 21.5 /) ; 3deg x 3deg + +; Zoom in on northeast corner of BIG CONUS domain. +;subreg_limits := (/ -61, -58, 47, 50 /) ; 3deg x 3deg + + + + +; Alaska domain subregions: +;subreg_limits := (/ -210, -120, 45, 80 /) ; whole AK domain; won't work with cyln projection + +; Zoom in on northwest corner of Alaska domain. +;subreg_limits := (/ 141, 145, 66, 70 /) ; 4deg x 4deg +;subreg_limits := (/ 142, 144, 66, 70 /) ; 2deg x 4deg +;subreg_limits := (/ 142, 144, 67, 69 /) ; 2deg x 2deg + +; Zoom in on southwest corner of Alaska domain. +;subreg_limits := (/ 170, 174, 44, 48 /) ; 4deg x 4deg +;subreg_limits := (/ 170, 173, 44, 47 /) ; 3deg x 3deg +;subreg_limits := (/ 171, 173, 45, 47 /) ; 2deg x 2deg + +; Zoom in on southeast corner of Alaska domain. +;subreg_limits := (/ -137, -133, 44, 48 /) ; 4deg x 4deg +;subreg_limits := (/ -136, -133, 44, 47 /) ; 3deg x 3deg +;subreg_limits := (/ -135.5, -133.5, 44.8, 46.8 /) ; 2deg x 2deg + +; Zoom in on northeast corner of Alaska domain. +;subreg_limits := (/ -108, -102, 65, 71 /) ; 6deg x 6deg +;subreg_limits := (/ -107, -103, 66, 70 /) ; 4deg x 4deg +;subreg_limits := (/ -106, -104, 66, 70 /) ; 2deg x 4deg +;subreg_limits := (/ -106, -104, 67, 69 /) ; 2deg x 2deg + + +;subreg_limits := (/ -135, -60, 15, 60 /) ; RTMA domain if using "ortho" map projection. +;subreg_limits := (/ -128, -126, 34, 36 /) ; Center of western boundary of CONUS ;subreg_limits := (/ -15, 0, 0, 15 /) ;subreg_limits := (/ -30, 0, 0, 30 /) @@ -129,7 +336,7 @@ field_name = "area" ;field_name = "abcd" -;field_name = "orog_raw" +field_name = "orog_raw" ;field_name = "orog_filt" ;field_name = "time" @@ -139,13 +346,14 @@ field_name = "area" field_name = "sltyp" field_name = "dswrf" +field_name = "zsurf" show_tile_bdies = True ;show_tile_bdies = False -;show_tile_grids = True -show_tile_grids = False +show_tile_grids = True +;show_tile_grids = False file_basename = "atmos_static" @@ -153,14 +361,12 @@ file_basename = "atmos_static" file_basename = "fv3_history2d" -;show_wrtcmp_grid = True +show_wrtcmp_grid = True show_wrtcmp_grid = False show_wrtcmp_bdy = True ;show_wrtcmp_bdy = False -wrtcmp_bdy_color = "green" - separator_line \ := "************************************************************************" @@ -183,6 +389,7 @@ loadscript(lib_location + "repeat_str.ncl") loadscript(lib_location + "calc_field_stats.ncl") loadscript(lib_location + "get_rect_grid_bdy.ncl") loadscript(lib_location + "set_cnLevels_lbLabels.ncl") +loadscript(lib_location + "append_to_snumeric_array.ncl") load "process_plot_params.ncl" load "read_FV3LAM_grid_native.ncl" @@ -373,9 +580,11 @@ char_dq + "ncgm" + char_dq + "." + char_nl gtype = plot_params@gtype num_tiles_to_plot = plot_params@num_tiles_to_plot inds_tiles_to_plot = plot_params@inds_tiles_to_plot +;print("XXXXXXXXXXXXXXX") +;print("inds_tiles_to_plot = " + inds_tiles_to_plot) + cres = plot_params@cres - run_dir = plot_params@run_dir - work_dir = plot_params@work_dir + expt_dir = plot_params@expt_dir horiz_dist_units = plot_params@horiz_dist_units horiz_area_units = plot_params@horiz_area_units @@ -401,87 +610,6 @@ char_dq + "ncgm" + char_dq + "." + char_nl plot_subreg = plot_params@plot_subreg subreg_limits = plot_params@subreg_limits - - -; -; ********************************************************************** -; -; Read in the FV3-LAM grid. -; -; ********************************************************************** -; -read_FV3LAM_wrtcmp = True -;read_FV3LAM_wrtcmp = False - -if (read_FV3LAM_wrtcmp) then - - FV3LAM_wrtcmp_fn = run_dir + "/" + CDATE + "/" + "dynf000.nc" - get_domain_bdy = True - grid_info := read_FV3LAM_grid_wrtcmp( \ - FV3LAM_wrtcmp_fn, \ - get_domain_bdy) - - fp_wrtcmp = grid_info@fp - nx = grid_info@nx - ny = grid_info@ny - lon_cntrs_unstruc = grid_info@lon_cntrs_unstruc - lat_cntrs_unstruc = grid_info@lat_cntrs_unstruc - lon_verts_unstruc = grid_info@lon_verts_unstruc - lat_verts_unstruc = grid_info@lat_verts_unstruc - lon_bdy = grid_info@lon_bdy - lat_bdy = grid_info@lat_bdy - coord_data_type_FV3LAM = grid_info@coord_data_type - -else - - nhalo_T7 = 4 ; Should this be at the top, i.e. defined as a global variable???? - ; or be a requird input that gets processed along with the other - ; command linea arguments? - - grid_info := read_FV3LAM_grid_native( \ - work_dir, \ - gtype, \ - cres, \ - inds_tiles_to_plot, \ - show_tile_bdies, \ - nhalo_T7, \ - remove_rgnl_halo) - - grid_fn_tiles_to_plot = grid_info@grid_fn_all_tiles - - nhSG_tiles_to_plot = grid_info@nhSG_all_tiles - nxhSG_tiles_to_plot = grid_info@nxhSG_all_tiles - nyhSG_tiles_to_plot = grid_info@nyhSG_all_tiles - nxSG_tiles_to_plot = grid_info@nxSG_all_tiles - nySG_tiles_to_plot = grid_info@nySG_all_tiles - - nh_tiles_to_plot = grid_info@nh_all_tiles - nxh_tiles_to_plot = grid_info@nxh_all_tiles - nyh_tiles_to_plot = grid_info@nyh_all_tiles - nx_tiles_to_plot = grid_info@nx_all_tiles - ny_tiles_to_plot = grid_info@ny_all_tiles - - remove_halo_tiles_to_plot = grid_info@remove_halo_all_tiles - - lon_cntrs_unstruc = grid_info@lon_cntrs_all_tiles_unstruc - lat_cntrs_unstruc = grid_info@lat_cntrs_all_tiles_unstruc - lon_verts_unstruc = grid_info@lon_verts_all_tiles_unstruc - lat_verts_unstruc = grid_info@lat_verts_all_tiles_unstruc - - lon_bdy = grid_info@lon_bdy_all_tiles - lat_bdy = grid_info@lat_bdy_all_tiles - - lon_tile_cntr_tiles_to_plot = grid_info@lon_tile_cntr_all_tiles - lat_tile_cntr_tiles_to_plot = grid_info@lat_tile_cntr_all_tiles - - lon_tile_corners_face_midpts_tiles_to_plot \ - = grid_info@lon_tile_corners_face_midpts_all_tiles - lat_tile_corners_face_midpts_tiles_to_plot \ - = grid_info@lat_tile_corners_face_midpts_all_tiles - - coord_data_type_FV3LAM = grid_info@coord_data_type - -end if ; ; ********************************************************************** ; @@ -489,687 +617,309 @@ end if ; ; ********************************************************************** ; -time_inds_to_plot := (/ 0, 2 /) ; This must be specified on the command line. -time_inds_to_plot := (/ 0 /) ; This must be specified on the command line. - - -fcst_output_hrs := (/ 0, 1, 2, 3, 4, 5, 6 /) ; Read this in from file, e.g. var_defns.sh. -;fcst_output_hrs := (/ 0, 2, 4, 6 /) ; Read this in from file, e.g. var_defns.sh. -fcst_output_hrs := (/ 0 /) ; Read this in from file, e.g. var_defns.sh. -fcst_output_hrs := (/ 5 /) ; Read this in from file, e.g. var_defns.sh. - -fcst_hrs_to_plot := fcst_output_hrs(time_inds_to_plot) -num_fcst_hrs = dimsizes(fcst_hrs_to_plot) - -vert_inds_to_plot := (/ 0, 10 /) -vert_inds_to_plot := (/ 0 /) -num_vert = dimsizes(vert_inds_to_plot) +native = True +;native = False +native@plot_gridlines = True +native@plot_gridlines = False +;native@gridline_color = "black" +native@gridline_color = "red" +native@plot_bdy = True +native@bdy_color = native@gridline_color +native@bdy_line_thickness = 4.0 +;native@bdy_line_thickness = 16.0 +native@bdy_dash_pattern = 1 +halo = True +;halo = False +halo@plot_gridlines = True +;halo@plot_gridlines = False +halo@gridline_color = "orange" +halo@plot_bdy = True +;halo@plot_bdy = False +halo@bdy_color = halo@gridline_color +halo@bdy_line_thickness = 4.0 +halo@bdy_dash_pattern = 1 -; Must set to 0 for write-component files since those each contain output for only one time. -if (read_FV3LAM_wrtcmp) then - time_inds_to_plot = 0*time_inds_to_plot -end if - - -do n=0, num_fcst_hrs-1 - do k=0, num_vert-1 - - print("") - print("") - print("" + separator_line) - print("" + separator_line) - print("n = " + n + "; k = " + k) - print("" + separator_line) - print("" + separator_line) - - vert_indx = vert_inds_to_plot(k) - time_indx = time_inds_to_plot(n) - fcst_hr = fcst_hrs_to_plot(n) - - fmt_str = "%03i" - vert_indx_str = sprinti(fmt_str, vert_indx) - fcst_hr_str = sprinti(fmt_str, fcst_hr) - -;print("") -; print("fcst_hr = " + fcst_hr) -; print("fcst_hr_str = " + fcst_hr_str) -;print("") -; print("vert_indx = " + vert_indx) -; print("vert_indx_str = " + vert_indx_str) -;pause - +wrtcmp = True +;wrtcmp = False +wrtcmp@plot_gridlines = True +wrtcmp@plot_gridlines = False +;wrtcmp@gridline_color = "green" +wrtcmp@gridline_color = "blue" +wrtcmp@plot_bdy = True +wrtcmp@bdy_color = wrtcmp@gridline_color +wrtcmp@bdy_line_thickness = 6.0 +wrtcmp@bdy_dash_pattern = 1 +extrnl = True +;extrnl = False +;extrnl@plot_gridlines = True +extrnl@plot_gridlines = False +;extrnl@gridline_color = "red" +extrnl@gridline_color = "green" +extrnl@plot_bdy = True +extrnl@bdy_color = extrnl@gridline_color +extrnl@bdy_line_thickness = 4.0 +extrnl@bdy_dash_pattern = 1 ; ; ********************************************************************** ; -; If we want to plot output files generated by the write-component ... -; -; ********************************************************************** -; -if (read_FV3LAM_wrtcmp) then -; -; Set the file name. This depends on the time index/ forecast output hour. -; - -; FV3LAM_wrtcmp_fn = run_dir + "/dynf000.nc" -; FV3LAM_wrtcmp_fn = run_dir + "/phyf000.nc" -; FV3LAM_wrtcmp_fn = run_dir + "/phyf" + fcst_hr_str + ".nc" - FV3LAM_wrtcmp_fn = run_dir + "/" + CDATE + "/" + "phyf" + fcst_hr_str + ".nc" - -; -; ********************************************************************** ; -; Call a function that runs various checks on the specified field. This -; function will: -; -; 1) Verify that the field exists as a as a variable in the file. -; 2) Verify that its functional dependence on space and time is one of -; the following: -; a) Function of only the two horizontal directions but not the ver- -; tical direction or time. In this case, the func_xy_only attrib- -; ute of the returned variable will be set to True. -; b) Function of only the two horizontal directions and the vertical -; direction but not time. In this case, the func_xyz_only attrib- -; ute of the returned variable will be set to True. -; c) Function of only the two horizontal directions and time but not -; the vertical direction. In this case, the func_xyt_only attrib- -; ute of the returned variable will be set to True. -; d) Function of the two horizontal directions, the vertical direc- -; tion, and time. In this case, the func_xyzt_only attribute of -; the returned variable will be set to True. -; 3) Verify that the specified vertical and/or time indices do not ex- -; ceed the array bounds of the variable that represents the specified -; field. -; 4) Return: -; a) The rank, dimension names, and dimension sizes of the variable -; that represents the field. -; b) The functional dependence of the field on x, y, z, and t. ; ; ********************************************************************** ; +grid_opts = True +grid_opts@plot_gridlines := new(1, logical) +grid_opts@gridline_colors := new(1, string) -; x_filedim_names = (/ "grid_xt" /) -; y_filedim_names = (/ "grid_yt" /) -; z_filedim_names = (/ "pfull", "phalf" /) -; t_filedim_names = (/ "time" /) - - var_info := check_filevar_existence_dims( \ - FV3LAM_wrtcmp_fn, \ - field_name, \ - nx, ny, \ - vert_inds_to_plot, \ - time_inds_to_plot) -; x_filedim_names, \ -; y_filedim_names, \ -; z_filedim_names, \ -; t_filedim_names, \ - - var_rank = var_info@var_rank - var_dim_names = var_info@var_dim_names - var_dim_sizes = var_info@var_dim_sizes - func_xy_only = var_info@func_xy_only - func_xyz_only = var_info@func_xyz_only - func_xyt_only = var_info@func_xyt_only - func_xyzt_only = var_info@func_xyzt_only - -;print("") -;print("func_xy_only = " + func_xy_only) -;print("func_xyz_only = " + func_xyz_only) -;print("func_xyt_only = " + func_xyt_only) -;print("func_xyzt_only = " + func_xyzt_only) - -; -; ********************************************************************** -; -; Read the specified field on the FV3-LAM write-component grid. -; -; ********************************************************************** -; - field_info \ - := read_FV3LAM_field_wrtcmp( \ - field_name, \ - horiz_dist_units, horiz_area_units, \ - FV3LAM_wrtcmp_fn, \ - nx, ny, \ - vert_indx, time_indx, \ - func_xy_only, func_xyz_only, func_xyt_only, func_xyzt_only) - - fp_field_FV3LAM = field_info@fp - field_desc = field_info@field_desc - field_units = field_info@field_units - field_unstruc = field_info@field_unstruc - field_min = field_info@field_min - field_max = field_info@field_max - field_median = field_info@field_median - field_mean = field_info@field_mean - field_data_type_FV3LAM = field_info@field_data_type - - plot_title = field_desc + " [" + field_units + "]" - print("") - print("plot_title = " + char_dq + plot_title + char_dq) -; -; ********************************************************************** -; -; If we want to plot output files generated by the FMS (?) on FV3's na- -; tive cubed-sphere grid ... -; -; ********************************************************************** -; -else -; -; ********************************************************************** -; -; +bdy_opts = True +bdy_opts@num_bdies = 0 +bdy_opts@plot_bdy = new(1, logical) +bdy_opts@bdy_colors = new(1, string) +bdy_opts@bdy_line_thicknesses = new(1, float) +bdy_opts@bdy_dash_patterns = new(1, integer) ; ; ********************************************************************** ; - file_name_base = "fv3_history" ; Should be a global input. +; Initialize arrays to single-element arrays. These will be appended to +; as necessary. ; ; ********************************************************************** ; -; Set the dimension names we expect to see in the file(s) from which we -; will read in the field. This depends on the file name base. These -; dimension names will be used to check the consistency of the dimen- -; sions of the specified field. -; -; ********************************************************************** -; - -; if (strcmp_exact(file_name_base, "grid_spec")) then -; x_filedim_names = (/ "grid_x", "grid_xt" /) -; y_filedim_names = (/ "grid_y", "grid_yt" /) -; z_filedim_names = (/ "phalf", "pfull" /) -; t_filedim_names = (/ "time" /) -; else if (strcmp_exact(file_name_base, "atmos_static") .or. \ -; strcmp_exact(file_name_base, "fv3_history") .or. \ -; strcmp_exact(file_name_base, "fv3_history2d") .or. \ -; strcmp_exact(file_name_base, "ref3D")) then -; x_filedim_names = (/ "grid_xt" /) -; y_filedim_names = (/ "grid_yt" /) -; z_filedim_names = (/ "phalf", "pfull" /) -; t_filedim_names = (/ "time" /) -; else -; msg := char_nl + \ -;"Unknown file base name (file_name_base) specified:" + char_nl + \ -;" file_name_base = " + char_dq + file_name_base + char_dq + char_nl + \ -;"Stopping." -; exit -; end if -; end if +num_grids := 0 +nx_all := new(1, integer) +ny_all := new(1, integer) +lon_cntrs_unstruc := new(1, double) +lat_cntrs_unstruc := new(1, double) +lon_verts_unstruc := new((/1,4/), double) +lat_verts_unstruc := new((/1,4/), double) +lon_bdy := new(1, double) +lat_bdy := new(1, double) +field_unstruc := new(1, double) ; ; ********************************************************************** ; -; Loop through the specified tiles and form the file name corresponding -; to each tile (from which the field will be read in). +; If native is set to True, read in the native FV3LAM grid. ; ; ********************************************************************** ; - file_names_by_tile = new((/ num_tiles_to_plot /), "string") - field_names_by_tile = new((/ num_tiles_to_plot /), "string") +if (native .or. halo) then +;if (native) then - print("") - print("" + separator_line) - msg := \ -"Setting file and field name for each specified tile ..." + char_nl + \ -"[The field name for a tile will be set to " + char_dq + "none" + char_dq + \ -" if a file for that tile " + char_nl + \ -"does not exist, e.g. if the tile in consideration is #5, but we are on a " + char_nl + \ -"regional grid (in which case files/fields are only available on tile #7).]" - print("" + msg) + num_grids = num_grids + 1 - do nn=0, num_tiles_to_plot-1 + nhalo_T7 = 4 ; Should this be at the top, i.e. defined as a global variable???? + ; or be a requird input that gets processed along with the other + ; command linea arguments? - print("") - msg := "nn = " + nn - print("" + msg) - underline = repeat_str("-", strlen(msg)) - print("" + underline) + grid_info := read_FV3LAM_grid_native( \ + expt_dir, \ + gtype, \ + cres, \ + inds_tiles_to_plot, \ + show_tile_bdies, \ + nhalo_T7, \ + remove_rgnl_halo) - n_tile = inds_tiles_to_plot(nn) - print("") - print(" n_tile = " + n_tile) -; -; ********************************************************************** -; -; Generate the file name for the current tile. -; -; ********************************************************************** -; - file_name := run_dir + "/" + file_name_base - if (.not. strcmp_exact(gtype, "regional")) then - file_name := file_name + ".tile" + tostring(n_tile) - end if - file_name := file_name + ".nc" - file_names_by_tile(nn) = file_name + if (remove_rgnl_halo) then + nx_all := append_to_snumeric_array(nx_all, grid_info@nx_all_tiles) + ny_all := append_to_snumeric_array(ny_all, grid_info@ny_all_tiles) + else + nx_all := append_to_snumeric_array(nx_all, grid_info@nxh_all_tiles) + ny_all := append_to_snumeric_array(ny_all, grid_info@nyh_all_tiles) + end if - print(" file_names_by_tile(" + nn + ") = " + \ - char_dq + file_names_by_tile(nn) + char_dq) -; -; ********************************************************************** -; -; -; -; ********************************************************************** -; - field_names_by_tile(nn) = field_name - if (strcmp_exact(gtype, "regional") .and. (n_tile .ne. 7)) then - field_names_by_tile(nn) = "none" - msg := char_nl + \ -" The specified field is not available on the current tile:" + char_nl + \ -" n_tile = " + n_tile + char_nl + \ -" field_name = " + char_dq + field_name + char_dq + char_nl + \ -" Setting the field name for the current tile to " + char_dq + "none" + char_dq + ":" + char_nl + \ -" field_names_by_tile(" + nn + ") = " + char_dq + field_names_by_tile(nn) + char_dq - print("" + msg) - else - print(" field_names_by_tile(" + nn + ") = " + \ - char_dq + field_names_by_tile(nn) + char_dq) - end if + lon_cntrs_unstruc \ + := append_to_snumeric_array(lon_cntrs_unstruc, grid_info@lon_cntrs_all_tiles_unstruc) + lat_cntrs_unstruc \ + := append_to_snumeric_array(lat_cntrs_unstruc, grid_info@lat_cntrs_all_tiles_unstruc) + + lon_verts_unstruc \ + := append_to_snumeric_array(lon_verts_unstruc, grid_info@lon_verts_all_tiles_unstruc) + lat_verts_unstruc \ + := append_to_snumeric_array(lat_verts_unstruc, grid_info@lat_verts_all_tiles_unstruc) + + lon_bdy := append_to_snumeric_array(lon_bdy, grid_info@lon_bdy_all_tiles) + lat_bdy := append_to_snumeric_array(lat_bdy, grid_info@lat_bdy_all_tiles) + + grid_opts@plot_gridlines \ + := array_append_record(grid_opts@plot_gridlines, native@plot_gridlines, 0) + grid_opts@gridline_colors \ + := array_append_record(grid_opts@gridline_colors, native@gridline_color, 0) + + if (native@plot_bdy) then + bdy_opts@num_bdies = bdy_opts@num_bdies + 1 + bdy_opts@plot_bdy \ + := array_append_record(bdy_opts@plot_bdy, native@plot_bdy, 0) + bdy_opts@bdy_colors \ + := array_append_record(bdy_opts@bdy_colors, native@bdy_color, 0) + bdy_opts@bdy_line_thicknesses \ + := array_append_record(bdy_opts@bdy_line_thicknesses, native@bdy_line_thickness, 0) + bdy_opts@bdy_dash_patterns \ + := array_append_record(bdy_opts@bdy_dash_patterns, native@bdy_dash_pattern, 0) + end if + +end if ; ; ********************************************************************** ; -; Perform checks on variable. +; If halo is set to True, then ... ; ; ********************************************************************** ; - if (.not. strcmp_exact(field_names_by_tile(nn), "none")) then - - if ((nn .gt. 0) .and. isvar("var_info")) then - var_info_prev_tile := var_info - end if +if (halo) then - var_info := check_filevar_existence_dims( \ - file_names_by_tile(nn), \ - field_names_by_tile(nn), \ - nx_tiles_to_plot(nn), ny_tiles_to_plot(nn), \ - vert_inds_to_plot, \ - time_inds_to_plot) -; x_filedim_names, \ -; y_filedim_names, \ -; z_filedim_names, \ -; t_filedim_names, \ - - fp_field_file = var_info@fp - var_rank = var_info@var_rank - var_dim_names = var_info@var_dim_names - var_dim_sizes = var_info@var_dim_sizes - func_xy_only = var_info@func_xy_only - func_xyz_only = var_info@func_xyz_only - func_xyt_only = var_info@func_xyt_only - func_xyzt_only = var_info@func_xyzt_only - average_in_x = var_info@average_in_x - average_in_y = var_info@average_in_y - - if ((nn .gt. 0) .and. isvar("var_info_prev_tile")) then - - n_tile_prev = inds_tiles_to_plot(nn-1) - - var_rank_prev_tile := var_info_prev_tile@var_rank - var_dim_names_prev_tile := var_info_prev_tile@var_dim_names - var_dim_sizes_prev_tile := var_info_prev_tile@var_dim_sizes - func_xy_only_prev_tile := var_info_prev_tile@func_xy_only - func_xyz_only_prev_tile := var_info_prev_tile@func_xyz_only - func_xyt_only_prev_tile := var_info_prev_tile@func_xyt_only - func_xyzt_only_prev_tile := var_info_prev_tile@func_xyzt_only - average_in_x_prev_tile := var_info_prev_tile@average_in_x - average_in_y_prev_tile := var_info_prev_tile@average_in_y - - if (var_rank .eq. var_rank_prev_tile) then - var_dim_names_differ := False - do i=0, var_rank_prev_tile-1 - if (.not. strcmp_exact(var_dim_names, var_dim_names_prev_tile(i))) then - var_dim_names_differ := True - break - end if - end do - end if - - if (var_rank .ne. var_rank_prev_tile) then - - msg := char_nl + \ -"The variable's rank (var_rank) changed from tile " + n_tile_prev + \ -" to tile " + n_tile + ":" + char_nl + \ -" var_rank_prev_tile = " + var_rank_prev_tile + char_nl + \ -" var_rank = " + var_rank + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (var_dim_names_differ) then - - var_dim_names_prev_tile_str \ - := str_join(var_dim_names_prev_tile, char_dq + ", " + char_dq) - var_dim_names_prev_tile_str \ - := "(" + char_dq + var_dim_names_prev_tile_str + char_dq + ")" - - var_dim_names_str \ - := str_join(var_dim_names, char_dq + ", " + char_dq) - var_dim_names_str \ - := "(" + char_dq + var_dim_names_str + char_dq + ")" - - msg := char_nl + \ -"The variable's dimension names (var_dim_names) changed from tile " + \ -n_tile_prev + " to " + char_nl + \ -"tile " + n_tile + ":" + char_nl + \ -" var_dim_names_prev_tile = " + var_dim_names_prev_tile_str + char_nl + \ -" var_dim_names = " + var_dim_names_str + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (any(var_dim_sizes .ne. var_dim_sizes_prev_tile)) then - - var_dim_sizes_prev_tile_str \ - := "(" + str_join(tostring(var_dim_sizes_prev_tile), ", ") + ")" - var_dim_sizes_str \ - := "(" + str_join(tostring(var_dim_sizes), ", ") + ")" - - msg := char_nl + \ -"The variable's dimension sizes (var_dim_sizes) changed from tile " + \ -n_tile_prev + " to " + char_nl + \ -"tile " + n_tile + ":" + char_nl + \ -" var_dim_sizes_prev_tile = " + var_dim_sizes_prev_tile_str + char_nl + \ -" var_dim_sizes = " + var_dim_sizes_str + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (func_xy_only .ne. func_xy_only_prev_tile) then - - msg := char_nl + \ -"The variable's functional dependence status on only the horizontal " + char_nl + \ -"coordinates x and y (func_xy_only) changed from tile " + n_tile_prev + " to " + \ -"tile " + n_tile + ":" + char_nl + \ -" func_xy_only_prev_tile = " + func_xy_only_prev_tile + char_nl + \ -" func_xy_only = " + func_xy_only + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (func_xyz_only .ne. func_xyz_only_prev_tile) then - - msg := char_nl + \ -"The variable's functional dependence status on only the horizontal " + char_nl + \ -"coordinates x and y and the vertical coordinate (func_xyz_only) " + char_nl + \ -"changed from tile " + n_tile_prev + " to tile " + n_tile + ":" + char_nl + \ -" func_xyz_only_prev_tile = " + func_xyz_only_prev_tile + char_nl + \ -" func_xyz_only = " + func_xyz_only + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (func_xyt_only .ne. func_xyt_only_prev_tile) then - - msg := char_nl + \ -"The variable's functional dependence status on only the horizontal " + char_nl + \ -"coordinates x and y and time (func_xyt_only) changed from tile " + n_tile_prev + char_nl + \ -"to tile " + n_tile + ":" + char_nl + \ -" func_xyt_only_prev_tile = " + func_xyt_only_prev_tile + char_nl + \ -" func_xyt_only = " + func_xyt_only + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (func_xyzt_only .ne. func_xyzt_only_prev_tile) then - - msg := char_nl + \ -"The variable's functional dependence status on the horizontal coordinates " + char_nl + \ -"x and y, the vertical coordinate, and time (func_xyzt_only) changed from " + char_nl + \ -"tile " + n_tile_prev + " to tile " + n_tile + ":" + char_nl + \ -" func_xyzt_only_prev_tile = " + func_xyzt_only_prev_tile + char_nl + \ -" func_xyzt_only = " + func_xyzt_only + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (average_in_x .ne. average_in_x_prev_tile) then - - msg := char_nl + \ -"The averaging in the x direction needed to obtain the variable's values " + char_nl + \ -"at cell centers (average_in_x) changed from tile " + n_tile_prev + \ -" to tile " + n_tile + ":" + char_nl + \ -" average_in_x_prev_tile = " + average_in_x_prev_tile + char_nl + \ -" average_in_x = " + average_in_x + char_nl + \ -"Stopping." - print("" + msg) - exit - - else if (average_in_y .ne. average_in_y_prev_tile) then - - msg := char_nl + \ -"The averaging in the x direction needed to obtain the variable's values " + char_nl + \ -"at cell centers (average_in_y) changed from tile " + n_tile_prev + \ -" to tile " + n_tile + ":" + char_nl + \ -" average_in_y_prev_tile = " + average_in_y_prev_tile + char_nl + \ -" average_in_y = " + average_in_y + char_nl + \ -"Stopping." - print("" + msg) - exit - - end if - end if - end if - end if - end if - end if - end if - end if - end if + num_grids = num_grids + 1 - end if +; nhalo_T7 = 4 ; Should this be at the top, i.e. defined as a global variable???? +; ; or be a requird input that gets processed along with the other +; ; command linea arguments? +; +; grid_info := read_FV3LAM_grid_native( \ +; expt_dir, \ +; gtype, \ +; cres, \ +; inds_tiles_to_plot, \ +; show_tile_bdies, \ +; nhalo_T7, \ +; False) - end if + nx_all := append_to_snumeric_array(nx_all, grid_info@nxh_all_tiles) + ny_all := append_to_snumeric_array(ny_all, grid_info@nyh_all_tiles) - end do + lon_cntrs_unstruc \ + := append_to_snumeric_array(lon_cntrs_unstruc, grid_info@lon_halo_cntrs_all_tiles_unstruc) + lat_cntrs_unstruc \ + := append_to_snumeric_array(lat_cntrs_unstruc, grid_info@lat_halo_cntrs_all_tiles_unstruc) - print("") - print("Done setting file and field name for each specified tile.") - print("" + separator_line) + lon_verts_unstruc \ + := append_to_snumeric_array(lon_verts_unstruc, grid_info@lon_halo_verts_all_tiles_unstruc) + lat_verts_unstruc \ + := append_to_snumeric_array(lat_verts_unstruc, grid_info@lat_halo_verts_all_tiles_unstruc) + lon_bdy := append_to_snumeric_array(lon_bdy, grid_info@lon_halo_bdy_all_tiles) + lat_bdy := append_to_snumeric_array(lat_bdy, grid_info@lat_halo_bdy_all_tiles) + grid_opts@plot_gridlines \ + := array_append_record(grid_opts@plot_gridlines, halo@plot_gridlines, 0) + grid_opts@gridline_colors \ + := array_append_record(grid_opts@gridline_colors, halo@gridline_color, 0) -; -; ********************************************************************** -; -; -; -; ********************************************************************** -; - field_info \ - := read_FV3LAM_field_native( \ - field_names_by_tile, \ - file_names_by_tile, \ - gtype, inds_tiles_to_plot, \ - nh_tiles_to_plot, \ - nxh_tiles_to_plot, nyh_tiles_to_plot, \ - nx_tiles_to_plot, ny_tiles_to_plot, \ - remove_halo_tiles_to_plot, \ - vert_indx, time_indx, \ - func_xy_only, func_xyz_only, func_xyt_only, func_xyzt_only, \ - average_in_x, average_in_y) - -; fp_field_FV3LAM = field_info@fp ; This would in general be an array or list of file pointers. - field_desc = field_info@field_desc - field_units = field_info@field_units - field_unstruc = field_info@field_all_tiles_unstruc - field_min_all_tiles = field_info@field_min_all_tiles - field_max_all_tiles = field_info@field_max_all_tiles - field_median_all_tiles = field_info@field_median_all_tiles - field_mean_all_tiles = field_info@field_mean_all_tiles - field_data_type_FV3LAM = field_info@field_data_type - - plot_title = field_desc + " [" + field_units + "]" - print("") - print("plot_title = " + char_dq + plot_title + char_dq) -; -; ********************************************************************** -; -; Calculate and print out basic statistics of the field over all tiles -; to be plotted. -; -; ********************************************************************** -; - temp := tostring(inds_tiles_to_plot) - temp := str_join(temp, ", ") - temp := str_concat( (/"[tile(s) ", temp, "]"/) ) - msg := "Calculating statistics of field over all FV3-LAM tiles to be plotted " + \ - temp + " ..." - print("") - print("" + separator_line) - print("" + msg) - -; print_field_stats = True - print_field_stats = False - field_stat_info \ - := calc_field_stats( \ - field_unstruc, field_desc, field_units, print_field_stats) - msg := " " + field_stat_info@msg - print("") - print("" + msg) + if (halo@plot_bdy) then + bdy_opts@num_bdies = bdy_opts@num_bdies + 1 + bdy_opts@plot_bdy \ + := array_append_record(bdy_opts@plot_bdy, halo@plot_bdy, 0) + bdy_opts@bdy_colors \ + := array_append_record(bdy_opts@bdy_colors, halo@bdy_color, 0) + bdy_opts@bdy_line_thicknesses \ + := array_append_record(bdy_opts@bdy_line_thicknesses, halo@bdy_line_thickness, 0) + bdy_opts@bdy_dash_patterns \ + := array_append_record(bdy_opts@bdy_dash_patterns, halo@bdy_dash_pattern, 0) + end if - msg := "Done calculating statistics of field over all FV3-LAM tiles to be plotted." - print("") - print("" + msg) - print("" + separator_line) +end if ; ; ********************************************************************** ; -; Save field statistics in appropriate variables. +; If wrtcmp is set to True, read in the write-component grid. ; ; ********************************************************************** ; - field_min := field_stat_info@field_min - field_max := field_stat_info@field_max - field_median := field_stat_info@field_median - field_mean := field_stat_info@field_mean - -end if - - +if (wrtcmp) then + num_grids = num_grids + 1 + FV3LAM_wrtcmp_fn = run_dir + "/" + "dynf000.nc" + get_domain_bdy = True + grid_info := read_FV3LAM_grid_wrtcmp( \ + FV3LAM_wrtcmp_fn, \ + get_domain_bdy) -; -; ********************************************************************** -; -; If plot_RAP_field is set to True, read in the coordinates of the RAP -; grid and possibly also a field on that grid. -; -; ********************************************************************** -; - if (plot_RAP_field) then -; -; ********************************************************************** -; -; Read in the RAP grid from file. -; -; ********************************************************************** -; - grid_info := read_RAP_grid(RAP_grid_fn, show_RAP_bdy) - -; fp_RAP_grid = grid_info@fp - nx_RAP = grid_info@nx - ny_RAP = grid_info@ny - lon_cntrs_unstruc_RAP = grid_info@lon_cntrs_unstruc - lat_cntrs_unstruc_RAP = grid_info@lat_cntrs_unstruc - lon_verts_unstruc_RAP = grid_info@lon_verts_unstruc - lat_verts_unstruc_RAP = grid_info@lat_verts_unstruc - lon_bdy_RAP = grid_info@lon_bdy - lat_bdy_RAP = grid_info@lat_bdy - coord_data_type_RAP = grid_info@coord_data_type -; -; ********************************************************************** -; -; Calculate the coordinates of the center of the RAP domain. -; -; ********************************************************************** -; -if (False) then - - rem_x = mod(nx_RAP, 2) - rem_y = mod(ny_RAP, 2) - - if ((rem_x .eq. 0) .and. (rem_y .eq. 0)) then - i_cntr = nx_RAP/2 - j_cntr = ny_RAP/2 - lon_RAP_cntr = lon_verts_RAP(j_cntr,i_cntr) - lat_RAP_cntr = lat_verts_RAP(j_cntr,i_cntr) - else if ((rem_x .eq. 1) .and. (rem_y .eq. 0)) then - i_cntr = (nx_RAP - 1)/2 - j_cntr = ny_RAP/2 - lon_vpts_RAP := fg->XLONG_V(:,:,:) - lat_vpts_RAP := fg->XLAT_V(:,:,:) - lon_vpts_RAP := rm_single_dims(lon_vpts_RAP) - lat_vpts_RAP := rm_single_dims(lat_vpts_RAP) - lon_RAP_cntr = lon_vpts_RAP(j_cntr,i_cntr) - lat_RAP_cntr = lat_vpts_RAP(j_cntr,i_cntr) - else if ((rem_x .eq. 0) .and. (rem_y .eq. 1)) then - i_cntr = nx_RAP/2 - j_cntr = (ny_RAP - 1)/2 - lon_upts_RAP := fg->XLONG_U(:,:,:) - lat_upts_RAP := fg->XLAT_U(:,:,:) - lon_upts_RAP := rm_single_dims(lon_upts_RAP) - lat_upts_RAP := rm_single_dims(lat_upts_RAP) - lon_RAP_cntr = lon_upts_RAP(j_cntr,i_cntr) - lat_RAP_cntr = lat_upts_RAP(j_cntr,i_cntr) - else if ((rem_x .eq. 1) .and. (rem_y .eq. 1)) then - i_cntr = (nx_RAP - 1)/2 - j_cntr = (ny_RAP - 1)/2 - lon_RAP_cntr = lon_cntrs_RAP(j_cntr,i_cntr) - lat_RAP_cntr = lat_cntrs_RAP(j_cntr,i_cntr) - end if - end if - end if - end if - - print("") - print("lon_RAP_cntr = " + lon_RAP_cntr + " deg") - print("lat_RAP_cntr = " + lat_RAP_cntr + " deg") + nx_all := append_to_snumeric_array(nx_all, grid_info@nx) + ny_all := append_to_snumeric_array(ny_all, grid_info@ny) + + lon_cntrs_unstruc \ + := append_to_snumeric_array(lon_cntrs_unstruc, grid_info@lon_cntrs_unstruc) + lat_cntrs_unstruc \ + := append_to_snumeric_array(lat_cntrs_unstruc, grid_info@lat_cntrs_unstruc) + + lon_verts_unstruc \ + := append_to_snumeric_array(lon_verts_unstruc, grid_info@lon_verts_unstruc) + lat_verts_unstruc \ + := append_to_snumeric_array(lat_verts_unstruc, grid_info@lat_verts_unstruc) + + lon_bdy := append_to_snumeric_array(lon_bdy, grid_info@lon_bdy) + lat_bdy := append_to_snumeric_array(lat_bdy, grid_info@lat_bdy) + + grid_opts@plot_gridlines \ + := array_append_record(grid_opts@plot_gridlines, wrtcmp@plot_gridlines, 0) + grid_opts@gridline_colors \ + := array_append_record(grid_opts@gridline_colors, wrtcmp@gridline_color, 0) + + if (wrtcmp@plot_bdy) then + bdy_opts@num_bdies = bdy_opts@num_bdies + 1 + bdy_opts@plot_bdy \ + := array_append_record(bdy_opts@plot_bdy, wrtcmp@plot_bdy, 0) + bdy_opts@bdy_colors \ + := array_append_record(bdy_opts@bdy_colors, wrtcmp@bdy_color, 0) + bdy_opts@bdy_line_thicknesses \ + := array_append_record(bdy_opts@bdy_line_thicknesses, wrtcmp@bdy_line_thickness, 0) + bdy_opts@bdy_dash_patterns \ + := array_append_record(bdy_opts@bdy_dash_patterns, wrtcmp@bdy_dash_pattern, 0) + end if end if + +print("") +printVarSummary(wrtcmp) ; ; ********************************************************************** ; -; Read in the specified field on the RAP domain. +; If extrnl is set to True, read in the FV3LAM grid. ; ; ********************************************************************** ; - field_info := read_RAP_field( \ - field_name, \ - horiz_dist_units, \ - horiz_area_units, \ - RAP_grid_fn, \ - nx_RAP, \ - ny_RAP) - -; fp_field_RAP = field_info@fp - field_desc_RAP = field_info@field_desc - field_units_RAP = field_info@field_units - field_unstruc_RAP = field_info@field_unstruc - field_min_RAP = field_info@field_min - field_max_RAP = field_info@field_max - field_median_RAP = field_info@field_median - field_mean_RAP = field_info@field_mean - field_data_type_RAP = field_info@field_data_type - - plot_title_RAP = field_desc_RAP + " [" + field_units_RAP + "]" - print("") - print("plot_title_RAP = " + char_dq + plot_title_RAP + char_dq) - -end if - - +if (extrnl) then + num_grids = num_grids + 1 + grid_info := read_RAP_grid(RAP_grid_fn, show_RAP_bdy) + nx_all := append_to_snumeric_array(nx_all, grid_info@nx) + ny_all := append_to_snumeric_array(ny_all, grid_info@ny) + lon_cntrs_unstruc \ + := append_to_snumeric_array(lon_cntrs_unstruc, grid_info@lon_cntrs_unstruc) + lat_cntrs_unstruc \ + := append_to_snumeric_array(lat_cntrs_unstruc, grid_info@lat_cntrs_unstruc) + lon_verts_unstruc \ + := append_to_snumeric_array(lon_verts_unstruc, grid_info@lon_verts_unstruc) + lat_verts_unstruc \ + := append_to_snumeric_array(lat_verts_unstruc, grid_info@lat_verts_unstruc) + lon_bdy := append_to_snumeric_array(lon_bdy, grid_info@lon_bdy) + lat_bdy := append_to_snumeric_array(lat_bdy, grid_info@lat_bdy) + grid_opts@plot_gridlines \ + := array_append_record(grid_opts@plot_gridlines, extrnl@plot_gridlines, 0) + grid_opts@gridline_colors \ + := array_append_record(grid_opts@gridline_colors, extrnl@gridline_color, 0) + if (extrnl@plot_bdy) then + bdy_opts@num_bdies = bdy_opts@num_bdies + 1 + bdy_opts@plot_bdy \ + := array_append_record(bdy_opts@plot_bdy, extrnl@plot_bdy, 0) + bdy_opts@bdy_colors \ + := array_append_record(bdy_opts@bdy_colors, extrnl@bdy_color, 0) + bdy_opts@bdy_line_thicknesses \ + := array_append_record(bdy_opts@bdy_line_thicknesses, extrnl@bdy_line_thickness, 0) + bdy_opts@bdy_dash_patterns \ + := array_append_record(bdy_opts@bdy_dash_patterns, extrnl@bdy_dash_pattern, 0) + end if +end if ; ; ********************************************************************** ; @@ -1177,147 +927,145 @@ end if ; ; ********************************************************************** ; - fn_graphics = cres + "_grid_f" + fcst_hr_str + "_k" + vert_indx_str - - coord_fill_val := default_fillvalue(typeof(lon_cntrs_unstruc)) +nx_all := nx_all(1:) +ny_all := ny_all(1:) +lon_cntrs_unstruc := lon_cntrs_unstruc(1:) +lat_cntrs_unstruc := lat_cntrs_unstruc(1:) +lon_verts_unstruc := lon_verts_unstruc(1:,:) +lat_verts_unstruc := lat_verts_unstruc(1:,:) +lon_bdy := lon_bdy(1:) +lat_bdy := lat_bdy(1:) +;field_unstruc := new(1, double) ; ; ********************************************************************** ; -; If plot_RAP_field is set to True, combine the coordinate arrays for -; the FV3-LAM and the RAP into a single set of arrays for plotting. -; -; ********************************************************************** -; - if (plot_RAP_field) then -; -; ********************************************************************** ; -; If the RAP coordinate arrays are not of the same data type as the FV3- -; LAM coordinate arrays, convert the data type of the former to that of -; the latter. ; ; ********************************************************************** ; - if (.not. strcmp_exact(coord_data_type_FV3LAM, coord_data_type_RAP)) then - - lon_cntrs_unstruc_RAP \ - := totype(lon_cntrs_unstruc_RAP, coord_data_type_FV3LAM) - - lat_cntrs_unstruc_RAP \ - := totype(lat_cntrs_unstruc_RAP, coord_data_type_FV3LAM) - - lon_verts_unstruc_RAP \ - := totype(lon_verts_unstruc_RAP, coord_data_type_FV3LAM) +n := dimsizes(grid_opts@plot_gridlines) +if (n .gt. 1) then + grid_opts@plot_gridlines := grid_opts@plot_gridlines(1:) + grid_opts@gridline_colors := (/ grid_opts@gridline_colors(1:) /) +end if - lat_verts_unstruc_RAP \ - := totype(lat_verts_unstruc_RAP, coord_data_type_FV3LAM) +bdy_opts@plot_bdy := (/ bdy_opts@plot_bdy(1:) /) +bdy_opts@bdy_colors := bdy_opts@bdy_colors(1:) +bdy_opts@bdy_line_thicknesses := bdy_opts@bdy_line_thicknesses(1:) +bdy_opts@bdy_dash_patterns := bdy_opts@bdy_dash_patterns(1:) +bdy_opts@num_bdy_pts_all_bdies := 2*(nx_all + ny_all) + 1 - end if +print("") +printVarSummary(grid_opts) +print("") +printVarSummary(bdy_opts) ; ; ********************************************************************** ; -; If the RAP field is not of the same data type as the FV3-LAM field, -; convert the data type of the former to that of the latter. -; -; ********************************************************************** -; - if (.not. strcmp_exact(field_data_type_FV3LAM, field_data_type_RAP)) then - - field_unstruc_RAP \ - := totype(field_unstruc_RAP, field_data_type_FV3LAM) - - end if -; -; ********************************************************************** ; -; Prepend RAP coordinates and fields to the corresponding arrays for the -; FV3-LAM so that the RAP grid is drawn first and the FV3-LAM tiles are -; then drawn on top. ; ; ********************************************************************** ; - lon_cntrs_unstruc \ - := array_append_record(lon_cntrs_unstruc_RAP, lon_cntrs_unstruc, 0) - - lat_cntrs_unstruc \ - := array_append_record(lat_cntrs_unstruc_RAP, lat_cntrs_unstruc, 0) - lon_verts_unstruc \ - := array_append_record(lon_verts_unstruc_RAP, lon_verts_unstruc, 0) +;grid_opts := True +;grid_opts@plot_gridlines := new(1, logical) +;grid_opts@gridline_colors := new(1, string) +; +;bdy_opts := True +;bdy_opts@num_bdies = 0 +;bdy_opts@plot_bdy = new(1, logical) +;bdy_opts@bdy_colors = new(1, string) +;bdy_opts@bdy_line_thicknesses = new(1, float) +;bdy_opts@bdy_dash_patterns = new(1, integer) - lat_verts_unstruc \ - := array_append_record(lat_verts_unstruc_RAP, lat_verts_unstruc, 0) - field_unstruc \ - := array_append_record(field_unstruc_RAP, field_unstruc, 0) -; -; ********************************************************************** -; -; Calculate and print out basic statistics of the field, now including -; the RAP field. +;print("AAAAAA native = " + native) +;if (native) then ; -; ********************************************************************** +; grid_opts@plot_gridlines \ +; := array_append_record(grid_opts@plot_gridlines, native@plot_gridlines, 0) +; grid_opts@gridline_colors \ +; := array_append_record(grid_opts@gridline_colors, native@gridline_color, 0) ; - msg := "Calculating statistics of combined field on FV3-LAM and RAP grids ..." - print("") - print("" + separator_line) - print("" + msg) - -; print_field_stats = True - print_field_stats = False - field_stat_info \ - := calc_field_stats( \ - field_unstruc, field_desc, field_units, print_field_stats) - msg := " " + field_stat_info@msg - print("") - print("" + msg) - - field_min := field_stat_info@field_min - field_max := field_stat_info@field_max - field_median := field_stat_info@field_median - field_mean := field_stat_info@field_mean - - msg := "Done calculating statistics of combined field on FV3-LAM and RAP grids." - print("") - print("" + msg) - print("" + separator_line) +; if (native@plot_bdy) then +; bdy_opts@num_bdies = bdy_opts@num_bdies + 1 +; bdy_opts@plot_bdy \ +; := array_append_record(bdy_opts@plot_bdy, native@plot_bdy, 0) +; bdy_opts@bdy_colors \ +; := array_append_record(bdy_opts@bdy_colors, native@bdy_color, 0) +; bdy_opts@bdy_line_thicknesses \ +; := array_append_record(bdy_opts@bdy_line_thicknesses, native@bdy_line_thickness, 0) +; bdy_opts@bdy_dash_patterns \ +; := array_append_record(bdy_opts@bdy_dash_patterns, native@bdy_dash_pattern, 0) +; end if ; -; ********************************************************************** +;end if + +;print("AAAAAA wrtcmp = " + wrtcmp) +;if (wrtcmp) then +; +; grid_opts@plot_gridlines \ +; := array_append_record(grid_opts@plot_gridlines, wrtcmp@plot_gridlines, 0) +; grid_opts@gridline_colors \ +; := array_append_record(grid_opts@gridline_colors, wrtcmp@gridline_color, 0) +; +; if (wrtcmp@plot_bdy) then +; bdy_opts@num_bdies = bdy_opts@num_bdies + 1 +; bdy_opts@plot_bdy \ +; := array_append_record(bdy_opts@plot_bdy, wrtcmp@plot_bdy, 0) +; bdy_opts@bdy_colors \ +; := array_append_record(bdy_opts@bdy_colors, wrtcmp@bdy_color, 0) +; bdy_opts@bdy_line_thicknesses \ +; := array_append_record(bdy_opts@bdy_line_thicknesses, wrtcmp@bdy_line_thickness, 0) +; bdy_opts@bdy_dash_patterns \ +; := array_append_record(bdy_opts@bdy_dash_patterns, wrtcmp@bdy_dash_pattern, 0) +; end if ; -; If show_RAP_bdy is set to True, prepend the RAP boundary coordinates -; to those for the FV3-LAM tiles. +;end if + +;print("AAAAAA extrnl = " + extrnl) +;if (extrnl) then +; +; grid_opts@plot_gridlines +; := array_append_record(grid_opts@plot_gridlines, extrnl@plot_gridlines, 0) +; grid_opts@gridline_colors \ +; := array_append_record(grid_opts@gridline_colors, extrnl@gridline_color, 0) +; +; if (extrnl@plot_bdy) then +; bdy_opts@num_bdies = bdy_opts@num_bdies + 1 +; bdy_opts@plot_bdy \ +; := array_append_record(bdy_opts@plot_bdy, extrnl@plot_bdy, 0) +; bdy_opts@bdy_colors \ +; := array_append_record(bdy_opts@bdy_colors, extrnl@bdy_color, 0) +; bdy_opts@bdy_line_thicknesses \ +; := array_append_record(bdy_opts@bdy_line_thicknesses, extrnl@bdy_line_thickness, 0) +; bdy_opts@bdy_dash_patterns \ +; := array_append_record(bdy_opts@bdy_dash_patterns, extrnl@bdy_dash_pattern, 0) +; end if ; -; ********************************************************************** +;end if + +;print("") +;printVarSummary(grid_opts) ; - if (show_RAP_bdy) then +;n := dimsizes(grid_opts@plot_gridlines) +;if (n .gt. 1) then +; grid_opts@plot_gridlines := grid_opts@plot_gridlines(1:) +; grid_opts@gridline_colors := (/ grid_opts@gridline_colors(1:) /) +;end if ; -; Perform data conversion if necessary. +;bdy_opts@plot_bdy := (/ bdy_opts@plot_bdy(1:) /) +;bdy_opts@bdy_colors := bdy_opts@bdy_colors(1:) +;bdy_opts@bdy_line_thicknesses := bdy_opts@bdy_line_thicknesses(1:) +;bdy_opts@bdy_dash_patterns := bdy_opts@bdy_dash_patterns(1:) +;bdy_opts@num_bdy_pts_all_bdies = 2*(nx_all + ny_all) + 1 ; - if (strcmp_exact(coord_data_type_FV3LAM, coord_data_type_RAP) .eq. False) then - lon_bdy_RAP := totype(lon_bdy_RAP, coord_data_type_FV3LAM) - lat_bdy_RAP := totype(lat_bdy_RAP, coord_data_type_FV3LAM) - end if - - if (.not. show_tile_bdies) then - - lon_bdy := lon_bdy_RAP - lat_bdy := lat_bdy_RAP - - else - -; lon_bdy_RAP := array_append_record(lon_bdy_RAP, coord_fill_val, 0) - lon_bdy := array_append_record(coord_fill_val, lon_bdy, 0) - lon_bdy := array_append_record(lon_bdy_RAP, lon_bdy, 0) - -; lat_bdy_RAP := array_append_record(lat_bdy_RAP, coord_fill_val, 0) - lat_bdy := array_append_record(coord_fill_val, lat_bdy, 0) - lat_bdy := array_append_record(lat_bdy_RAP, lat_bdy, 0) - - end if - - end if +;print("") +;printVarSummary(grid_opts) +;print("") +;printVarSummary(bdy_opts) - end if +;exit ; ; ********************************************************************** ; @@ -1351,9 +1099,12 @@ end if plot_opts@subreg_limits = subreg_limits end if -left_str = "AAA" -main_str = "BBB" -right_str = "CCC" +;left_str = "AAA" +;main_str = "BBB" +;right_str = "CCC" +left_str = "" +main_str = "" +right_str = "" plot_opts@left_str = left_str plot_opts@main_str = main_str @@ -1365,6 +1116,17 @@ right_str = "CCC" ; ; ********************************************************************** ; +nx_big = sum(nx_all) +ny_big = sum(ny_all) +field_unstruc := new(nx_big*ny_big, double) + + field_min := min(field_unstruc) + field_max := max(field_unstruc) + +;print("field_min = " + field_min) +;print("field_max = " + field_max) +;pause + print("") print("" + separator_line) msg := \ @@ -1386,85 +1148,11 @@ right_str = "CCC" print("Done calculating " + char_dq + "nice" + char_dq + " contour values.") print("" + separator_line) - -; -; ********************************************************************** -; -; Set the arrays containing the number of grid points in the x and y di- -; rections for all tiles and grids to be plotted. -; -; ********************************************************************** -; -;nx_all_grids := nx -;ny_all_grids := ny - -; nx_all_grids \ -; := where(remove_halo_tiles_to_plot, \ -; nx_tiles_to_plot, nxh_tiles_to_plot) -; ny_all_grids \ -; := where(remove_halo_tiles_to_plot, \ -; ny_tiles_to_plot, nyh_tiles_to_plot) - -; if (show_RAP_grid .or. plot_RAP_field) then -; nx_all_grids := array_append_record(nx_RAP, nx_all_grids, 0) -; ny_all_grids := array_append_record(ny_RAP, ny_all_grids, 0) -; end if - -; if (show_wrtcmp_grid) then -; nx_all_grids := array_append_record(nx_wrtcmp, nx_all_grids, 0) -; ny_all_grids := array_append_record(ny_wrtcmp, ny_all_grids, 0) -; end if - - - -; -; ********************************************************************** -; -; -; -; ********************************************************************** -; - -grid_opts := True -;grid_opts@num_grids = num_grids_to_plot -grid_opts@num_grids = 1 -;grid_opts@plot_grid = plot_grid -grid_opts@plot_grid = show_wrtcmp_grid -;grid_opts@gridline_colors = gridline_colors -grid_opts@gridline_colors = wrtcmp_bdy_color - - -bdy_opts := True -;bdy_opts@num_bdies = num_bdies_to_plot -bdy_opts@num_bdies = 1 -;bdy_opts@num_bdy_pts_all_bdies = num_bdy_pts_all_bdies -bdy_opts@num_bdy_pts_all_bdies = 2*(nx + ny) + 1 -;bdy_opts@plot_bdy = plot_bdy -bdy_opts@plot_bdy = show_wrtcmp_bdy -;bdy_opts@bdy_colors = bdy_colors -bdy_opts@bdy_colors = wrtcmp_bdy_color -;bdy_opts@bdy_line_thicknesses = bdy_line_thicknesses -bdy_opts@bdy_line_thicknesses = 4.0 -;bdy_opts@bdy_dash_patterns = bdy_dash_patterns -bdy_opts@bdy_dash_patterns = 1 - - -; Old way of calling plot_horiz_field + changes to get it to work with -; new way, but doesn't work. Use the new call further below, but some -; input arguments not yet defined. Should be defined as in file -; plot_FV3LAM_field_native.ncl. -; plot_info := plot_horiz_field( \ -; fn_graphics, \ -; lon_cntrs_unstruc, lat_cntrs_unstruc, \ -; lon_verts_unstruc, lat_verts_unstruc, \ -; lon_bdy, lat_bdy, \ -; field_unstruc, \ -; plot_options) - - +; fn_graphics = cres + "_grid_f" + fcst_hr_str + "_k" + vert_indx_str + fn_graphics = cres + "_grids" plot_info := plot_horiz_field( \ fn_graphics, \ - nx, ny, \ + nx_all, ny_all, \ lon_cntrs_unstruc, lat_cntrs_unstruc, \ lon_verts_unstruc, lat_verts_unstruc, \ lon_bdy, lat_bdy, \ @@ -1474,14 +1162,9 @@ bdy_opts@bdy_dash_patterns = 1 plot_opts) - -print("BYE!!!!!!!!!!!!!!!!!!!!!!!") - - - - - end do -end do +print("") +print("BYE") +exit end diff --git a/ush/NCL/plot_horiz_field.ncl b/ush/NCL/plot_horiz_field.ncl index a9c5caafd..35d9ca212 100644 --- a/ush/NCL/plot_horiz_field.ncl +++ b/ush/NCL/plot_horiz_field.ncl @@ -179,7 +179,9 @@ begin indx_start := new(num_grids, "integer") indx_end := new(num_grids, "integer") - + +print("num_grids = " + num_grids) +;pause do i=0, num_grids-1 if (i .eq. 0) then indx_start(i) = 0 @@ -192,6 +194,7 @@ begin print("") print("(nx_all_grids, ny_all_grids) = " + \ "(" + nx_all_grids + ", " + ny_all_grids + ")") +pause ; ; ********************************************************************** ; @@ -275,8 +278,10 @@ print("indx_end(i) = " + indx_end(i)) ; lon_cntrs_crnt_grid_unstruc \ := lon_cntrs_unstruc(indx_start(i):indx_end(i)) +;print("dimsizes(lon_cntrs_crnt_grid_unstruc) = " + dimsizes(lon_cntrs_crnt_grid_unstruc)) lat_cntrs_crnt_grid_unstruc \ := lat_cntrs_unstruc(indx_start(i):indx_end(i)) +;print("dimsizes(lat_cntrs_crnt_grid_unstruc) = " + dimsizes(lat_cntrs_crnt_grid_unstruc)) rsrc@sfXArray = lon_cntrs_crnt_grid_unstruc rsrc@sfYArray = lat_cntrs_crnt_grid_unstruc @@ -285,24 +290,47 @@ print("indx_end(i) = " + indx_end(i)) ; These resources must be set in order if the cnFillMode resource is set ; to "CellFill". ; +;print("XXXXXXXXXXXXXXXXXXXXXXXXXXXX") +;print("dimsizes(lon_verts_unstruc) = " + dimsizes(lon_verts_unstruc)) +;print("indx_start(i) = " + indx_start(i)) +;print("indx_end(i) = " + indx_end(i)) +;pause lon_verts_crnt_grid_unstruc \ := lon_verts_unstruc(indx_start(i):indx_end(i),:) +;print("dimsizes(lon_verts_crnt_grid_unstruc) = " + dimsizes(lon_verts_crnt_grid_unstruc)) lat_verts_crnt_grid_unstruc \ := lat_verts_unstruc(indx_start(i):indx_end(i),:) +;print("dimsizes(lat_verts_crnt_grid_unstruc) = " + dimsizes(lat_verts_crnt_grid_unstruc)) rsrc@sfXCellBounds = lon_verts_crnt_grid_unstruc rsrc@sfYCellBounds = lat_verts_crnt_grid_unstruc ; -; If the grid_opts@plot_grid(i) is set to True, draw the cell edges +; If the grid_opts@plot_gridlines(i) is set to True, draw the cell edges ; (gridlines) of the current grid. ; - if (grid_opts@plot_grid(i)) then +;print("DDDDDDDD") +;print(grid_opts) +;print("EEEEEE i = " + i) +;print(" dimsizes(grid_opts@plot_gridlines(i)) = " + dimsizes(grid_opts@plot_gridlines(i))) +;print(dimsizes(grid_opts@plot_gridlines(i))) +;print(dimsizes(grid_opts@plot_gridlines)) +;tmp := grid_opts@plot_gridlines(i) +tmp := grid_opts@plot_gridlines +;print("FFFFFFFFFFFFFF") +;print("KKKKKKKKKK tmp(i) = " + tmp(i)) +;print("GGGGGGGGGGG") +;print(dimsizes(tmp)) +;print("HHHHHHHHHHH") +;exit +; if (grid_opts@plot_gridlines(i)) then +; if ( False ) then + if (tmp(i)) then ; ; The resource cnCellFillMissingValEdgeColor should ideally set the cell ; edge color of those cells that contain missing values, but it seems to ; have no effect - at least when the field on the current grid contains ; all missing/fill values. For this reason, when the field on a grid -; contains all missing/fill values and grid_opts@plot_grid(i) for that +; contains all missing/fill values and grid_opts@plot_gridlines(i) for that ; grid is set to True (i.e. we want to see the gridlines but not a field ; on that grid), we resort to the method below in which we set the cn- ; CellFillEdgeColor resource to the color we want for the gridlines, and @@ -328,6 +356,7 @@ print("indx_end(i) = " + indx_end(i)) ; Extract the portion of the field array that contains the field values ; on the current grid. ; +;print("dimsizes(field_unstruc) = " + dimsizes(field_unstruc)) field_crnt_grid_unstruc \ := field_unstruc(indx_start(i):indx_end(i)) ; @@ -335,7 +364,7 @@ print("indx_end(i) = " + indx_end(i)) ; ues, then reset at least one value to a non-missing value (e.g. zero), ; and set the opacity of the field to 0 (transparent). We do this in ; order to be able to see the gridlines in cases in which all values in -; the field on the current grid are missing, and grid_opts@plot_grid(i) +; the field on the current grid are missing, and grid_opts@plot_gridlines(i) ; is set to True (because in that case, the cnCellFillMissingValEdgeCo- ; lor resource doesn't seem to have an effect, so we use the cnCellFill- ; EdgeColor resource instead along with setting the opacity to 0). @@ -432,6 +461,14 @@ print("indx_end(i) = " + indx_end(i)) ; rsrc@mpDataBaseVersion = "MediumRes" ; rsrc@mpDataBaseVersion = "HighRes" +; rsrc@mpDataBaseVersion = "Dynamic" + rsrc@mpDataSetName = "Earth..4" + +; rsrc@mpOutlineBoundarySets = "USStates" +; rsrc@mpOutlineBoundarySets = "AllBoundaries" +; rsrc@mpOutlineSpecifiers = (/ "United States:states", "Canada:states", "Mexico:states" /) + rsrc@mpOutlineSpecifiers = (/ "land:states" /) +; rsrc@mpOutlineDrawOrder = "PostDraw" ; ; Plot curves of constant longitude and latitude (regardless of the plot ; projection). @@ -978,6 +1015,8 @@ print("indx_end(i) = " + indx_end(i)) id_grid_bdies := new(num_bdies, "graphic") bdy_indx_end := -1 +;print("") +;print("dimsizes(id_grid_bdies) = " + dimsizes(id_grid_bdies)) do i=0, num_bdies-1 @@ -988,15 +1027,25 @@ print("indx_end(i) = " + indx_end(i)) if (show_grid_bdy(i)) then resp := True - resp@gsLineColor = bdy_opts@bdy_colors(i) - resp@gsLineThicknessF = bdy_opts@bdy_line_thicknesses(i) - resp@gsLineDashPattern = bdy_opts@bdy_dash_patterns(i) + resp@gsLineColor := bdy_opts@bdy_colors(i) + resp@gsLineThicknessF := bdy_opts@bdy_line_thicknesses(i) + resp@gsLineDashPattern := bdy_opts@bdy_dash_patterns(i) lon_crnt_bdy := lon_bdy_all_bdies(bdy_indx_start:bdy_indx_end) lat_crnt_bdy := lat_bdy_all_bdies(bdy_indx_start:bdy_indx_end) +print("") +print("i = " + i) +print("num_bdies = " + num_bdies) +print("bdy_opts@bdy_colors(i) = " + bdy_opts@bdy_colors(i)) +print("bdy_indx_start = " + bdy_indx_start) +print("bdy_indx_end = " + bdy_indx_end) +;print(resp) + id_grid_bdies(i) \ = gsn_add_polyline( \ wks, contour_map, lon_crnt_bdy, lat_crnt_bdy, resp) +; gsn_add_polyline( \ +; wks, contour_map, lon_crnt_bdy, lat_crnt_bdy, resp) end if diff --git a/ush/NCL/process_plot_params.ncl b/ush/NCL/process_plot_params.ncl index b58b42320..297cd284f 100644 --- a/ush/NCL/process_plot_params.ncl +++ b/ush/NCL/process_plot_params.ncl @@ -236,7 +236,7 @@ example_usage_and_help_str ; ********************************************************************** ; cmd = "sed --silent --regexp-extended --expression " \ - + "'s/^[ ]*(RES=)([" + char_dq + "]*)([0-9]+)([" + char_dq + "]*)(.*)/\3/p' " \ + + "'s/^[ ]*(CRES=)([" + char_dq + "]*)C([0-9]+)([" + char_dq + "]*)(.*)/\3/p' " \ + var_defns_fn res := systemfunc(cmd) ; diff --git a/ush/NCL/read_FV3LAM_grid_native.ncl b/ush/NCL/read_FV3LAM_grid_native.ncl index 7862666d8..e676163be 100644 --- a/ush/NCL/read_FV3LAM_grid_native.ncl +++ b/ush/NCL/read_FV3LAM_grid_native.ncl @@ -6,57 +6,56 @@ ; ; Description: ; ^^^^^^^^^^^ -; This function returns the file names, dimensions, cell center coordi- -; nates, and cell vertex coordinates of the grids associated with the -; specified FV3 cubed-sphere tiles (tile_inds). If get_tile_bdies is -; set to True, it also returns the coordinates of those grid cell verti- -; ces that lie on the boundary of each specified tile. +; This function returns the file names, dimensions, cell center coordinates, +; and cell vertex coordinates of the grids associated with the specified +; FV3 cubed-sphere tiles (tile_inds). If get_tile_bdies is set to True, +; it also returns the coordinates of those grid cell vertices that lie on +; the boundary of each specified tile. ; ; The input arguments to this function are as follows: ; ; expt_dir: -; This is the experiment directory created by the FV3-LAM workflow gene- -; ration script. The grid specification files corresponding to the -; cubed-sphere tiles are within subdirectories under this directory. +; This is the experiment directory created by the FV3SAR workflow generation +; script. The grid specification files corresponding to the cubed-sphere +; tiles are within subdirectories under this directory. ; ; gtype: -; This is a string containing the grid type of the FV3 cubed-sphere grid -; being read in. For files generated by the FV3-LAMR workflow, this will -; be equal to "regional". +; This is a string containing the type of the FV3 cubed-sphere grid being +; read in. For files generated by the FV3SAR workflow, this will be equal +; to "regional". ; ; cres: ; This is the C-resolution of the global cubed-sphere grid that serves ; as the "parent" of the regional grid. It consists of the character ; "C" followed by an interger that is equal to the number of grid cells ; in each of the two horizontal directions (say x and y) on each of the -; six tiles of the parent global grid. Note that this number is in ge- -; neral not equal to the number of grid cells on the regional grid (i.e. -; the one on tile 7) because the latter is given by the former multi- -; plied by a refinement factor (an integer) that is normally greater -; than 1. +; six tiles of the parent global grid. Note that this number is in general +; not equal to the number of grid cells on the regional grid (i.e. the +; one on tile 7) because the latter is given by the former multiplied by +; a refinement factor (an integer) that is normally greater than 1. ; ; tile_inds: ; The indices of the tiles (associated with ither the parent global grid ; or the regional grid) to consider in this function. ; ; get_tile_bdies: -; A logical variable that specifies whether arrays containing the coor- -; dinates of grid cell vertices that lie on the boundary of each tile -; specified in tile_inds are to be extracted and returned. +; A logical variable that specifies whether arrays containing the coordinates +; of grid cell vertices that lie on the boundary of each tile specified +; in tile_inds are to be extracted and returned. ; ; nhalo_T7: ; The width of the halo (in units of grid cells) included in the grid -; specification file for the regional grid (tile 7). If tile_inds in- -; cludes tile 7, then this is used to form the name of the grid file for -; that tile. Also, if tile_inds includes tile 7 and if remove_rgnl_halo -; is set to True, then a halo of width nhalo_T7 is removed from any ar- -; rays read in from the tile 7 grid file. This is not used if tile_inds -; does not include tile 7. +; specification file for the regional grid (tile 7). If tile_inds includes +; tile 7, then this is used to form the name of the grid file for that +; tile. Also, if tile_inds includes tile 7 and if remove_rgnl_halo is +; set to True, then a halo of width nhalo_T7 is removed from any arrays +; read in from the tile 7 grid file. This is not used if tile_inds does +; not include tile 7. ; ; remove_rgnl_halo: ; Flag indicating whether to remove a halo of width nhalo_T7 from any -; arrays read in from the tile 7 grid file. This is not used if tile_- -; inds does not include tile 7. +; arrays read in from the tile 7 grid file. This is not used if tile_inds +; does not include tile 7. ; ; ********************************************************************** ; @@ -120,8 +119,6 @@ local num_tiles_to_plot, \ \ lon_cntrs_crnt_tile_unstruc, lat_cntrs_crnt_tile_unstruc, \ lon_verts_crnt_tile_unstruc, lat_verts_crnt_tile_unstruc, \ - lon_cntrs_all_tiles_unstruc, lat_cntrs_all_tiles_unstruc, \ - lon_verts_all_tiles_unstruc, lat_verts_all_tiles_unstruc, \ \ grid_info @@ -145,12 +142,12 @@ begin ; grid_fn_all_tiles: ; Full path to the grid file corresponding to each tile. Note that the ; grid file contains information (coordinates, etc) on the supergrid of -; a given tile, where the supergrid is a grid having twice the resolu- -; tion of the actual (i.e. computational) grid. +; a given tile, where the supergrid is a grid having twice the resolution +; of the actual (i.e. computational) grid. ; ; remove_halo_all_tiles: -; Logical array that specifies whether the halo cells around a given -; tile should be removed before plotting or other processing. +; Logical array that specifies whether the halo cells around a given tile +; should be removed before plotting or other processing. ; ; nhSG_all_tiles: ; Halo width on the supergrid of each tile, in units of supergrid cells. @@ -158,12 +155,12 @@ begin ; will be zero for tiles 1 through 6. ; ; nxhSG_all_tiles, nyhSG_all_tiles: -; Number of cells, including the halo, in the x and y directions, res- -; pectively, on the supergrid of each tile. +; Number of cells, including the halo, in the x and y directions, +; respectively, on the supergrid of each tile. ; ; nxSG_all_tiles, nySG_all_tiles: -; Number of cells, excluding the halo, in the x and y directions, res- -; pectively, on the supergrid of each tile. +; Number of cells, excluding the halo, in the x and y directions, +; respectively, on the supergrid of each tile. ; ; nh_all_tiles: ; Halo width on the computational grid of each tile, in units of grid @@ -171,12 +168,12 @@ begin ; so this will be zero for tiles 1 through 6. ; ; nxh_all_tiles, nyh_all_tiles: -; Number of cells, including the halo, in the x and y directions, res- -; pectively, on the computational grid of each tile. +; Number of cells, including the halo, in the x and y directions, +; respectively, on the computational grid of each tile. ; ; nx_all_tiles, ny_all_tiles: -; Number of cells, excluding the halo, in the x and y directions, res- -; pectively, on the computational grid of each tile. +; Number of cells, excluding the halo, in the x and y directions, +; respectively, on the computational grid of each tile. ; ; coord_data_type_all_tiles: ; The data type of the coordinate arrays in the grid file corresponding @@ -222,17 +219,20 @@ begin ; ; ********************************************************************** ; -; Set the file name (including path) for the current tile. Then save -; the resut in the grid_fn_all_tiles array for later use. +; Set the file name (including path) for the current tile. Then save the +; result in the grid_fn_all_tiles array for later use. ; ; ********************************************************************** ; +; Maybe read in the new parameter DOT_OR_USCORE from the var_defns.sh file. grid_fn = cres + "_grid.tile" + n_tile +; grid_fn = cres + ".grid.tile" + n_tile if (strcmp_exact(gtype, "regional") .and. (n_tile .eq. 7)) then grid_fn = grid_fn + ".halo" + tostring(nhalo_T7) + ".nc" else grid_fn = grid_fn + ".nc" end if +; grid_fn = expt_dir + "/fix_sar/" + grid_fn grid_fn = expt_dir + "/fix_lam/" + grid_fn grid_fn_all_tiles(nn) = grid_fn @@ -361,9 +361,9 @@ begin msg := str_join(msg, char_nl) msg := char_nl + \ -"For simplicity, we require that the coordinate arrays in the files cor-" + char_nl + \ -"responding to the specified tiles all have the same data type. In this " + char_nl + \ -"case, they are not:" + char_nl + \ +"For simplicity, we require that the coordinate arrays in the files " + char_nl + \ +"corresponding to the specified tiles all have the same data type. In " + char_nl + \ +"this case, they are not:" + char_nl + \ msg + char_nl + \ "Stopping." @@ -382,12 +382,12 @@ msg + char_nl + \ ; ; ********************************************************************** ; -; Initialize the arrays that will contain the grid and boundary coordi- -; nates of all specified tiles to 1-element arrays containing missing -; values of type coord_data_type. After the coordinates are appended to -; these arrays in the loop below, the first elements of these arrays -; will be stripped away (since they are created here only to make it -; convenient to append to the arrays). +; Initialize the arrays that will contain the grid and boundary coordinates +; of all specified tiles to 1-element arrays containing missing values +; of type coord_data_type. After the coordinates are appended to these +; arrays in the loop below, the first elements of these arrays will be +; stripped away (since they are created here only to make it convenient +; to append to the arrays). ; ; ********************************************************************** ; @@ -397,6 +397,13 @@ msg + char_nl + \ lat_verts_all_tiles_unstruc := new((/1,4/), coord_data_type) lon_bdy_all_tiles := new(1, coord_data_type) lat_bdy_all_tiles := new(1, coord_data_type) + + lon_halo_cntrs_all_tiles_unstruc := new(1, coord_data_type) + lat_halo_cntrs_all_tiles_unstruc := new(1, coord_data_type) + lon_halo_verts_all_tiles_unstruc := new((/1,4/), coord_data_type) + lat_halo_verts_all_tiles_unstruc := new((/1,4/), coord_data_type) + lon_halo_bdy_all_tiles := new(1, coord_data_type) + lat_halo_bdy_all_tiles := new(1, coord_data_type) ; ; ********************************************************************** ; @@ -477,8 +484,8 @@ msg + char_nl + \ ; ; ********************************************************************** ; -; Get the coordinates of the cell vertices on the current tile from -; those of the supergrid. +; Get the coordinates of the cell vertices on the current tile from those +; of the supergrid. ; ; ********************************************************************** ; @@ -497,9 +504,32 @@ msg + char_nl + \ ; ; ********************************************************************** ; -; If on a regional grid, if the current tile is tile 7 (the regional do- -; main/grid), and if remove_rgnl_halo is set to True, then remove a halo -; of width nhalo_T7 cells from each of the coordinate arrays. +; Set arrays containing the coordinates of just the halo cells (with all +; internal cells' coordinates set to the approprite type of fill value). +; This approach allows us to more conveniently plot just the halo cells +; using the same plotting routines as for the internal cells. +; +; ********************************************************************** +; + lon_halo_cntrs_crnt_tile := lon_cntrs_crnt_tile + lon_halo_cntrs_crnt_tile(nh:nyh-nh,nh:nxh-nh) \ + = default_fillvalue(coord_data_type) + lat_halo_cntrs_crnt_tile := lat_cntrs_crnt_tile + lat_halo_cntrs_crnt_tile(nh:nyh-nh,nh:nxh-nh) \ + = default_fillvalue(coord_data_type) + + lon_halo_verts_crnt_tile := lon_verts_crnt_tile + lon_halo_verts_crnt_tile(nh+1:nyh-nh-1,nh+1:nxh-nh-1) \ + = default_fillvalue(coord_data_type) + lat_halo_verts_crnt_tile := lat_verts_crnt_tile + lat_halo_verts_crnt_tile(nh+1:nyh-nh-1,nh+1:nxh-nh-1) \ + = default_fillvalue(coord_data_type) +; +; ********************************************************************** +; +; If on a regional grid, if the current tile is tile 7 (the regional +; domain/grid), and if remove_rgnl_halo is set to True, then remove a +; halo of width nhalo_T7 cells from each of the coordinate arrays. ; ; ********************************************************************** ; @@ -555,13 +585,16 @@ msg + char_nl + \ ; arrays, and their size (i.e. the number of elements they contain) is ; equal to the number of cells on the current tile's grid (i.e. nxh*nyh ; or nx*ny). This unstructured format is useful for generating color- -; contour plots of fields on the grid that have one value per cell re- -; presented by a flat color in that cell. +; contour plots of fields on the grid that have one value per cell +; represented by a flat color in that cell. ; ; ********************************************************************** ; lon_cntrs_crnt_tile_unstruc := ndtooned(lon_cntrs_crnt_tile) lat_cntrs_crnt_tile_unstruc := ndtooned(lat_cntrs_crnt_tile) + + lon_halo_cntrs_crnt_tile_unstruc := ndtooned(lon_halo_cntrs_crnt_tile) + lat_halo_cntrs_crnt_tile_unstruc := ndtooned(lat_halo_cntrs_crnt_tile) ; ; ********************************************************************** ; @@ -575,21 +608,57 @@ msg + char_nl + \ ; ; ********************************************************************** ; + +; Get dimensions again because they depend on whether the halo is being +; removed or not (remove_rgnl_halo). + dims := dimsizes(lon_cntrs_crnt_tile) + endx := dims(1) + endy := dims(0) + lon_verts_crnt_tile_unstruc \ - := (/ ndtooned(lon_verts_crnt_tile(0:ny-1,0:nx-1)), \ - ndtooned(lon_verts_crnt_tile(0:ny-1,1:nx)), \ - ndtooned(lon_verts_crnt_tile(1:ny,1:nx)), \ - ndtooned(lon_verts_crnt_tile(1:ny,0:nx-1)) /) + := (/ ndtooned(lon_verts_crnt_tile(0:endy-1,0:endx-1)), \ + ndtooned(lon_verts_crnt_tile(0:endy-1,1:endx)), \ + ndtooned(lon_verts_crnt_tile(1:endy,1:endx)), \ + ndtooned(lon_verts_crnt_tile(1:endy,0:endx-1)) /) lon_verts_crnt_tile_unstruc \ := transpose(lon_verts_crnt_tile_unstruc) lat_verts_crnt_tile_unstruc \ - := (/ ndtooned(lat_verts_crnt_tile(0:ny-1,0:nx-1)), \ - ndtooned(lat_verts_crnt_tile(0:ny-1,1:nx)), \ - ndtooned(lat_verts_crnt_tile(1:ny,1:nx)), \ - ndtooned(lat_verts_crnt_tile(1:ny,0:nx-1)) /) + := (/ ndtooned(lat_verts_crnt_tile(0:endy-1,0:endx-1)), \ + ndtooned(lat_verts_crnt_tile(0:endy-1,1:endx)), \ + ndtooned(lat_verts_crnt_tile(1:endy,1:endx)), \ + ndtooned(lat_verts_crnt_tile(1:endy,0:endx-1)) /) lat_verts_crnt_tile_unstruc \ := transpose(lat_verts_crnt_tile_unstruc) + + +; Do same for halo coordinates. + lon_halo_verts_crnt_tile_unstruc \ + := (/ ndtooned(lon_halo_verts_crnt_tile(0:nyh-1,0:nxh-1)), \ + ndtooned(lon_halo_verts_crnt_tile(0:nyh-1,1:nxh)), \ + ndtooned(lon_halo_verts_crnt_tile(1:nyh,1:nxh)), \ + ndtooned(lon_halo_verts_crnt_tile(1:nyh,0:nxh-1)) /) + lon_halo_verts_crnt_tile_unstruc \ + := transpose(lon_halo_verts_crnt_tile_unstruc) + + lat_halo_verts_crnt_tile_unstruc \ + := (/ ndtooned(lat_halo_verts_crnt_tile(0:nyh-1,0:nxh-1)), \ + ndtooned(lat_halo_verts_crnt_tile(0:nyh-1,1:nxh)), \ + ndtooned(lat_halo_verts_crnt_tile(1:nyh,1:nxh)), \ + ndtooned(lat_halo_verts_crnt_tile(1:nyh,0:nxh-1)) /) + lat_halo_verts_crnt_tile_unstruc \ + := transpose(lat_halo_verts_crnt_tile_unstruc) + + do i=0, nxh-1 + do j=0, nyh-1 + if ((i .ge. nh) .and. (i .le. nxh-nh-1)) .and. \ + ((j .ge. nh) .and. (j .le. nyh-nh-1)) then + indx = i + j*nxh + lon_halo_verts_crnt_tile_unstruc(indx,:) = default_fillvalue(coord_data_type) + lat_halo_verts_crnt_tile_unstruc(indx,:) = default_fillvalue(coord_data_type) + end if + end do + end do ; ; ********************************************************************** ; @@ -612,6 +681,20 @@ msg + char_nl + \ lat_verts_all_tiles_unstruc \ := array_append_record( \ lat_verts_all_tiles_unstruc, lat_verts_crnt_tile_unstruc, 0) + + lon_halo_cntrs_all_tiles_unstruc \ + := array_append_record( \ + lon_halo_cntrs_all_tiles_unstruc, lon_halo_cntrs_crnt_tile_unstruc, 0) + lat_halo_cntrs_all_tiles_unstruc \ + := array_append_record( \ + lat_halo_cntrs_all_tiles_unstruc, lat_halo_cntrs_crnt_tile_unstruc, 0) + + lon_halo_verts_all_tiles_unstruc \ + := array_append_record( \ + lon_halo_verts_all_tiles_unstruc, lon_halo_verts_crnt_tile_unstruc, 0) + lat_halo_verts_all_tiles_unstruc \ + := array_append_record( \ + lat_halo_verts_all_tiles_unstruc, lat_halo_verts_crnt_tile_unstruc, 0) ; ; ********************************************************************** ; @@ -643,6 +726,30 @@ msg + char_nl + \ lat_bdy_all_tiles \ := array_append_record(lat_bdy_all_tiles, lat_bdy_crnt_tile, 0) + +; Do same for halo coordinates. +; +; First, get the coordinates of the boundary points on the current tile. +; Here, by "boundary points", we mean those cell vertices that happen to +; lie on the tile's boundary. +; + repeat_last_point = True + array_order = "ji" + bdy_info := get_rect_grid_bdy( \ + lon_halo_verts_crnt_tile, lat_halo_verts_crnt_tile, \ + repeat_last_point, array_order) + lon_halo_bdy_crnt_tile := bdy_info@x_bdy + lat_halo_bdy_crnt_tile := bdy_info@y_bdy +; +; Append to the arrays that will contain the coordinates of the boundary +; points on all specified tiles. We refer to these as the "all-tiles" +; arrays. +; + lon_halo_bdy_all_tiles \ + := array_append_record(lon_halo_bdy_all_tiles, lon_halo_bdy_crnt_tile, 0) + lat_halo_bdy_all_tiles \ + := array_append_record(lat_halo_bdy_all_tiles, lat_halo_bdy_crnt_tile, 0) + end if ; ; ********************************************************************** @@ -673,9 +780,9 @@ msg + char_nl + \ ; ********************************************************************** ; ; Set the i-indices of the domain's left (west) boundary, center, and -; right (east) boundary and the j-indices of the bottom (south) bounda- -; ry, middle (center), and top (north) boundary in the arrays containing -; the coordinates of the supergrid. +; right (east) boundary and the j-indices of the bottom (south) boundary, +; middle (center), and top (north) boundary in the arrays containing the +; coordinates of the supergrid. ; ; ********************************************************************** ; @@ -703,13 +810,13 @@ msg + char_nl + \ ; ; ********************************************************************** ; -; Check whether any of the four faces of the current tile cross the in- -; ternational date line (IDL). This is important because if so, we will -; not be able to identify the southwest (SW), southeast (SE), northwest -; (NW), and northeast (NE) corners of the tile. We perform this check -; for each face by checking whether there is a jump in the longitudes of -; grid cell corner points that lie on the face as we move along the -; face. +; Check whether any of the four faces of the current tile cross the +; international date line (IDL). This is important because if so, we +; will not be able to identify the southwest (SW), southeast (SE), +; northwest (NW), and northeast (NE) corners of the tile. We perform +; this check for each face by checking whether there is a jump in the +; longitudes of grid cell corner points that lie on the face as we move +; along the face. ; ; Note that if one (or both) of the poles lies within the tile, then one ; of the tile faces must cross the IDL. Thus, the IDL crossing check @@ -723,6 +830,9 @@ msg + char_nl + \ ; ; ********************************************************************** ; + face_id_strs := (/ "bottom", "right", "top", "left" /) + num_faces := dimsizes(face_id_strs) +if (False) then ; abs_dlon_cutoff := 0.0d+0 ; For debugging only. abs_dlon_cutoff := 180.0d+0 @@ -757,19 +867,20 @@ msg + char_nl + \ msg := char_nl + \ "The " + char_dq + face_id_str + char_dq + " boundary of the current tile " + \ "crosses the international date " + char_nl + \ -"line (IDL) because there is a jump in longitude from one grid point to " + char_nl + \ -"the next along that boundary with a magnitude that is greater than or " + char_nl + \ -"equal to the maximum allowed value specified by " + char_dq + "abs_dlon_cutoff" + char_dq + ":" + char_nl + \ -" abs_dlon_cutoff = " + abs_dlon_cutoff_str + " deg" + char_nl + \ +"line (IDL) because there is a jump in longitude (abs_dlon_max) from one " + char_nl + \ +"grid point to the next along that boundary with a magnitude that is greater " + char_nl + \ +"than or equal to the maximum allowed value specified by " + char_dq + "abs_dlon_cutoff" + char_dq + ":" + char_nl + \ " abs_dlon_max = " + abs_dlon_max_str + " deg" + char_nl + \ -"Please express the longitude and latitude of the grid points in a rota-" + char_nl + \ -"ted lat/lon coordinate system to avoid this problem." + char_nl + \ +" abs_dlon_cutoff = " + abs_dlon_cutoff_str + " deg" + char_nl + \ +"Please express the longitude and latitude of the grid points in a rotated" + char_nl + \ +"lat/lon coordinate system to avoid this problem." + char_nl + \ "Stopping." print("" + msg) exit end if end do +end if ; ; ********************************************************************** ; @@ -812,8 +923,8 @@ msg + char_nl + \ ; ; Save in lon_face_midpts_crnt_tile and lat_face_midpts_crnt_tile the ; longitudes and latitudes of the midpoints of the four faces of the -; current tile, starting with the bottom face and proceeding counter- -; clockwise to the left face. +; current tile, starting with the bottom face and proceeding counterclockwise +; to the left face. ; ; ********************************************************************** ; @@ -839,9 +950,9 @@ msg + char_nl + \ ; ; ********************************************************************** ; -; Now find the indices into lon_tile_corners_crnt_tile (or lat_tile_- -; corners_crnt_tile) of the southwest, southeast, northeast, and north- -; west corners of the current tile. +; Now find the indices into lon_tile_corners_crnt_tile (or +; lat_tile_corners_crnt_tile) of the southwest, southeast, northeast, +; and northwest corners of the current tile. ; ; ********************************************************************** ; @@ -912,25 +1023,30 @@ msg + char_nl + \ end if end do + +indx_SW := (/ 0 /) +indx_SE := (/ 1 /) +indx_NE := (/ 2 /) +indx_NW := (/ 3 /) ; ; ********************************************************************** ; -; Now rearrange the lon_tile_corners_crnt_tile and lat_tile_corners_- -; crnt_tile arrays so that the first element corresponds to the south- -; west corner of the tile, the second corresponds to the southeast cor- -; ner, the third corresponds to the northeast corner, and the fourth -; corresponds to the northwest corner. Also, rearange the lon_face_- -; midpts_crnt_tile and lat_face_midpts_crnt_tile arrays so that the -; first element corresponds to the southern face, the second corresponds -; to the eastern face, the third corresponds to the northern face, and -; the fourth corresponds to the western face. +; Now rearrange the lon_tile_corners_crnt_tile and lat_tile_corners_crnt_tile +; arrays so that the first element corresponds to the southwest corner of +; the tile, the second corresponds to the southeast corner, the third +; corresponds to the northeast corner, and the fourth corresponds to the +; northwest corner. Also, rearange the lon_face_midpts_crnt_tile and +; lat_face_midpts_crnt_tile arrays so that the first element corresponds +; to the southern face, the second corresponds to the eastern face, the +; third corresponds to the northern face, and the fourth corresponds to +; the western face. ; ; ********************************************************************** ; ; IMPORTANT NOTE: ; For a global cubed-sphere grid, for three of the tiles (the ones over -; the north and south poles and the one that straddles the IDL), the in- -; dices of the SW, SE, NE, and NW corners of the tile will not be set +; the north and south poles and the one that straddles the IDL), the +; indices of the SW, SE, NE, and NW corners of the tile will not be set ; (they will remain set to their initial missing values), so the check ; below will be triggered. Something more complex needs to be done for ; such tiles, but we do not worry about it here for now since we're only @@ -1024,9 +1140,8 @@ msg + char_nl + \ ; ; Remove the first elements in the unstructured arrays containing the ; coordinates of the grid cells and tile boundaries. Recall that these -; first elements were defined to make it convenient to append the coor- -; dinates of each consecutive tile; they contain missing values of type -; coord_data_type. +; first elements were defined to make it convenient to append the coordinates +; of each consecutive tile; they contain missing values of type coord_data_type. ; ; ********************************************************************** ; @@ -1034,9 +1149,17 @@ msg + char_nl + \ lat_cntrs_all_tiles_unstruc := lat_cntrs_all_tiles_unstruc(1:) lon_verts_all_tiles_unstruc := lon_verts_all_tiles_unstruc(1:,:) lat_verts_all_tiles_unstruc := lat_verts_all_tiles_unstruc(1:,:) + + lon_halo_cntrs_all_tiles_unstruc := lon_halo_cntrs_all_tiles_unstruc(1:) + lat_halo_cntrs_all_tiles_unstruc := lat_halo_cntrs_all_tiles_unstruc(1:) + lon_halo_verts_all_tiles_unstruc := lon_halo_verts_all_tiles_unstruc(1:,:) + lat_halo_verts_all_tiles_unstruc := lat_halo_verts_all_tiles_unstruc(1:,:) + if (get_tile_bdies) then lon_bdy_all_tiles := lon_bdy_all_tiles(1:) lat_bdy_all_tiles := lat_bdy_all_tiles(1:) + lon_halo_bdy_all_tiles := lon_halo_bdy_all_tiles(1:) + lat_halo_bdy_all_tiles := lat_halo_bdy_all_tiles(1:) end if ; ; ********************************************************************** @@ -1072,6 +1195,14 @@ msg + char_nl + \ grid_info@lon_bdy_all_tiles = lon_bdy_all_tiles grid_info@lat_bdy_all_tiles = lat_bdy_all_tiles + grid_info@lon_halo_cntrs_all_tiles_unstruc = lon_halo_cntrs_all_tiles_unstruc + grid_info@lat_halo_cntrs_all_tiles_unstruc = lat_halo_cntrs_all_tiles_unstruc + grid_info@lon_halo_verts_all_tiles_unstruc = lon_halo_verts_all_tiles_unstruc + grid_info@lat_halo_verts_all_tiles_unstruc = lat_halo_verts_all_tiles_unstruc + + grid_info@lon_halo_bdy_all_tiles = lon_halo_bdy_all_tiles + grid_info@lat_halo_bdy_all_tiles = lat_halo_bdy_all_tiles + grid_info@lon_tile_cntr_all_tiles = lon_tile_cntr_all_tiles grid_info@lat_tile_cntr_all_tiles = lat_tile_cntr_all_tiles diff --git a/ush/NCL/read_FV3LAM_grid_wrtcmp.ncl b/ush/NCL/read_FV3LAM_grid_wrtcmp.ncl index 77bddcef3..7ed14cbe9 100644 --- a/ush/NCL/read_FV3LAM_grid_wrtcmp.ncl +++ b/ush/NCL/read_FV3LAM_grid_wrtcmp.ncl @@ -19,6 +19,7 @@ loadscript(lib_location + "special_chars.ncl") loadscript(lib_location + "constants.ncl") loadscript(lib_location + "strcmp_exact.ncl") loadscript(lib_location + "get_rect_grid_bdy.ncl") +loadscript(lib_location + "interpol_extrapol_linear.ncl") undef("read_FV3LAM_grid_wrtcmp") @@ -90,15 +91,12 @@ begin ; Read in the cell vertex coordinates. ; ; ********************************************************************** -; +; if (strcmp_exact(coord_sys, "rotated_latlon") .or. \ strcmp_exact(coord_sys, "lambert_conformal")) then - lon_verts := fp->grid_xt(:,:) - lat_verts := fp->grid_yt(:,:) - -lon_verts = lon_verts*degs_per_rad -lat_verts = lat_verts*degs_per_rad + lon_cntrs := fp->lon(:,:) + lat_cntrs := fp->lat(:,:) else @@ -116,9 +114,9 @@ lat_verts = lat_verts*degs_per_rad ; ; ********************************************************************** ; - dims := dimsizes(lon_verts) - nx = dims(1) - 1 - ny = dims(0) - 1 + dims := dimsizes(lon_cntrs) + nx = dims(1) + ny = dims(0) print("") print(" nx = " + nx) @@ -126,23 +124,210 @@ lat_verts = lat_verts*degs_per_rad ; ; ********************************************************************** ; -; Calculate cell center coordinates from cell vertex coordinates. +; Calculate cell vertex coordinates from cell center coordinates. For +; vertices that are in the interior of the write-component domain, we +; simply averate the four neighboring cell center coordinates to obtain +; the coordinates of the vertex. For vertices that lie on the boundary +; of the domain, we perform linear extrapolation using the coordinates +; of vertices that lie within the domain (and whose coordinates we have +; already calculated using the coordinates of the cell centers). +; +; ********************************************************************** +; + lon_verts := new((/ ny+1, nx+1 /), coord_data_type) + lat_verts := new((/ ny+1, nx+1 /), coord_data_type) +;lon_verts = -98.5d+0 +;lat_verts = 37.5d+0 +; +; Average the coordinates of the four neighboring center points around +; each vertex that is in the interior of the domain/grid to obtain the +; coordinates of that internal vertex. +; + lon_verts(1:ny-1,1:nx-1) \ + = (lon_cntrs(0:ny-2,0:nx-2) \ + + lon_cntrs(0:ny-2,1:nx-1) \ + + lon_cntrs(1:ny-1,1:nx-1) \ + + lon_cntrs(1:ny-1,0:nx-2))/4.0d+0 + + lat_verts(1:ny-1,1:nx-1) \ + = (lat_cntrs(0:ny-2,0:nx-2) \ + + lat_cntrs(0:ny-2,1:nx-1) \ + + lat_cntrs(1:ny-1,1:nx-1) \ + + lat_cntrs(1:ny-1,0:nx-2))/4.0d+0 +; +; Create integer (index) arrays needed in the extrapolations below in the +; x direction. +; + ivec1 := new(ny-1, "integer") + ivec2 := new(ny-1, "integer") + ivec3 := new(ny-1, "integer") +; +; Extrapolate to obtain coordinates of vertices along the left boundary +; (but not including the vertices on the bottom-left and top-left corners +; of the grid). +; + i1 = 1 + i2 = 2 + i3 = 0 + ivec1 = i1 + ivec2 = i2 + ivec3 = i3 + lon_verts(1:ny-1,i3) \ + = interpol_extrapol_linear( \ + ivec1, lon_verts(1:ny-1,i1), ivec2, lon_verts(1:ny-1,i2), ivec3) + lat_verts(1:ny-1,i3) \ + = interpol_extrapol_linear( \ + ivec1, lat_verts(1:ny-1,i1), ivec2, lat_verts(1:ny-1,i2), ivec3) +; +; Extrapolate to obtain coordinates of vertices along the right boundary +; (but not including the vertices on the bottom-right and top-right corners +; of the grid). +; + i1 = nx - 2 + i2 = nx - 1 + i3 = nx + ivec1 = i1 + ivec2 = i2 + ivec3 = i3 + lon_verts(1:ny-1,i3) \ + = interpol_extrapol_linear( \ + ivec1, lon_verts(1:ny-1,i1), ivec2, lon_verts(1:ny-1,i2), ivec3) + lat_verts(1:ny-1,i3) \ + = interpol_extrapol_linear( \ + ivec1, lat_verts(1:ny-1,i1), ivec2, lat_verts(1:ny-1,i2), ivec3) +; +; Create integer (index) arrays needed in the extrapolations below in the +; y direction. +; + jvec1 := new(nx-1, "integer") + jvec2 := new(nx-1, "integer") + jvec3 := new(nx-1, "integer") +; +; Extrapolate to obtain coordinates of vertices along the bottom boundary +; (but not including the vertices on the bottom-left and bottom-right +; corners of the grid). +; + j1 = 1 + j2 = 2 + j3 = 0 + jvec1 = j1 + jvec2 = j2 + jvec3 = j3 + lon_verts(j3,1:nx-1) \ + = interpol_extrapol_linear( \ + jvec1, lon_verts(j1,1:nx-1), jvec2, lon_verts(j2,1:nx-1), jvec3) + lat_verts(j3,1:nx-1) \ + = interpol_extrapol_linear( \ + jvec1, lat_verts(j1,1:nx-1), jvec2, lat_verts(j2,1:nx-1), jvec3) +; +; Extrapolate to obtain coordinates of vertices along the top boundary +; (but not including the vertices on the top-left and top-right corners +; of the grid). +; + j1 = ny - 2 + j2 = ny - 1 + j3 = ny + jvec1 = j1 + jvec2 = j2 + jvec3 = j3 + lon_verts(j3,1:nx-1) \ + = interpol_extrapol_linear( \ + jvec1, lon_verts(j1,1:nx-1), jvec2, lon_verts(j2,1:nx-1), jvec3) + lat_verts(j3,1:nx-1) \ + = interpol_extrapol_linear( \ + jvec1, lat_verts(j1,1:nx-1), jvec2, lat_verts(j2,1:nx-1), jvec3) +; +; ********************************************************************** +; +; Extrapolate to obtain the coordinates of the vertex on the bottom-left +; corner of the grid. +; +; ********************************************************************** +; + i1 = 1 + i2 = 2 + i3 = 0 + j3 = 0 + lon_verts(j3,i3) \ + = interpol_extrapol_linear( \ + i1, lon_verts(j3,i1), i2, lon_verts(j3,i2), i3) + + j1 = 1 + j2 = 2 + j3 = 0 + i3 = 0 + lat_verts(j3,i3) \ + = interpol_extrapol_linear( \ + j1, lat_verts(j1,i3), i2, lat_verts(j2,i3), j3) +; +; ********************************************************************** +; +; Extrapolate to obtain the coordinates of the vertex on the bottom-right +; corner of the grid. +; +; ********************************************************************** +; + i1 = nx - 2 + i2 = nx - 1 + i3 = nx + j3 = 0 + lon_verts(j3,i3) \ + = interpol_extrapol_linear( \ + i1, lon_verts(j3,i1), i2, lon_verts(j3,i2), i3) + + j1 = 1 + j2 = 2 + j3 = 0 + i3 = nx + lat_verts(j3,i3) \ + = interpol_extrapol_linear( \ + j1, lat_verts(j1,i3), j2, lat_verts(j2,i3), j3) +; +; ********************************************************************** +; +; Extrapolate to obtain the coordinates of the vertex on the top-right +; corner of the grid. +; +; ********************************************************************** +; + i1 = nx - 2 + i2 = nx - 1 + i3 = nx + j3 = ny + lon_verts(j3,i3) \ + = interpol_extrapol_linear( \ + i1, lon_verts(j3,i1), i2, lon_verts(j3,i2), i3) + + j1 = ny - 2 + j2 = ny - 1 + j3 = ny + i3 = nx + lat_verts(j3,i3) \ + = interpol_extrapol_linear( \ + j1, lat_verts(j1,i3), j2, lat_verts(j2,i3), j3) +; +; ********************************************************************** +; +; Extrapolate to obtain the coordinates of the vertex on the top-left +; corner of the grid. ; ; ********************************************************************** ; -; lon_cntrs := new((/ ny, nx /), coord_data_type) - lon_cntrs = lon_verts(0:ny-1,0:nx-1) \ - + lon_verts(0:ny-1,1:nx) \ - + lon_verts(1:ny,1:nx) \ - + lon_verts(1:ny,0:nx-1) - lon_cntrs = 0.25d+0*lon_cntrs + i1 = 1 + i2 = 2 + i3 = 0 + j3 = ny + lon_verts(j3,i3) \ + = interpol_extrapol_linear( \ + i1, lon_verts(j3,i1), i2, lon_verts(j3,i2), i3) -; lat_cntrs := new((/ ny, nx /), coord_data_type) - lat_cntrs = lat_verts(0:ny-1,0:nx-1) \ - + lat_verts(0:ny-1,1:nx) \ - + lat_verts(1:ny,1:nx) \ - + lat_verts(1:ny,0:nx-1) - lat_cntrs = 0.25d+0*lat_cntrs + j1 = ny - 2 + j2 = ny - 1 + j3 = ny + i3 = 0 + lat_verts(j3,i3) \ + = interpol_extrapol_linear( \ + j1, lat_verts(j1,i3), j2, lat_verts(j2,i3), j3) ; ; ********************************************************************** ; diff --git a/ush/set_predef_grid_params.sh b/ush/set_predef_grid_params.sh index 636fcf70c..80c37d51b 100644 --- a/ush/set_predef_grid_params.sh +++ b/ush/set_predef_grid_params.sh @@ -340,16 +340,16 @@ predefined domain: ESGgrid_DELX="25000.0" ESGgrid_DELY="25000.0" - ESGgrid_NX=204 - ESGgrid_NY=114 + ESGgrid_NX=200 + ESGgrid_NY=112 ESGgrid_WIDE_HALO_WIDTH=6 DT_ATMOS="300" - LAYOUT_X="6" + LAYOUT_X="5" LAYOUT_Y="2" - BLOCKSIZE="34" + BLOCKSIZE="40" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" @@ -359,10 +359,10 @@ predefined domain: WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="201" - WRTCMP_ny="109" - WRTCMP_lon_lwr_left="-121.52372751" - WRTCMP_lat_lwr_left="23.57183129" + WRTCMP_nx="197" + WRTCMP_ny="107" + WRTCMP_lon_lwr_left="-121.12455072" + WRTCMP_lat_lwr_left="23.89394570" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -394,16 +394,16 @@ predefined domain: ESGgrid_DELX="13000.0" ESGgrid_DELY="13000.0" - ESGgrid_NX=400 - ESGgrid_NY=232 + ESGgrid_NX=384 + ESGgrid_NY=224 ESGgrid_WIDE_HALO_WIDTH=6 - DT_ATMOS="180" + DT_ATMOS="45" LAYOUT_X="16" LAYOUT_Y="8" - BLOCKSIZE="29" + BLOCKSIZE="32" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" @@ -413,10 +413,10 @@ predefined domain: WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="397" - WRTCMP_ny="225" - WRTCMP_lon_lwr_left="-121.93788248" - WRTCMP_lat_lwr_left="22.51531359" + WRTCMP_nx="381" + WRTCMP_ny="217" + WRTCMP_lon_lwr_left="-121.11782706" + WRTCMP_lat_lwr_left="23.18443988" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi @@ -448,16 +448,16 @@ predefined domain: ESGgrid_DELX="3000.0" ESGgrid_DELY="3000.0" - ESGgrid_NX=1740 - ESGgrid_NY=1036 + ESGgrid_NX=1680 + ESGgrid_NY=1024 ESGgrid_WIDE_HALO_WIDTH=6 DT_ATMOS="40" LAYOUT_X="30" - LAYOUT_Y="14" - BLOCKSIZE="29" + LAYOUT_Y="16" + BLOCKSIZE="32" if [ "$QUILTING" = "TRUE" ]; then WRTCMP_write_groups="1" @@ -467,10 +467,10 @@ predefined domain: WRTCMP_cen_lat="${ESGgrid_LAT_CTR}" WRTCMP_stdlat1="${ESGgrid_LAT_CTR}" WRTCMP_stdlat2="${ESGgrid_LAT_CTR}" - WRTCMP_nx="1738" - WRTCMP_ny="1012" - WRTCMP_lon_lwr_left="-122.07320852" - WRTCMP_lat_lwr_left="21.93831404" + WRTCMP_nx="1678" + WRTCMP_ny="1002" + WRTCMP_lon_lwr_left="-121.29805882" + WRTCMP_lat_lwr_left="22.26588883" WRTCMP_dx="${ESGgrid_DELX}" WRTCMP_dy="${ESGgrid_DELY}" fi From 2163fb387b9b968681cb8297b37fb668631d161a Mon Sep 17 00:00:00 2001 From: gsketefian <31046882+gsketefian@users.noreply.github.com> Date: Fri, 23 Oct 2020 13:57:24 -0600 Subject: [PATCH 38/39] Remove redundant model_configure.${CCPP_PHYS_SUITE} template files; use Jinja2 to create model_configure (#321) ## DESCRIPTION OF CHANGES: * Remove model_configure template files whose names depend on the physics suite, i.e. files with names of the form model_configure.${CCPP_PHYS_SUITE}. Only a single template file is needed because the contents of the model_configure file are not suite dependent. This leaves just one template file (named model_configure). * Change the function create_model_configure_file.sh and the template file model_configure so they use jinja2 instead of sed to replace placeholder values. * Absorb the contents of the write-component template files wrtcmp_lambert_conformal, wrtcmp_regional_latlon, and wrtcmp_rotated_latlon into the new jinja2-compliant model_configure file. We can do this because Jinja2 allows use of if-statements in the template file. * In the new model_configure jinja2 template file, include comments to explain the various write-component parameters. ## TESTS CONDUCTED: On Hera, ran the two WE2E tests new_ESGgrid and new_GFDLgrid. The first uses a "lambert_conformal" type of write-component grid, and the second uses a "rotated_latlon" type of write-component grid. (The write-component also allows "regional_latlon" type grids, which is just the usual earth-relative latlon coordinate system, but we do not have any cases that use that.) Both tests succeeded. ## ISSUE (optional): This PR resolves issue #281. --- ush/create_model_configure_file.sh | 146 ++++++++------ ush/set_predef_grid_params.sh | 4 +- ush/setup.sh | 33 +--- ush/templates/model_configure | 178 ++++++++++++++++-- ush/templates/model_configure.FV3_CPT_v0 | 23 --- .../model_configure.FV3_GFS_2017_gfdlmp | 23 --- ...del_configure.FV3_GFS_2017_gfdlmp_regional | 23 --- ush/templates/model_configure.FV3_GFS_v15p2 | 23 --- ush/templates/model_configure.FV3_GFS_v16beta | 23 --- ush/templates/model_configure.FV3_GSD_SAR | 23 --- ush/templates/model_configure.FV3_GSD_SAR_v1 | 23 --- ush/templates/model_configure.FV3_GSD_v0 | 23 --- ush/templates/model_configure.FV3_RRFS_v0 | 23 --- ush/templates/model_configure.FV3_RRFS_v1beta | 23 --- ush/templates/wrtcmp_lambert_conformal | 25 --- ush/templates/wrtcmp_regional_latlon | 23 --- ush/templates/wrtcmp_rotated_latlon | 23 --- 17 files changed, 264 insertions(+), 398 deletions(-) delete mode 100644 ush/templates/model_configure.FV3_CPT_v0 delete mode 100644 ush/templates/model_configure.FV3_GFS_2017_gfdlmp delete mode 100644 ush/templates/model_configure.FV3_GFS_2017_gfdlmp_regional delete mode 100644 ush/templates/model_configure.FV3_GFS_v15p2 delete mode 100644 ush/templates/model_configure.FV3_GFS_v16beta delete mode 100644 ush/templates/model_configure.FV3_GSD_SAR delete mode 100644 ush/templates/model_configure.FV3_GSD_SAR_v1 delete mode 100644 ush/templates/model_configure.FV3_GSD_v0 delete mode 100644 ush/templates/model_configure.FV3_RRFS_v0 delete mode 100644 ush/templates/model_configure.FV3_RRFS_v1beta delete mode 100644 ush/templates/wrtcmp_lambert_conformal delete mode 100644 ush/templates/wrtcmp_regional_latlon delete mode 100644 ush/templates/wrtcmp_rotated_latlon diff --git a/ush/create_model_configure_file.sh b/ush/create_model_configure_file.sh index 0707ddc4a..f64e96c07 100644 --- a/ush/create_model_configure_file.sh +++ b/ush/create_model_configure_file.sh @@ -68,15 +68,14 @@ nthreads \ # #----------------------------------------------------------------------- # - local i \ - model_config_fp \ - yyyy \ + local yyyy \ mm \ dd \ hh \ - mm \ dot_quilting_dot \ - dot_print_esmf_dot + dot_print_esmf_dot \ + settings \ + model_config_fp # #----------------------------------------------------------------------- # @@ -89,12 +88,6 @@ Creating a model configuration file (\"${MODEL_CONFIG_FN}\") in the specified run directory (run_dir): run_dir = \"${run_dir}\"" # -# Copy template model configure files from the templates directory to the -# run directory. -# - model_config_fp="${run_dir}/${MODEL_CONFIG_FN}" - cp_vrfy "${MODEL_CONFIG_TMPL_FP}" "${model_config_fp}" -# # Extract from cdate the starting year, month, day, and hour of the forecast. # yyyy=${cdate:0:4} @@ -106,65 +99,106 @@ run directory (run_dir): # dot_quilting_dot="."${QUILTING,,}"." dot_print_esmf_dot="."${PRINT_ESMF,,}"." - - set_file_param "${model_config_fp}" "PE_MEMBER01" "${PE_MEMBER01}" - set_file_param "${model_config_fp}" "dt_atmos" "${DT_ATMOS}" - set_file_param "${model_config_fp}" "start_year" "$yyyy" - set_file_param "${model_config_fp}" "start_month" "$mm" - set_file_param "${model_config_fp}" "start_day" "$dd" - set_file_param "${model_config_fp}" "start_hour" "$hh" - set_file_param "${model_config_fp}" "nhours_fcst" "${FCST_LEN_HRS}" - set_file_param "${model_config_fp}" "ncores_per_node" "${NCORES_PER_NODE}" - set_file_param "${model_config_fp}" "quilting" "${dot_quilting_dot}" - set_file_param "${model_config_fp}" "print_esmf" "${dot_print_esmf_dot}" - set_file_param "${model_config_fp}" "atmos_nthreads" "${nthreads:-1}" # #----------------------------------------------------------------------- # -# If the write component is to be used, then a set of parameters, including -# those that define the write component's output grid, need to be specified -# in the model configuration file (model_config_fp). This is done by -# appending a template file (in which some write-component parameters are -# set to actual values while others are set to placeholders) to model_config_fp -# and then replacing the placeholder values in the (new) model_config_fp -# file with actual values. The full path of this template file is specified -# in the workflow variable WRTCMP_PARAMS_TMPL_FP. +# Create a multiline variable that consists of a yaml-compliant string +# specifying the values that the jinja variables in the template +# model_configure file should be set to. # #----------------------------------------------------------------------- +# + settings="\ + 'PE_MEMBER01': ${PE_MEMBER01} + 'start_year': $yyyy + 'start_month': $mm + 'start_day': $dd + 'start_hour': $hh + 'nhours_fcst': ${FCST_LEN_HRS} + 'dt_atmos': ${DT_ATMOS} + 'atmos_nthreads': ${nthreads:-1} + 'ncores_per_node': ${NCORES_PER_NODE} + 'quilting': ${dot_quilting_dot} + 'print_esmf': ${dot_print_esmf_dot} + 'output_grid': ${WRTCMP_output_grid}" +# 'output_grid': \'${WRTCMP_output_grid}\'" +# +# If the write-component is to be used, then specify a set of computational +# parameters and a set of grid parameters. The latter depends on the type +# (coordinate system) of the grid that the write-component will be using. # if [ "$QUILTING" = "TRUE" ]; then - cat ${WRTCMP_PARAMS_TMPL_FP} >> ${model_config_fp} + settings="${settings} + 'write_groups': ${WRTCMP_write_groups} + 'write_tasks_per_group': ${WRTCMP_write_tasks_per_group} + 'cen_lon': ${WRTCMP_cen_lon} + 'cen_lat': ${WRTCMP_cen_lat} + 'lon1': ${WRTCMP_lon_lwr_left} + 'lat1': ${WRTCMP_lat_lwr_left}" + + if [ "${WRTCMP_output_grid}" = "lambert_conformal" ]; then + + settings="${settings} + 'stdlat1': ${WRTCMP_stdlat1} + 'stdlat2': ${WRTCMP_stdlat2} + 'nx': ${WRTCMP_nx} + 'ny': ${WRTCMP_ny} + 'dx': ${WRTCMP_dx} + 'dy': ${WRTCMP_dy} + 'lon2': \"\" + 'lat2': \"\" + 'dlon': \"\" + 'dlat': \"\"" - set_file_param "${model_config_fp}" "write_groups" "${WRTCMP_write_groups}" - set_file_param "${model_config_fp}" "write_tasks_per_group" "${WRTCMP_write_tasks_per_group}" + elif [ "${WRTCMP_output_grid}" = "regional_latlon" ] || \ + [ "${WRTCMP_output_grid}" = "rotated_latlon" ]; then - set_file_param "${model_config_fp}" "output_grid" "\'${WRTCMP_output_grid}\'" - set_file_param "${model_config_fp}" "cen_lon" "${WRTCMP_cen_lon}" - set_file_param "${model_config_fp}" "cen_lat" "${WRTCMP_cen_lat}" - set_file_param "${model_config_fp}" "lon1" "${WRTCMP_lon_lwr_left}" - set_file_param "${model_config_fp}" "lat1" "${WRTCMP_lat_lwr_left}" + settings="${settings} + 'lon2': ${WRTCMP_lon_upr_rght} + 'lat2': ${WRTCMP_lat_upr_rght} + 'dlon': ${WRTCMP_dlon} + 'dlat': ${WRTCMP_dlat} + 'stdlat1': \"\" + 'stdlat2': \"\" + 'nx': \"\" + 'ny': \"\" + 'dx': \"\" + 'dy': \"\"" - if [ "${WRTCMP_output_grid}" = "rotated_latlon" ]; then - set_file_param "${model_config_fp}" "lon2" "${WRTCMP_lon_upr_rght}" - set_file_param "${model_config_fp}" "lat2" "${WRTCMP_lat_upr_rght}" - set_file_param "${model_config_fp}" "dlon" "${WRTCMP_dlon}" - set_file_param "${model_config_fp}" "dlat" "${WRTCMP_dlat}" - elif [ "${WRTCMP_output_grid}" = "lambert_conformal" ]; then - set_file_param "${model_config_fp}" "stdlat1" "${WRTCMP_stdlat1}" - set_file_param "${model_config_fp}" "stdlat2" "${WRTCMP_stdlat2}" - set_file_param "${model_config_fp}" "nx" "${WRTCMP_nx}" - set_file_param "${model_config_fp}" "ny" "${WRTCMP_ny}" - set_file_param "${model_config_fp}" "dx" "${WRTCMP_dx}" - set_file_param "${model_config_fp}" "dy" "${WRTCMP_dy}" - elif [ "${WRTCMP_output_grid}" = "regional_latlon" ]; then - set_file_param "${model_config_fp}" "lon2" "${WRTCMP_lon_upr_rght}" - set_file_param "${model_config_fp}" "lat2" "${WRTCMP_lat_upr_rght}" - set_file_param "${model_config_fp}" "dlon" "${WRTCMP_dlon}" - set_file_param "${model_config_fp}" "dlat" "${WRTCMP_dlat}" fi fi + + print_info_msg $VERBOSE " +The variable \"settings\" specifying values to be used in the \"${MODEL_CONFIG_FN}\" +file has been set as follows: +#----------------------------------------------------------------------- +settings = +$settings" +# +#----------------------------------------------------------------------- +# +# Call a python script to generate the experiment's actual MODEL_CONFIG_FN +# file from the template file. +# +#----------------------------------------------------------------------- +# + model_config_fp="${run_dir}/${MODEL_CONFIG_FN}" + $USHDIR/fill_jinja_template.py -q \ + -u "${settings}" \ + -t ${MODEL_CONFIG_TMPL_FP} \ + -o ${model_config_fp} || \ + print_err_msg_exit "\ +Call to python script fill_jinja_template.py to create a \"${MODEL_CONFIG_FN}\" +file from a jinja2 template failed. Parameters passed to this script are: + Full path to template rocoto XML file: + MODEL_CONFIG_TMPL_FP = \"${MODEL_CONFIG_TMPL_FP}\" + Full path to output rocoto XML file: + model_config_fp = \"${model_config_fp}\" + Namelist settings specified on command line: + settings = +$settings" # #----------------------------------------------------------------------- # diff --git a/ush/set_predef_grid_params.sh b/ush/set_predef_grid_params.sh index 80c37d51b..7151d1632 100644 --- a/ush/set_predef_grid_params.sh +++ b/ush/set_predef_grid_params.sh @@ -34,7 +34,9 @@ local func_name="${FUNCNAME[0]}" # domain (PREDEF_GRID_NAME). Note that the code will enter this script # only if PREDEF_GRID_NAME has a valid (and non-empty) value. # -# The following needs to be updated: +#################### +# The following comments need to be updated: +#################### # # 1) Reset the experiment title (expt_title). # 2) Reset the grid parameters. diff --git a/ush/setup.sh b/ush/setup.sh index 7a50b5d08..8bd6e374e 100755 --- a/ush/setup.sh +++ b/ush/setup.sh @@ -1131,7 +1131,7 @@ dot_ccpp_phys_suite_or_null=".${CCPP_PHYS_SUITE}" DATA_TABLE_TMPL_FN="${DATA_TABLE_FN}" DIAG_TABLE_TMPL_FN="${DIAG_TABLE_FN}${dot_ccpp_phys_suite_or_null}" FIELD_TABLE_TMPL_FN="${FIELD_TABLE_FN}${dot_ccpp_phys_suite_or_null}" -MODEL_CONFIG_TMPL_FN="${MODEL_CONFIG_FN}${dot_ccpp_phys_suite_or_null}" +MODEL_CONFIG_TMPL_FN="${MODEL_CONFIG_FN}" NEMS_CONFIG_TMPL_FN="${NEMS_CONFIG_FN}" DATA_TABLE_TMPL_FP="${TEMPLATE_DIR}/${DATA_TABLE_TMPL_FN}" @@ -1979,42 +1979,19 @@ fi # #----------------------------------------------------------------------- # -# Initialize the full path to the template file containing placeholder -# values for the write component parameters. Then, if the write component -# is going to be used to write output files to disk (i.e. if QUILTING is -# set to "TRUE"), set the full path to this file. This file will be -# appended to the NEMS configuration file (MODEL_CONFIG_FN), and placeholder -# values will be replaced with actual ones. +# If the write-component is going to be used to write output files to +# disk (i.e. if QUILTING is set to "TRUE"), make sure that the grid type +# used by the write-component (WRTCMP_output_grid) is set to a valid value. # #----------------------------------------------------------------------- # -WRTCMP_PARAMS_TMPL_FP="" - if [ "$QUILTING" = "TRUE" ]; then -# -# First, make sure that WRTCMP_output_grid is set to a valid value. -# err_msg="\ The coordinate system used by the write-component output grid specified in WRTCMP_output_grid is not supported: WRTCMP_output_grid = \"${WRTCMP_output_grid}\"" check_var_valid_value \ "WRTCMP_output_grid" "valid_vals_WRTCMP_output_grid" "${err_msg}" -# -# Now set the name of the write-component template file. -# - wrtcmp_params_tmpl_fn=${wrtcmp_params_tmpl_fn:-"wrtcmp_${WRTCMP_output_grid}"} -# -# Finally, set the full path to the write component template file and -# make sure that the file exists. -# - WRTCMP_PARAMS_TMPL_FP="${TEMPLATE_DIR}/${wrtcmp_params_tmpl_fn}" - if [ ! -f "${WRTCMP_PARAMS_TMPL_FP}" ]; then - print_err_msg_exit "\ -The write-component template file does not exist or is not a file: - WRTCMP_PARAMS_TMPL_FP = \"${WRTCMP_PARAMS_TMPL_FP}\"" - fi - fi # #----------------------------------------------------------------------- @@ -2483,8 +2460,6 @@ NEMS_CONFIG_FP="${NEMS_CONFIG_FP}" FV3_EXEC_FP="${FV3_EXEC_FP}" LOAD_MODULES_RUN_TASK_FP="${LOAD_MODULES_RUN_TASK_FP}" - -WRTCMP_PARAMS_TMPL_FP="${WRTCMP_PARAMS_TMPL_FP}" # #----------------------------------------------------------------------- # diff --git a/ush/templates/model_configure b/ush/templates/model_configure index 083016571..33b0e527c 100644 --- a/ush/templates/model_configure +++ b/ush/templates/model_configure @@ -1,23 +1,179 @@ total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: +PE_MEMBER01: {{ PE_MEMBER01 }} +start_year: {{ start_year }} +start_month: {{ start_month }} +start_day: {{ start_day }} +start_hour: {{ start_hour }} start_minute: 0 start_second: 0 -nhours_fcst: +nhours_fcst: {{ nhours_fcst }} RUN_CONTINUE: .false. ENS_SPS: .false. -dt_atmos: +dt_atmos: {{ dt_atmos }} cpl: .false. calendar: 'julian' memuse_verbose: .false. -atmos_nthreads: +atmos_nthreads: {{ atmos_nthreads }} use_hyper_thread: .false. -ncores_per_node: +ncores_per_node: {{ ncores_per_node }} debug_affinity: .true. restart_interval: 0 output_1st_tstep_rst: .false. -quilting: -print_esmf: +print_esmf: {{ print_esmf }} +quilting: {{ quilting }} + +{% if quilting %} +# +# Write-component (quilting) computational parameters. +# +write_groups: {{ write_groups }} +write_tasks_per_group: {{ write_tasks_per_group }} +num_files: 2 +filename_base: 'dyn''phy' +output_file: 'netcdf' +write_nemsioflip: .false. +write_fsyncflag: .false. +# +# Write-component output frequency parameter definitions: +# +# nfhout: +# Output frequency in hours after forecast hour "nfhmax_hf". +# +# nfhmax_hf: +# Number of forecast hours until output frequency "nfhout" takes affect. +# +# nfhout_hf: +# Output frequency in hours until forecast hour "nfhmax_hf". +# +# nsout: +# Output frequency in time steps (positive values override "nfhout" and +# "nfhout_hf"). +# +nfhout: 1 +nfhmax_hf: 60 +nfhout_hf: 1 +nsout: -1 +# +# Coordinate system used by the output grid. +# +output_grid: '{{ output_grid }}' +# +# Parameter definitions for an output grid of type "{{ output_grid }}": +# + {%- if output_grid == "lambert_conformal" %} +# cen_lon: +# Longitude of center of grid (degrees). +# +# cen_lat: +# Latitude of center of grid (degrees). +# +# stdlat1: +# Latitude of first standard parallel (degrees). +# +# stdlat2: +# Latitude of second standard parallel (degrees). +# +# nx: +# Number of grid cells along x-axis in Lambert conformal (x,y) plane. +# +# ny: +# Number of grid cells along y-axis in Lambert conformal (x,y) plane. +# +# lon1: +# Longitude of center of grid cell at bottom-left corner of grid (degrees). +# +# lat1: +# Latitude of center of grid cell at bottom-left corner of grid (degrees). +# +# dx: +# Grid cell size in x direction (meters). +# +# dy: +# Grid cell size in y direction (meters). +# + {%- elif output_grid == "regional_latlon" %} +# cen_lon: +# Longitude of center of grid (degrees). +# +# cen_lat: +# Latitude of center of grid (degrees). +# +# lon1: +# Longitude of center of lower-left (southwest) grid cell (degrees). +# +# lat1: +# Latitude of center of lower-left (southwest) grid cell (degrees). +# +# lon2: +# Longitude of center of upper-right (northeast) grid cell (degrees). +# +# lat2: +# Latitude of center of upper-right (northeast) grid cell (degrees). +# +# dlon: +# Longitudinal grid size (degrees). +# +# dlat: +# Latitudinal grid size (degrees). +# + {%- elif output_grid == "rotated_latlon" %} +# cen_lon: +# Longitude of center of grid, expressed in the NON-ROTATED latlon +# coordinate system (degrees). This is also the longitude of the point +# at which the equator and prime meridian of the ROTATED coordinate +# system intersect (i.e. the point at which the longitude and latitude +# in the ROTATED latlon coordinate system are both 0). +# +# cen_lat: +# Latitude of center of grid, expressed in the NON-ROTATED latlon +# coordinate system (degrees). This is also the latitude of the point +# at which the equator and prime meridian of the ROTATED coordinate system +# intersect (i.e. the point at which the longitude and latitude in the +# ROTATED latlon coordinate system are both 0). +# +# lon1: +# Longitude of center of lower-left grid cell, expressed in the ROTATED +# latlon coordinate system (degrees). +# +# lat1: +# Latitude of center of lower-left grid cell, expressed in the ROTATED +# latlon coordinate system (degrees). +# +# lon2: +# Longitude of center of upper-right grid cell, expressed in the ROTATED +# latlon coordinate system (degrees). +# +# lat2: +# Latitude of center of upper-right grid cell, expressed in the ROTATED +# latlon coordinate system (degrees). +# +# dlon: +# Longitudinal grid size in the ROTATED latlon coordinate system (degrees). +# +# dlat: +# Latitudinal grid size in the ROTATED latlon coordinate system (degrees). +# + {%- endif %} + {%- if output_grid == "lambert_conformal" %} +cen_lon: {{ cen_lon }} +cen_lat: {{ cen_lat }} +stdlat1: {{ stdlat1 }} +stdlat2: {{ stdlat2 }} +nx: {{ nx }} +ny: {{ ny }} +lon1: {{ lon1 }} +lat1: {{ lat1 }} +dx: {{ dx }} +dy: {{ dy }} + {%- elif (output_grid == "regional_latlon") or (output_grid == "rotated_latlon") %} +cen_lon: {{ cen_lon }} +cen_lat: {{ cen_lat }} +lon1: {{ lon1 }} +lat1: {{ lat1 }} +lon2: {{ lon2 }} +lat2: {{ lat2 }} +dlon: {{ dlon }} +dlat: {{ dlat }} + {%- endif %} +{%- endif %} + diff --git a/ush/templates/model_configure.FV3_CPT_v0 b/ush/templates/model_configure.FV3_CPT_v0 deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_CPT_v0 +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GFS_2017_gfdlmp b/ush/templates/model_configure.FV3_GFS_2017_gfdlmp deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GFS_2017_gfdlmp +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GFS_2017_gfdlmp_regional b/ush/templates/model_configure.FV3_GFS_2017_gfdlmp_regional deleted file mode 100644 index baa69d879..000000000 --- a/ush/templates/model_configure.FV3_GFS_2017_gfdlmp_regional +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GFS_v15p2 b/ush/templates/model_configure.FV3_GFS_v15p2 deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GFS_v15p2 +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GFS_v16beta b/ush/templates/model_configure.FV3_GFS_v16beta deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GFS_v16beta +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GSD_SAR b/ush/templates/model_configure.FV3_GSD_SAR deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GSD_SAR +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GSD_SAR_v1 b/ush/templates/model_configure.FV3_GSD_SAR_v1 deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GSD_SAR_v1 +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_GSD_v0 b/ush/templates/model_configure.FV3_GSD_v0 deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_GSD_v0 +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_RRFS_v0 b/ush/templates/model_configure.FV3_RRFS_v0 deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_RRFS_v0 +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/model_configure.FV3_RRFS_v1beta b/ush/templates/model_configure.FV3_RRFS_v1beta deleted file mode 100644 index 083016571..000000000 --- a/ush/templates/model_configure.FV3_RRFS_v1beta +++ /dev/null @@ -1,23 +0,0 @@ -total_member: 1 -PE_MEMBER01: -start_year: -start_month: -start_day: -start_hour: -start_minute: 0 -start_second: 0 -nhours_fcst: -RUN_CONTINUE: .false. -ENS_SPS: .false. -dt_atmos: -cpl: .false. -calendar: 'julian' -memuse_verbose: .false. -atmos_nthreads: -use_hyper_thread: .false. -ncores_per_node: -debug_affinity: .true. -restart_interval: 0 -output_1st_tstep_rst: .false. -quilting: -print_esmf: diff --git a/ush/templates/wrtcmp_lambert_conformal b/ush/templates/wrtcmp_lambert_conformal deleted file mode 100644 index fd4e52eea..000000000 --- a/ush/templates/wrtcmp_lambert_conformal +++ /dev/null @@ -1,25 +0,0 @@ - -write_groups: -write_tasks_per_group: -num_files: 2 -filename_base: 'dyn''phy' -output_file: 'netcdf' -write_nemsioflip: .false. -write_fsyncflag: .false. - -output_grid: # Coordinate system used by output grid. -cen_lon: # Reference longitude, in degrees. -cen_lat: # Reference latitude, in degrees. -stdlat1: # Latitude of first standard parallel, in degrees. -stdlat2: # Latitude of second standard parallel, in degrees. -nx: # Number of grid cells along x-axis in Lambert conformal (x,y) plane. -ny: # Number of grid cells along y-axis in Lambert conformal (x,y) plane. -lon1: # Longitude of center of grid cell at bottom-left corner of grid, in degrees. -lat1: # Latitude of center of grid cell at bottom-left corner of grid, in degrees. -dx: # Grid cell size in x direction, in meters. -dy: # Grid cell size in y direction, in meters. - -nfhout: 1 # Output frequency in hours after forecast hour "nfhmax_hf" -nfhmax_hf: 60 # Number of forecast hours until output frequency "nfhout" takes affect -nfhout_hf: 1 # Output frequency in hours until forecast hour "nfhmax_hf" -nsout: -1 # Output frequency in time steps (positive values override "nfhout" and "nfhout_hf") diff --git a/ush/templates/wrtcmp_regional_latlon b/ush/templates/wrtcmp_regional_latlon deleted file mode 100644 index 1b1f2c0a9..000000000 --- a/ush/templates/wrtcmp_regional_latlon +++ /dev/null @@ -1,23 +0,0 @@ - -write_groups: -write_tasks_per_group: -num_files: 2 -filename_base: 'dyn''phy' -output_file: 'netcdf' -write_nemsioflip: .false. -write_fsyncflag: .false. - -output_grid: # Coordinate system of output grid. -cen_lon: # central longitude -cen_lat: # central latitude -lon1: # longitude of lower-left point in non-rotated coordinate system (in degrees) -lat1: # latitude of lower-left -lon2: # longitude of upper-right -lat2: # latitude of upper-right -dlon: -dlat: - -nfhout: 1 # Output frequency in hours after forecast hour "nfhmax_hf" -nfhmax_hf: 60 # Number of forecast hours until output frequency "nfhout" takes affect -nfhout_hf: 3 # Output frequency in hours until forecast hour "nfhmax_hf" -nsout: -1 # Output frequency in time steps (positive values override "nfhout" and "nfhout_hf") diff --git a/ush/templates/wrtcmp_rotated_latlon b/ush/templates/wrtcmp_rotated_latlon deleted file mode 100644 index a7f60e033..000000000 --- a/ush/templates/wrtcmp_rotated_latlon +++ /dev/null @@ -1,23 +0,0 @@ - -write_groups: -write_tasks_per_group: -num_files: 2 -filename_base: 'dyn''phy' -output_file: 'netcdf' -write_nemsioflip: .false. -write_fsyncflag: .false. - -output_grid: # Coordinate system of output grid. -cen_lon: # Longitude of center of grid, expressed in the NON-ROTATED latlon coordinate system (in degrees). This is also the longitude of the point at which the equator and prime meridian of the ROTATED coordinate system intersect (i.e. the point at which the longitude and latitude in the ROTATED latlon coordinate system are both 0). -cen_lat: # Latitude of center of grid, expressed in the NON-ROTATED latlon coordinate system (in degrees). This is also the latitude of the point at which the equator and prime meridian of the ROTATED coordinate system intersect (i.e. the point at which the longitude and latitude in the ROTATED latlon coordinate system are both 0). -lon1: # Longitude of lower-left grid point, expressed in the ROTATED latlon coordinate system (in degrees). -lat1: # Latitude of lower-left grid point, expressed in the ROTATED latlon coordinate system (in degrees). -lon2: # Longitude of upper-right grid point, expressed in the ROTATED latlon coordinate system (in degrees). -lat2: # Latitude of upper-right grid point, expressed in the ROTATED latlon coordinate system (in degrees). -dlon: -dlat: - -nfhout: 1 # Output frequency in hours after forecast hour "nfhmax_hf" -nfhmax_hf: 60 # Number of forecast hours until output frequency "nfhout" takes affect -nfhout_hf: 1 # Output frequency in hours until forecast hour "nfhmax_hf" -nsout: -1 # Output frequency in time steps (positive values override "nfhout" and "nfhout_hf") From 5d53c5c72979478d1581be40f7acf29f4a7baa0a Mon Sep 17 00:00:00 2001 From: gerard ketefian Date: Fri, 23 Oct 2020 16:04:49 -0500 Subject: [PATCH 39/39] Change the module files to use the contrib module for regional_workflow set up by Christina Holt. --- modulefiles/tasks/orion/make_grid.local | 12 +++++------- modulefiles/tasks/orion/make_ics.local | 12 +++++------- modulefiles/tasks/orion/make_lbcs.local | 12 +++++------- modulefiles/tasks/orion/run_fcst.local | 12 +++++------- 4 files changed, 20 insertions(+), 28 deletions(-) diff --git a/modulefiles/tasks/orion/make_grid.local b/modulefiles/tasks/orion/make_grid.local index 7b0776c62..e7b20cb66 100644 --- a/modulefiles/tasks/orion/make_grid.local +++ b/modulefiles/tasks/orion/make_grid.local @@ -1,7 +1,5 @@ - -#module use -a /contrib/miniconda3/modulefiles -#module load miniconda3 -#if [module-info mode load] { -# system "conda activate regional_workflow" -#} -module load python/3.7 +module use -a /apps/contrib/miniconda3-noaa-gsl/modulefiles +module load miniconda3 +if [module-info mode load] { + system "conda activate regional_workflow" +} diff --git a/modulefiles/tasks/orion/make_ics.local b/modulefiles/tasks/orion/make_ics.local index 7b0776c62..e7b20cb66 100644 --- a/modulefiles/tasks/orion/make_ics.local +++ b/modulefiles/tasks/orion/make_ics.local @@ -1,7 +1,5 @@ - -#module use -a /contrib/miniconda3/modulefiles -#module load miniconda3 -#if [module-info mode load] { -# system "conda activate regional_workflow" -#} -module load python/3.7 +module use -a /apps/contrib/miniconda3-noaa-gsl/modulefiles +module load miniconda3 +if [module-info mode load] { + system "conda activate regional_workflow" +} diff --git a/modulefiles/tasks/orion/make_lbcs.local b/modulefiles/tasks/orion/make_lbcs.local index 7b0776c62..e7b20cb66 100644 --- a/modulefiles/tasks/orion/make_lbcs.local +++ b/modulefiles/tasks/orion/make_lbcs.local @@ -1,7 +1,5 @@ - -#module use -a /contrib/miniconda3/modulefiles -#module load miniconda3 -#if [module-info mode load] { -# system "conda activate regional_workflow" -#} -module load python/3.7 +module use -a /apps/contrib/miniconda3-noaa-gsl/modulefiles +module load miniconda3 +if [module-info mode load] { + system "conda activate regional_workflow" +} diff --git a/modulefiles/tasks/orion/run_fcst.local b/modulefiles/tasks/orion/run_fcst.local index 2b539c8f0..e7b20cb66 100644 --- a/modulefiles/tasks/orion/run_fcst.local +++ b/modulefiles/tasks/orion/run_fcst.local @@ -1,7 +1,5 @@ - -#module use -a /contrib/miniconda3/modulefiles -#module load miniconda3 -#if [module-info mode load] { -# system "conda activate regional_workflow" -#} -#module load python/3.7 +module use -a /apps/contrib/miniconda3-noaa-gsl/modulefiles +module load miniconda3 +if [module-info mode load] { + system "conda activate regional_workflow" +}