Changeset 194 for trunk/MESOSCALE/PLOT/PYTHON
- Timestamp:
- Jul 4, 2011, 6:13:23 PM (14 years ago)
- Location:
- trunk/MESOSCALE/PLOT/PYTHON
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MESOSCALE/PLOT/PYTHON/mylib/api_g95.sh
r191 r194 9 9 \rm loge 10 10 f2py -c -m api ../../../LMD_MM_MARS/SRC/POSTPROC/api.F90 --fcompiler=g95 -L$NETCDF/lib -lnetcdf -lm -I$NETCDF/include --f90flags="-Wall -Wno=112,141,137,155 -fno-second-underscore -ffree-form" > logc 2> loge 11 f2py -c -m timestuff time.F --fcompiler=g95 -
trunk/MESOSCALE/PLOT/PYTHON/mylib/api_pgf90.sh
r191 r194 13 13 \rm loge 14 14 f2py -c -m api ../../../LMD_MM_MARS/SRC/POSTPROC/api.F90 --fcompiler=pg -L$NETCDF/lib -lnetcdf -lm -I$NETCDF/include --f90flags="-Mfree" > logc 2> loge 15 f2py -c -m timestuff time.F --fcompiler=pg -
trunk/MESOSCALE/PLOT/PYTHON/mylib/myplot.py
r191 r194 180 180 else: kcolor=color 181 181 if key: p = plt.quiverkey(q,posx,posy,scale,\ 182 str(int(scale)),coordinates='data',color=kcolor,labelpos='S' )182 str(int(scale)),coordinates='data',color=kcolor,labelpos='S',labelsep = 0.03) 183 183 return 184 184 -
trunk/MESOSCALE/PLOT/PYTHON/scripts/winds.py
r193 r194 26 26 from netCDF4 import Dataset 27 27 from myplot import getcoord2d,define_proj,makeplotpng,simplinterv,vectorfield,ptitle,latinterv,getproj,wrfinterv,dumpbdy 28 from mymath import deg 28 29 from matplotlib.pyplot import contourf, subplot, figure, rcParams, savefig, colorbar 29 30 from matplotlib.cm import get_cmap 31 from timestuff import sol2ls 30 32 import numpy as np 31 33 … … 73 75 else: [wlon,wlat] = simplinterv(lon2d,lat2d) 74 76 75 ################## 76 ### Get local time 77 if typefile in ['mesoapi','meso']: ltst = int(getattr(nc, 'GMT') + 0.5*(wlon[0]+wlon[1])/15.) 78 elif typefile in ['gcm']: ltst = 0 77 ######################### 78 ### Get local time and Ls 79 if typefile in ['mesoapi','meso']: 80 ltst = int(getattr(nc, 'GMT') + 0.5*(wlon[0]+wlon[1])/15.) 81 zetime = nc.variables['Times'][0] 82 zetimestart = getattr(nc, 'START_DATE') 83 zeday = int(zetime[8]+zetime[9]) - int(zetimestart[8]+zetimestart[9]) 84 if zeday < 0: lschar="" ## might have crossed a month... fix soon 85 else: lschar="_Ls"+str( int( sol2ls ( getattr( nc, 'JULDAY' ) + zeday ) ) ) 86 elif typefile in ['gcm']: 87 ltst = 0 88 lschar = "" 79 89 80 90 ############################################################################## … … 217 227 218 228 ### Next subplot 219 ptitle( basename + "_LT"+str((ltst+i)%24) )229 ptitle( basename + "_LT"+str((ltst+i)%24) + lschar ) 220 230 sub += 1 221 231
Note: See TracChangeset
for help on using the changeset viewer.