Commit f18db8d3 authored by Carl Schreck's avatar Carl Schreck
Browse files

Automated Nightly Commit - Wed Aug 21 00:00:57 EDT 2019

parent 05ad5578
......@@ -129,7 +129,7 @@ begin ; main
print_clock( "Reading sst" )
inPath = "/home/carl/data/monitor/v2/sst/sst.anom.nc"
inFile = addfile( inPath, "r" )
todayTime = inFile->time@lastObsTime
todayTime = inFile->time@firstFcstTime+0.5
minTime = todayTime - 84
maxTime = todayTime + 28
......@@ -141,9 +141,9 @@ begin ; main
inPath = "/home/carl/data/monitor/v2/waves/" + varLevName + ".waves." \
+ algoName + ".nc"
inFile = addfile( inPath, "r" )
todayTime = inFile->time@lastObsTime
minTime = todayTime - 85
maxTime = todayTime + 29
; todayTime = inFile->time@lastObsTime
; minTime = todayTime - 85
; maxTime = todayTime + 29
low = dim_avg_n_Wrap( \
inFile->low({minTime:maxTime},{minLat:maxLat},:), 1 )
......@@ -253,7 +253,7 @@ begin ; main
lineRes@gsLineLabelString = "Begin Forecast"
line = gsn_add_polyline( wks, plot, (/ 0, 360 /), \
(/ todayTime+0.5, todayTime+0.5 /), lineRes )
(/ todayTime+1.0, todayTime+1.0 /), lineRes )
tcRes = True
......
......@@ -107,6 +107,7 @@ begin ; main
inFile = addfile( inPath, "r" )
time = inFile->time
lastObsInd = time@lastObsInd
firstFcstInd = time@firstFcstInd
totFile = addfile( totPath, "r" )
......@@ -126,8 +127,14 @@ begin ; main
plot = new( nPlots, graphic )
do p = 0, nPlots-1
minTimeInd = lastObsInd - ( -1 + nAvg * ( 1 - period(p) ) )
maxTimeInd = lastObsInd - ( 0 + nAvg * ( 0 - period(p) ) )
if(period(p).le.0) then
minTimeInd = lastObsInd - ( -1 + nAvg * ( 1 - period(p) ) )
maxTimeInd = lastObsInd - ( 0 + nAvg * ( 0 - period(p) ) )
else
minTimeInd = firstFcstInd - ( -1 + nAvg * ( 1 - period(p) ) )
maxTimeInd = firstFcstInd - ( 0 + nAvg * ( 0 - period(p) ) )
end if
totData = dim_avg_n_Wrap( \
totFile->sst(minTimeInd:maxTimeInd,:,:), 0 )
......@@ -140,8 +147,13 @@ begin ; main
end if
if( varName.eq."delta" ) then
prevMinTimeInd = lastObsInd - ( -1 + nAvg * ( 1 - period(p) +1) )
prevMaxTimeInd = lastObsInd - ( 0 + nAvg * ( 0 - period(p) +1 ) )
if(period(p).le.1) then
prevMinTimeInd = lastObsInd - ( -1 + nAvg * ( 1 - period(p) +1) )
prevMaxTimeInd = lastObsInd - ( 0 + nAvg * ( 0 - period(p) +1 ) )
else
prevMinTimeInd = firstFcstInd - ( -1 + nAvg * ( 1 - period(p) +1) )
prevMaxTimeInd = firstFcstInd - ( 0 + nAvg * ( 0 - period(p) +1 ) )
end if
prevData = dim_avg_n_Wrap( \
inFile->sst(prevMinTimeInd:prevMaxTimeInd,:,:), 0 )
data = data - prevData
......
......@@ -31,7 +31,7 @@ begin
varName = "sst"
end if
if( .not.isvar("varType") ) then
varType = "anom"
varType = "total"
end if
obsPath = "/home/carl/data/monitor/v2/sst/oisst.nc"
......@@ -59,6 +59,7 @@ begin
outTime@lastObsInd = nObs-1
outTime@lastObsTime = outTime(nObs-1)
; open the output file
system( "rm " + outPath )
outFile = addfile(outPath,"c")
......@@ -86,6 +87,10 @@ begin
cfsFile = addfile( cfsPath, "r" )
cfsData = cfsFile->$varName$(:,::-1,:)
outTime@firstFcstInd = ind(cfsData&time(0).eq.outTime)-1
outTime@firstFcstTime = outTime(outTime@firstFcstInd)
outData&time = outTime
if( varType.eq."total" ) then
cfsData = cfsData - 273.15
end if
......
......@@ -45,12 +45,16 @@ begin ; main
finalPath = cd_string( time, finalString )
prelimPath = cd_string( time, prelimString )
print_clock("Looking for finals")
finalPresent = isfilepresent( finalPath )
; prelimPresent = isfilepresent( prelimPath )
; print( cd_string(time,"") + " " + finalPresent + " " + prelimPresent )
; exit
inPath = where( finalPresent, finalPath, prelimPath )
bothPath = where( finalPresent, finalPath, prelimPath )
print_clock("Looking for both")
bothPresent = isfilepresent(bothPath)
inPath = bothPath(ind(bothPresent))
print_clock( "Opening" )
inFiles = addfiles(inPath, "r" )
......@@ -60,10 +64,11 @@ begin ; main
print_clock( "Reading anom" )
anom = short2flt( inFiles[:]->anom )
newTime = cd_convert(total&time, timeUnits)
delete(total&time)
delete(anom&time)
total&time = time
anom&time = time
total&time = newTime
anom&time = newTime
print_clock( "Writing" )
outPath = "~/data/monitor/v2/sst/oisst.nc"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment