#!/bin/bash #BSUB -J pcp_urma #BSUB -P RTMA-T2O #BSUB -o /gpfs/dell2/ptmp/Ying.Lin/cron.out/urma.%J #BSUB -e /gpfs/dell2/ptmp/Ying.Lin/cron.out/urma.%J #BSUB -W 0:45 #BSUB -n 1 #BSUB -q "dev_shared" #BSUB -R "rusage[mem=1500]" #BSUB -R affinity[core(1)] #BSUB -R span[ptile=1] set -x module purge module load EnvVars/1.0.2 module load lsf/10.1 module load ips/18.0.1.163 module load impi/18.0.1 module load CFP/2.0.1 module load prod_util/1.1.3 module load prod_envir/1.0.3 module load grib_util/1.1.0 export urma_ver=v2.8.0 export RUN_ENVIR=dev # or nco export envir=dev # or prod/para/test # EXPORT list here # CALL executable job script here # This script has two optional arguments: # arg 1: yyyymmddhh # arg 2: debug (if in debug mode, do not delete the working directory) # arg 3: Single mode - only make erly/mid/late run (one of them, as # specified by argument. No POE. # arg #1: pdyhh=yyyymmddhh # 2019/11: note about the run cycle: since we're running PCPANL at hh:55, the # pcpURMA run might not start until after the top of the next hour. So check # the current minute: if it's less than 55, then the run cycle is for the # previous hour. # export retro=N if [ $# -ge 1 ]; then export retro=Y export pdyhh=$1 else minute=`date +%M` if [ $minute -lt 50 ]; then pdyhh=`date +%Y%m%d%H -d "1 hour ago"` else pdyhh=`date +%Y%m%d%H` fi fi # retro test # export pdyhh=2019062416 # retro test export cyc=`echo $pdyhh | cut -c 9-10` # arg #2: optional debug mode - the working directory is not deleted by the # JOBS script export KEEPDATA=YES if [ $# -ge 2 ]; then arg2=$2 if [ $arg2 = debug ]; then export KEEPDATA=YES fi fi if [ "$envir" = dev ]; then export USERHOME=/gpfs/dell2/emc/verification/noscrub/Ying.Lin export HOMEurma=$USERHOME/pcpanl/urma.${urma_ver} export NOSCRUBDIR=$USERHOME/mrms-cmorph.arch # begin dev for python: module use -a /u/Benjamin.Blake/modulefiles module load anaconda2/latest export GRIB_DEFINITION_PATH=/gpfs/dell2/emc/modeling/noscrub/Benjamin.Blake/EXT/grib_api.1.14.4/share/grib_api/definitions export PYTHONPATH=${PYTHONPATH}:/gpfs/dell2/emc/modeling/noscrub/Jacob.Carley/python/lib # end dev for python. # outid is what prod uses to name the job output file, e.g. # nam_pcpn_anal_2033.o2467312 (outid.$o${pid} # below is my approximation to prod outid: # $HOMEurma/jobs/JURMA_PCPN bsub < $HOMEurma/util.dev/send2rzdm.sh else /nw${envir}/jobs/JURMA_PCPN fi