Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Rm debug statements.
  • Loading branch information
EdwardSafford-NOAA committed Jan 6, 2023
1 parent 918f346 commit 046ff04
Show file tree
Hide file tree
Showing 24 changed files with 255 additions and 372 deletions.
7 changes: 0 additions & 7 deletions src/Conventional_Monitor/data_extract/ush/ConMon_DE.sh
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,6 @@ jobname=ConMon_DE_${CONMON_SUFFIX}
echo "C_TANKDIR = ${C_TANKDIR}"
echo "C_LOGDIR = ${C_LOGDIR}"
echo "C_IMGNDIR = ${C_IMGNDIR}"
echo "MON_USH = $MON_USH"

if [[ ! -d ${C_TANKDIR} ]]; then
mkdir -p ${C_TANKDIR}
Expand Down Expand Up @@ -141,8 +140,6 @@ if [[ ${#cnvstat_location} -le 0 ]]; then
export cnvstat_location=${COMROOT}/gfs/${gfs_ver}
fi
export CNVSTAT_LOCATION=${cnvstat_location}
echo "CNVSTAT_LOCATION = $CNVSTAT_LOCATION"

export COMPONENT=${COMPONENT:-atmos}

export C_DATDIR=${C_DATDIR:-${CNVSTAT_LOCATION}/${RUN}.${PDY}/${CYC}/${COMPONENT}}
Expand Down Expand Up @@ -181,10 +178,6 @@ if [[ ! -s ${pgrbf06} ]]; then
export pgrbf06="${C_GDATDIR}/gdas.t${GCYC}z.pgrb2.1p00.f006"
fi

echo "cnvstat = $cnvstat"
echo "pgrbf00 = $pgrbf00"
echo "pgrbf06 = $pgrbf06"


#---------------------------------------------
# override the default convinfo definition
Expand Down
6 changes: 1 addition & 5 deletions src/Conventional_Monitor/image_gen/gscripts/defint.gs
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,8 @@ while(i <= 6)
endif
i=i+1
endwhile
say line

line
*say 'set ccols 49 47 45 44 43 42 99 22 23 24 25 27 29'
*'set ccols 49 47 45 44 43 42 99 22 23 24 25 27 29'
say 'set ccols 9 14 4 11 5 3 99 7 12 8 2 25 29'
'set ccols 9 14 4 11 5 3 99 7 12 8 2 27 6'
*exit 0
return
endfile
8 changes: 4 additions & 4 deletions src/Conventional_Monitor/image_gen/gscripts/plot_qsfc_horz.gs
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ dbug=0
setmap(plotfile,he)
'set gxout shaded'
'defint.gs 0.5 0'
'd 10*(RH2m.1-RH2m.2)/RHprs.1'
'd 10*(RHprs.1-RHprs.2)/RHprs.1'
'colorbar.gs'
'set ccolor 6'
'set digsiz 0.12'
Expand All @@ -63,7 +63,7 @@ setmap(plotfile,he)
setmap(plotfile,he)
'set gxout shaded'
'defint.gs 0.5 0'
'd 10*(RH2m.1-RH2m.2)/RHprs.1'
'd 10*(RHprs.1-RHprs.2)/RHprs.1'
'colorbar.gs'
'set ccolor 6'
'set digsiz 0.12'
Expand All @@ -77,7 +77,7 @@ setmap(plotfile,he)
setmap(plotfile,he)
'set gxout shaded'
'defint.gs 0.5 0'
'd 10*(RH2m.1-RH2m.2)/RHprs.1'
'd 10*(RHprs.1-RHprs.2)/RHprs.1'
'colorbar.gs'
'set ccolor 98'
'draw title Humidity INCT*10/Anal at 'rdate'z'
Expand All @@ -86,7 +86,7 @@ setmap(plotfile,he)
setmap(plotfile,he)
'set gxout shaded'
'defint 10 50'
'd RH2m.1'
'd RHprs.1'
'colorbar.gs'
'draw title Surface Humidity Analysis(RH,%) at 'rdate'z'
if(dbug=1)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,6 @@ function plot_horz(plotfile,plotfile2,xsize,ysize,he,rdate,levx,levx1,hint,var)
'set digsiz 0.12'
levy=levx-hint
ley1=levx+hint+1
say 'levy='levy
say 'ley1='ley1
'set lev 'levy
'set dfile 4'
'set lev 'levy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -135,8 +135,6 @@ function plot_horz(plotfile,plotfile2,xsize,ysize,he,rdate,levx,levx1,hint,var)
'set digsiz 0.12'
levy=levx-hint
ley1=levx+hint+1
say 'levy='levy
say 'ley1='ley1
'set lev 'levy
'set dfile 4'
'set lev 'levy
Expand Down
35 changes: 10 additions & 25 deletions src/Conventional_Monitor/image_gen/gscripts/plotstas_time_bias.gs
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ function time_bias (args)
'q time'
dmy=sublin(result,1)
ti=subwrd(dmy,5)
say ti
hh=substr(ti,1,2)
dd=substr(ti,4,2)

Expand All @@ -23,13 +22,10 @@ function time_bias (args)
ixc=subwrd(size,3)
iyc=subwrd(size,6)
izc=subwrd(size,9)
say ixc
say 'iyc=' iyc

'!echo $CONMON_RESTRICT_PLOT_AREAS > rest.txt'
rest=read(rest.txt)
restrict=subwrd(rest,2)
say 'restrict=' restrict

ix=1
while(ix <=ixc)
Expand All @@ -46,6 +42,16 @@ function time_bias (args)
endif
result=close(info.txt)

* Avoid plotting stypes "uv235" and "all". Stype all is included in the ctl file (from
* which the stypes are taken) but the web site has never included all stypes, so
* eliminating plotting them is a space/time savings. Stype 235 (uv only) produces
* missing data errors on half the plots -- the upper half. This will be
* investigated in a separate fix.
if ( stype = 235 | stype = all )
ix=ix+1
continue
endif

iy=1
while(iy <=iyc)

Expand All @@ -57,7 +63,6 @@ function time_bias (args)
endif
endif

say 'iy=' iy
'!rm -f area.txt'

if ( iy <10)
Expand All @@ -74,7 +79,6 @@ function time_bias (args)
area=substr(info,14,25)
endif
result=close(area.txt)
say 'area = 'area
iz=1

while(iz <=izc)
Expand Down Expand Up @@ -130,22 +134,17 @@ endfile

function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)

'page'
'clear'

nfield=4
field.1.1=bias1.1
field.1.2=bias1.2
field.1.3=bias1.3
field.2.1=rms1.1
field.2.2=rms1.2
field.2.3=rms1.3
field.3.1=bias3.1
field.3.2=bias3.2
field.3.3=bias3.3
field.4.1=rms3.1
field.4.2=rms3.2
field.4.3=rms3.3

title.1="o-g(used)"
title.2="rms(used)"
Expand All @@ -162,9 +161,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)
y1=10.6-(nf-1)*2.5
y2=y1-1.8
ystring=y1+0.1
say ' y1='y1
say ' y2='y2
say ' ystring='ystring
'set t 1 last'
'query time'
dmy=sublin(result,1)
Expand All @@ -188,14 +184,10 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)
if(maxvar1 > maxvar)
maxvar=maxvar1
endif
say ' 'minvar
say ' 'maxvar
yrange=maxvar-minvar
dy=0.1*yrange
minvar=minvar-dy
maxvar=maxvar+dy
say ' 'minvar
say ' 'maxvar
'set parea 1.0 8.0 'y2' 'y1
'set gxout line'
'set t 1 last'
Expand All @@ -205,8 +197,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)
'set y 'iy
'set x 'ix
'set z 'iz
* 'set axlim 'minvar' 'maxvar
* 'set yaxis 'minvar' 'maxvar' 'dy
'set vrange 'minvar' 'maxvar
'set ccolor 1'
'set cmark 0'
Expand All @@ -215,9 +205,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)
'set cmark 1'
'd 'field.nf.2
'set ccolor 3'
* 'set cmark 2'
* 'd 'field.nf.3
* if(iuse = 1);datause='assimilated';endif
if(iuse = -1)
datause='mon.'
else
Expand All @@ -231,8 +218,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,dtype,levz,debug)
'set line 2 1'
'draw line 3.1 0.6 3.4 0.6'
'draw string 3.5 0.55 final outloop'
* 'set line 3 1'
* 'draw line 5.1 0.6 5.4 0.6'
'draw string 5.5 0.55 'fti'-'ti
nf=nf+1
endwhile
Expand Down
36 changes: 10 additions & 26 deletions src/Conventional_Monitor/image_gen/gscripts/plotstas_time_bias2.gs
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,13 @@ function plot_bias2 (args)
dtype=DTYPE
'open ges_'dtype'_stas.ctl'
'open anl_'dtype'_stas.ctl'
* 'open 'dtype'_stas_int.ctl'
'set grads off'
debug=0

'set t 1 last'
'q time'
dmy=sublin(result,1)
ti=subwrd(dmy,5)
say ti
hh=substr(ti,1,2)
dd=substr(ti,4,2)

Expand All @@ -24,8 +22,6 @@ function plot_bias2 (args)
ixc=subwrd(size,3)
iyc=subwrd(size,6)
izc=subwrd(size,9)
say ixc
say 'iyc=' iyc

iz=1
while(iz <=izc)
Expand Down Expand Up @@ -63,7 +59,6 @@ function plot_bias2 (args)
'!echo $CONMON_RESTRICT_PLOT_AREAS > rest.txt'
rest=read(rest.txt)
restrict=subwrd(rest,2)
say 'restrict=' restrict

iy=1
while(iy <=iyc)
Expand All @@ -76,7 +71,6 @@ function plot_bias2 (args)
endif
endif

say 'iy=' iy
'!rm -f area.txt'
'!cat ges_'dtype'_stas.ctl |grep "region= 'iy' " > area.txt'
result=read(area.txt)
Expand All @@ -87,7 +81,6 @@ function plot_bias2 (args)
area=substr(info,14,25)
endif
result=close(area.txt)
say 'area = 'area
ix=1

while(ix <=ixc)
Expand All @@ -105,6 +98,16 @@ function plot_bias2 (args)
endif
result=close(info.txt)

* Avoid plotting syptes "uv235" and "all". Stype all is included in the ctl file (from
* which the stypes are taken) but the web site has never included stype all, so
* eliminating plotting them is a space/time savings. Stype 235 (uv only) produces
* missing data errors on half the plots -- the upper half. This will be
* investigated in a separate fix.
if ( stype = 235 | stype = all )
ix=ix+1
continue
endif

plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)

ix=ix+1
Expand All @@ -122,25 +125,20 @@ endfile

function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)

'page'
'clear'

nfield=4
field.1.1=bias2.1
field.1.2=bias2.2
field.1.3=bias2.3

field.2.1=rms2.1
field.2.2=rms2.2
field.2.3=rms2.3

field.3.1=bias3.1
field.3.2=bias3.2
field.3.3=bias3.3

field.4.1=rms3.1
field.4.2=rms3.2
field.4.3=rms3.3

title.1="o-g for rej. by GC "
title.2="rms for rej. by GC"
Expand All @@ -157,9 +155,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)
y1=10.6-(nf-1)*2.5
y2=y1-1.8
ystring=y1+0.1
say ' y1='y1
say ' y2='y2
say ' ystring='ystring
'set t 1 last'
'query time'
dmy=sublin(result,1)
Expand All @@ -186,14 +181,10 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)
maxvar=maxvar1
endif

say ' 'minvar
say ' 'maxvar
yrange=maxvar-minvar
dy=0.1*yrange
minvar=minvar-dy
maxvar=maxvar+dy
say ' 'minvar
say ' 'maxvar
'set parea 1.0 8.0 'y2' 'y1
'set gxout line'
'set t 1 last'
Expand All @@ -203,8 +194,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)
'set y 'iy
'set x 'ix
'set z 'iz
* 'set axlim 'minvar' 'maxvar
* 'set yaxis 'minvar' 'maxvar' 'dy
'set vrange 'minvar' 'maxvar
'set ccolor 1'
'set cmark 0'
Expand All @@ -213,9 +202,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)
'set cmark 1'
'd 'field.nf.2
'set ccolor 3'
* 'set cmark 2'
* 'd 'field.nf.3
* if(iuse = 1);datause='assimilated';endif
if(iuse = -1)
datause='mon.'
else
Expand All @@ -229,8 +215,6 @@ function plottime(ix,iy,iz,dtype,hh,dd,area,stype,subtype,iuse,levz,debug)
'set line 2 1'
'draw line 3.1 0.6 3.4 0.6'
'draw string 3.5 0.55 final outloop'
'set line 3 1'
* 'draw line 5.1 0.6 5.4 0.6'
'draw string 5.5 0.55 'fti'-'ti
nf=nf+1
endwhile
Expand Down
Loading

0 comments on commit 046ff04

Please sign in to comment.