Skip to content

Commit

Permalink
Merge pull request #128 from RobertoPadilla-NOAA/feature/gfsv16_wave_…
Browse files Browse the repository at this point in the history
…prdgen

Feature/gfsv16 wave prdgen
  • Loading branch information
KateFriedman-NOAA committed Sep 11, 2020
2 parents c554657 + 9d9b79c commit 46c2404
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 32 deletions.
2 changes: 1 addition & 1 deletion gempak/fix/g2varswmo2.tbl
Original file line number Diff line number Diff line change
Expand Up @@ -428,7 +428,7 @@
010 001 002 000 u-component of current m s-1 URELC 0 -9999.00
010 001 003 000 v-component of current m s-1 VRELC 0 -9999.00
!
010 002 000 000 Ice cover Proportion ICE 0 -9999.00
010 002 000 000 Ice cover Proportion ICEC 0 -9999.00
010 002 001 000 Ice thickness m ICET 0 -9999.00
010 002 002 000 Direction of ice drift Degree true DRCTI 0 -9999.00
010 002 003 000 Speed of ice drift m s-1 SPEDI 0 -9999.00
Expand Down
59 changes: 28 additions & 31 deletions scripts/exgfs_wave_nawips.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ if [ ! -d $DATA ];then
fi

cd $DATA
cp $GEMwave/fix/g2varswmo2.tbl .

cpyfil=gds
garea=dset
Expand Down Expand Up @@ -59,20 +60,37 @@ while [ $fhcnt -le $FHMAX_WAV ]; do
grdIDout='gfswavewc10m' ;;
glo_30m) grdIDin='global.0p25'
grdIDout='gfswavegl30m' ;;
# ao_9km) grdIDin='arctic.9km'
# grdIDout='gfswavea9k' ;;
glo_10m) grdIDin='global.0p25'
grdIDout='gfswaveg16k' ;;
gso_15m) grdIDin='gsouth.0p25'
grdIDout='gfswaves25k' ;;
*) gridIDin=
grdIDout= ;;
esac
GRIBIN=$COMIN/gridded/$RUNwave.$cycle.$grdIDin.f${fhr}.grib2
GRIBIN_chk=$GRIBIN.idx
if [ "$grdIDin" = "global.0p25" ] && [ "$grid" = "glo_30m" ]; then
#cp $GRIBIN tempgf.$grdID.f${fhr}
#cp $GRIBIN tempgf.$grdIDin.f${fhr}

icnt=1
while [ $icnt -lt 1000 ]; do
if [ -r $GRIBIN_chk ] ; then
break
else
let "icnt=icnt+1"
sleep 20
fi
if [ $icnt -ge $maxtries ]; then
msg="ABORTING after 5 minutes of waiting for $GRIBIN."
postmsg "$jlogfile" "$msg"
echo ' '
echo '**************************** '
echo '*** ERROR : NO GRIB FILE *** '
echo '**************************** '
echo ' '
echo $msg
[[ "$LOUD" = YES ]] && set -x
echo "$RUNwave $grdID ${fhr} prdgen $date $cycle : GRIB file missing." >> $wavelog
err=1;export err;${errchk} || exit ${err}
fi
done

#if [ "$grdIDin" = "global.0p25" && "$grid" = "glo_30m" ]; then
if [ "$grdIDin" = "global.0p25" ]; then
$WGRIB2 -lola 0:720:0.5 -90:361:0.5 gribfile.$grdIDout.f${fhr} grib \
$GRIBIN 1> out 2>&1
OK=$?
Expand All @@ -97,28 +115,7 @@ while [ $fhcnt -le $FHMAX_WAV ]; do
echo $GRIBIN

GEMGRD=${grdIDout}_${PDY}${cyc}f${fhr}
icnt=1
while [ $icnt -lt 1000 ]; do
if [ -r $GRIBIN_chk ] ; then
break
else
let "icnt=icnt+1"
sleep 20
fi
if [ $icnt -ge $maxtries ]; then
msg="ABORTING after 5 minutes of waiting for $GRIBIN."
postmsg "$jlogfile" "$msg"
echo ' '
echo '**************************** '
echo '*** ERROR : NO GRIB FILE *** '
echo '**************************** '
echo ' '
echo $msg
[[ "$LOUD" = YES ]] && set -x
echo "$RUNwave $grdID ${fhr} prdgen $date $cycle : GRIB file missing." >> $wavelog
err=1;export err;${errchk} || exit ${err}
fi
done

cp $GRIBIN grib_$grid

startmsg
Expand Down

0 comments on commit 46c2404

Please sign in to comment.