Changeset 723 for trunk/UTIL
- Timestamp:
- Jul 16, 2012, 5:49:10 PM (12 years ago)
- Location:
- trunk/UTIL/PYTHON
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UTIL/PYTHON/README.INSTALL
r446 r723 1 ########################### 1 2 ############ README.INSTALL 3 ########################### 4 2 5 This README describes the required steps to install the python distribution and packages necessary to run the graphical routines. 3 6 … … 42 45 Step 4/- Read the README.PP ;) 43 46 ------------------------------ 47 48 NB: To use the movie capability, you will have to install mencoder. 49 NB: To use advance interpolation methods for GCM and mesoscale files, you will have to compile fortran routines with f2py (or compile those independently). 50 51 ########################### 52 ############ README.INSTALL.LMD 53 ########################### 54 55 If you work on LMD or IPSL computers, you don't necessarily need to install EPD. 56 57 [NB: You don't necessarily need to download pp.py sources either but in case 58 you would like to try modifications of the code please use the command 59 svn co http://svn.lmd.jussieu.fr/Planeto/trunk/UTIL/PYTHON 60 and change PYTHONPATH accordingly in the lines given in what follows] 61 62 ------------------------- 63 account on lmd.jussieu.fr 64 ------------------------- 65 66 A. Spiga installed on his account a version of EPD. 67 --> Add the following lines to your env_pers.ksh, then source the file. You're OK! 68 --> (ask for an installation of mencoder if you'd like to use movie capabilities) 69 70 ##################################### 71 if [ `uname` = 'Linux' ] ;then 72 if [ `uname -m` = 'x86_64' ] ;then 73 PATH="/donnees/aslmd/PY/epd-7.0-2-rh3-x86_64/bin/:$PATH" 74 else 75 PATH="/donnees/aslmd/PY/epd-7.0-2-rh5-x86/bin/:$PATH" 76 fi 77 fi 78 PYTHONPATH=/donnees/aslmd/MODELES/UTIL/PYTHON/ 79 export PYTHONPATH 80 PATH=$PYTHONPATH:$PATH 81 ##################################### 82 83 --------------------------------- 84 account on ciclad.ipsl.jussieu.fr 85 --------------------------------- 86 87 P. Weill installed on the system a version of EPD (and mencoder for movie capabilities) 88 --> Just add the following lines to your .bashrc, then source the file. You're OK! 89 90 ###################################### 91 PATH="/opt/epd-7.1-1/bin/:$PATH" 92 PYTHONPATH=/home/spiga/MODELES/UTIL/PYTHON/ 93 export PYTHONPATH 94 PATH=$PYTHONPATH:$PATH 95 ###################################### 96 97 ----------------------------------------------------------- 98 ----------------------------------------------------------- 99 ----------------------------------------------------------- 100 ----------------------------------------------------------- 101 Authors : A. Colaitis and A. Spiga 102 -
trunk/UTIL/PYTHON/README.PP
r518 r723 11 11 ************************************** 12 12 ************************************** 13 14 The program pp.py works on virtually any NETCDF file. 15 If not, please contact us, it is usually an easy fix to make it work. 13 16 14 17 ************************************ -
trunk/UTIL/PYTHON/mcd/mcd.py
r653 r723 247 247 for i in range(nd): self.xz = self.xcoord[i] ; self.update() ; self.put1d(i) 248 248 249 def seasonal(self,nd=12,start=0.,end=360.): 250 ### retrieve a seasonal slice 251 self.xlabel = "Areocentric longitude (degrees)" 252 self.prepare(ndx=nd) ; self.xcoord = np.linspace(start,end,nd) 253 for i in range(nd): self.xdate = self.xcoord[i] ; self.update() ; self.put1d(i) 254 249 255 def latlon(self,ndx=37,startx=-180.,endx=180.,ndy=19,starty=-90.,endy=90.): 250 256 ### retrieve a latitude/longitude slice … … 283 289 self.extvartab[i,j,1:100] = self.extvar[0:99] ## note: var numbering according to MCD manual is kept 284 290 285 def makemap2d(self,choice ):291 def makemap2d(self,choice,incwind=False): 286 292 ### one 2D map is created for the user-defined variable in choice. 293 self.latlon() ## a map is implicitely a lat-lon plot. otherwise it is a plot (cf. makeplot2d) 287 294 (field, fieldlab) = self.definefield(choice) 288 myplot.maplatlon(self.xcoord,self.ycoord,field,title=fieldlab,proj="moll") 289 290 def map2d(self,tabtodo): 295 if incwind: 296 (windx, fieldlabwx) = self.definefield("u") 297 (windy, fieldlabwy) = self.definefield("v") 298 myplot.maplatlon(self.xcoord,self.ycoord,field,title=fieldlab,proj="cyl",vecx=windx,vecy=windy) 299 else: 300 myplot.maplatlon(self.xcoord,self.ycoord,field,title=fieldlab,proj="moll") 301 302 def map2d(self,tabtodo,incwind=False): 291 303 ### complete 2D figure with possible multiplots 292 304 if isinstance(tabtodo,np.str): tabtodo=[tabtodo] ## so that asking one element without [] is possible. 293 305 if isinstance(tabtodo,np.int): tabtodo=[tabtodo] ## so that asking one element without [] is possible. 294 306 fig = mpl.figure() ; subv,subh = myplot.definesubplot( len(tabtodo) , fig ) 295 for i in range(len(tabtodo)): mpl.subplot(subv,subh,i+1) ; self.makemap2d(tabtodo[i] )307 for i in range(len(tabtodo)): mpl.subplot(subv,subh,i+1) ; self.makemap2d(tabtodo[i],incwind=incwind) 296 308 297 309 ### TODO: makeplot2d, plot2d, passer plot settings, vecteurs, plot loct pas fixe -
trunk/UTIL/PYTHON/mcd/proto/index.html
r639 r723 51 51 <li>Altitude 52 52 <input type="radio" name="isaltfree" value="0" checked> Value: <input type="text" size="2" name="altitude" value="10."> 53 <input type="radio" name="isaltfree" value="1"> All [0 ; 100000] km53 <input type="radio" name="isaltfree" value="1"> All [0 ; 100000] m 54 54 </li> 55 55 </ul>
Note: See TracChangeset
for help on using the changeset viewer.