Skip to content

Commit

Permalink
Add NewCOM functions for fcst and atmos_prdgen jobs
Browse files Browse the repository at this point in the history
 On branch feature/gefs_v13_atmos_prep
 Changes to be committed:
	modified:   jobs/JGEFS_ATMOS_PRDGEN
	modified:   rocoto/bin/wcoss2/common.sh
	modified:   scripts/exgefs_forecast.sh

Refs: NOAA-EMC#94 & NOAA-EMC#95
  • Loading branch information
XianwuXue-NOAA committed Jan 25, 2023
1 parent 2f1dd7e commit de78d0f
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 5 deletions.
9 changes: 7 additions & 2 deletions jobs/JGEFS_ATMOS_PRDGEN
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,13 @@ export PARMgefs=${PARMgefs:-$HOMEgefs/parm}
##############################################
ver=${ver:-$(echo ${gefs_ver}|cut -c1-5)}
export mem=$(echo $RUNMEM|cut -c3-5)
export COMIN=${COMIN:-$(compath.py $envir/com/$NET/${ver})/${RUN}.${PDY}/$cyc}/${mem}
export COMOUT=${COMOUT:-$(compath.py -o $NET/${ver})/${RUN}.${PDY}/$cyc}/${mem}
export COMIN=${COMIN:-$(compath.py $envir/com/$NET/${ver})/${RUN}.${PDY}/$cyc}
export COMOUT=${COMOUT:-$(compath.py -o $NET/${ver})/${RUN}.${PDY}/$cyc}
if [[ ${NewCOM:-"YES"} == "YES" ]]; then
export mem=$(echo $RUNMEM|cut -c3-5)
export COMIN=${COMIN}/${mem}
export COMOUT=${COMOUT}/${mem}
fi

#############################
# Source relevant config files
Expand Down
2 changes: 1 addition & 1 deletion rocoto/bin/wcoss2/common.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/ksh -l
#!/usr/bin/env bash

RocotoGen=${RocotoGen:-0}

Expand Down
12 changes: 10 additions & 2 deletions scripts/exgefs_forecast.sh
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,11 @@ if [[ $err != 0 ]]; then
fi

if [[ $SENDCOM == "YES" && $WRITE_DOPOST == ".true." ]]; then
mkdir -m 775 -p ${memdir}/misc/post
if [[ ${NewCOM} == "YES" ]]; then
mkdir -m 775 -p ${memdir}/misc/post
else
mkdir -m 775 -p ${memdir}/../misc/post
fi

# Convert output settings into an explicit list
OUTPUT_FH=""
Expand All @@ -339,7 +343,11 @@ if [[ $SENDCOM == "YES" && $WRITE_DOPOST == ".true." ]]; then

mafile=${memdir}/${CDUMP}.$cycle.master.grb2f${FH3}
mifile=${memdir}/${CDUMP}.$cycle.master.grb2if${FH3}
mcfile=${memdir}/misc/post/${CDUMP}.$cycle.master.control.f${FH3}
if [[ ${NewCOM} == "YES" ]]; then
mcfile=${memdir}/misc/post/${CDUMP}.$cycle.master.control.f${FH3}
else
mcfile=${memdir}/../misc/post/${CDUMP}.$cycle.master.control.f${FH3}
fi

if [[ ! -s $mcfile ]]; then
if [[ -s $mafile ]]; then
Expand Down

0 comments on commit de78d0f

Please sign in to comment.