-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun_pyMRMS.py
executable file
·73 lines (46 loc) · 1.92 KB
/
run_pyMRMS.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
from pyMRMS import retrieveMRMS,readFL,annotate,graph
projID = 'VSE'
tdrRng = 47966.79
plotMRMS = True
getMRMS = False
pltFT = True
plotAsts = False
plotRng = False
pltMultRng = False
plotStrmRpts = True
rprtWindow = -300
animAll = False
fltIntv = 60 # Plotting interval for flight track (seconds)
plotDom = False
domOrig = (34.0, -87.75)#(34.15, -87.3)
domX = 240
domY = 170
strtMRMS = '20170430-190000'
endMRMS = '20170430-192000'
mrmsSaveDir = '/Volumes/Pegasus/projData/vortexse17/MRMS/20170430/1800-2200Z'
mrmsPlotDir = '/Volumes/Pegasus/projData/vortexse17/MRMS/20170430/plots_StrmRpts'
flFile = '/Volumes/Pegasus/projData/vortexse17/flightLevel/20170430H1_AC.nc'
astsPrmsF = '/Volumes/Pegasus/projData/vortexse17/MRMS/20170430_assets_soundingLocs.yml'
strmRptsF = '/Volumes/Pegasus/projData/vortexse17/MRMS/20170430_stormReports.yml'
minLat = 33.1
minLon = -88.0
maxLat = 36.4
maxLon = -84.0
strtFL = strtMRMS
endFL = endMRMS
if getMRMS:
retrieveMRMS.fetch(strtMRMS,endMRMS,mrmsSaveDir)
if plotMRMS:
if pltFT:
print('Reading flight-level data...')
flData = readFL.getP3(flFile)#,endDT=endFL)
print('Extracting MRMS data...')
mData = retrieveMRMS.extract(mrmsSaveDir,strtDT=strtMRMS,endDT=endMRMS,llCrds=(minLat,minLon),urCrds=(maxLat,maxLon))
print('Plotting...')
graph.plotSHSR(mData['mLon'],mData['mLat'],mData['mSHSR'],mData['mDT'],radRange=tdrRng,
plotAsts=plotAsts,prmsFile=astsPrmsF,plotRng=plotRng,plotFltTrk=pltFT,multRings=pltMultRng,
flLon=flData['flLon'],flLat=flData['flLat'],flDT=flData['flDT'],
flHdng=flData['flHdng'],fltIntv=fltIntv,fadeFltTrk='fade',
projID=projID,plotDom=plotDom,domOrig=domOrig,domX=domX,domY=domY,
fType='png',saveDir=mrmsPlotDir,figsize=(19.5,15),animAll=animAll,
plotStrmRpts=plotStrmRpts,strmRptsF=strmRptsF,rprtWindow=rprtWindow)