Changeset 1186 for trunk/UTIL/PYTHON
- Timestamp:
- Feb 18, 2014, 1:05:14 PM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/UTIL/PYTHON/api/exapi.py
r1008 r1186 4 4 from optparse import OptionParser ### TBR by argparse 5 5 import numpy as np 6 import sys 6 7 # ----------------------------------------------------------------------- 7 8 # A simple script to call the API program to interpolate mesoscale files … … 100 101 print "EXAPI: OK. done with this file." 101 102 102 103 103 #################################### 104 # save a .sh file with the command # 105 #################################### 106 command = "" 107 if opt.output is None: 108 opt.output = "exapi" 109 for arg in sys.argv: command = command + arg + ' ' 110 try: 111 f = open(opt.output+'.sh','w') 112 f.write(command) 113 except IOError: 114 print "!! WARNING !! pp.py command not saved. Probably do not have permission to write here."
Note: See TracChangeset
for help on using the changeset viewer.