Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new jjob for ocean analysis bmat #1239

Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 87 additions & 0 deletions jobs/JGDAS_GLOBAL_OCEAN_ANALYSIS_BMAT
Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
#!/bin/bash
export STRICT="NO"
source "${HOMEgfs}/ush/preamble.sh"


##############################################
# make temp directory
##############################################
export DATA=${DATA:-${DATAROOT}/${RUN}ocnanal_${cyc}}
mkdir -p "${DATA}"
cd "${DATA}" || (echo "${DATA} does not exist. ABORT!"; exit 1)


##############################################
# Run setpdy and initialize PDY variables
##############################################
export cycle="t${cyc}z"
setpdy.sh
. ./PDY


##############################################
# Determine Job Output Name on System
##############################################
export pid=${pid:-$$}
export pgmout="OUTPUT.${pid}"
export pgmerr=errfile


#############################
# Source relevant config files
#############################
export EXPDIR=${EXPDIR:-${HOMEgfs}/parm/config}
configs="base ocnanal ocnanalrun"
for config in ${configs}; do
. "${EXPDIR}/config.${config}"
status=$?
[[ ${status} -ne 0 ]] && exit "${status}"
done


##########################################
# Source machine runtime environment
##########################################
. "${HOMEgfs}/env/${machine}.env" ocnanalrun
status=$?
[[ ${status} -ne 0 ]] && exit "${status}"
AndrewEichmann-NOAA marked this conversation as resolved.
Show resolved Hide resolved


##############################################
# Set variables used in the script
##############################################

export CDUMP=${CDUMP:-${RUN:-"gfs"}}
AndrewEichmann-NOAA marked this conversation as resolved.
Show resolved Hide resolved
export COMPONENT="ocean"
AndrewEichmann-NOAA marked this conversation as resolved.
Show resolved Hide resolved
AndrewEichmann-NOAA marked this conversation as resolved.
Show resolved Hide resolved

##############################################
# Begin JOB SPECIFIC work
##############################################

export COMOUT=${COMOUT:-${ROTDIR}/${CDUMP}.${PDY}/${cyc}/${COMPONENT}}
AndrewEichmann-NOAA marked this conversation as resolved.
Show resolved Hide resolved

###############################################################
# Run relevant script

EXSCRIPT=${GDASPREPPY:-${HOMEgfs}/sorc/gdas.cd/scripts/exgdas_global_marine_analysis_bmat.sh}
${EXSCRIPT}
status=$?
[[ ${status} -ne 0 ]] && exit "${status}"

##############################################
# End JOB SPECIFIC work
##############################################

##############################################
# Final processing
##############################################
if [[ -e "${pgmout}" ]] ; then
cat "${pgmout}"
fi

##########################################
# Do not remove the Temporary working directory (do this in POST)
##########################################
cd "${DATAROOT}" || exit 1

exit 0