- Timestamp:
- Jul 4, 2007, 5:22:18 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_work/production/pt_hedland_2006/run_pt_hedland_urs.py
r4544 r4587 38 38 from anuga.caching import myhash 39 39 from anuga.damage_modelling.inundation_damage import add_depth_and_momentum2csv, inundation_damage 40 from anuga.fit_interpolate.benchmark_least_squares import mem_usage 40 41 # Application specific imports 41 42 import project_urs # Definition of file names and polygons … … 53 54 54 55 kwargs['output_dir']=project_urs.output_run_time_dir 55 kwargs['bathy_file']=project_urs.combined_dir_name + '. txt'56 kwargs['bathy_file']=project_urs.combined_dir_name + '.pts' 56 57 kwargs['boundary_file']=project_urs.boundaries_in_dir_name + '.sww' 57 58 … … 61 62 #------------------------------------------------------------------------------ 62 63 63 start_screen_catcher(kwargs['output_dir'], myid, numprocs)64 65 64 print 'output_dir',kwargs['output_dir'] 66 65 if myid == 0: … … 71 70 72 71 barrier() 72 73 start_screen_catcher(kwargs['output_dir'], myid, numprocs) 74 73 75 74 76 print "Processor Name:",get_processor_name() … … 124 126 from polygon import Polygon_function 125 127 #following sets the stage/water to be offcoast only 126 IC = Polygon_function( [(project_urs.poly_mainland, -1.0)], default = kwargs['tide'], 127 geo_reference = domain.geo_reference) 128 domain.set_quantity('stage', IC) 128 #IC = Polygon_function( [(project_urs.poly_mainland, -50.0)], default = kwargs['tide'], 129 # geo_reference = domain.geo_reference) 130 #domain.set_quantity('stage', IC) 131 domain.set_quantity('stage', kwargs['tide']) 129 132 domain.set_quantity('friction', kwargs['friction']) 130 133 131 print 'Start Set quantity' 132 134 print 'Start Set quantity', kwargs['bathy_file'],kwargs['alpha'] 135 133 136 domain.set_quantity('elevation', 134 137 filename = kwargs['bathy_file'], … … 217 220 if myid == 0: 218 221 store_parameters(**kwargs) 219 220 swwfile = kwargs['output_dir']+kwargs['aa_scenario_name'] 221 export_grid(swwfile, extra_name_out = 'town', 222 quantities = ['elevation','depth','stage','speed'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation 223 timestep = None, 224 reduction = max, 225 cellsize = 25, 226 NODATA_value = -9999, 227 easting_min = project_urs.eastingmin, 228 easting_max = project_urs.eastingmax, 229 northing_min = project_urs.northingmin, 230 northing_max = project_urs.northingmax, 231 verbose = True, 232 origin = None, 233 datum = 'WGS84', 234 format = 'asc') 235 236 buildings_filename = project_urs.buildings_filename 237 buildings_filename_out = project_urs.buildings_filename_out 238 239 inundation_damage(swwfile+'.sww', buildings_filename, buildings_filename_out) 240 print '\n Augmented building file written to %s \n' %buildings_filename_out 222 223 print 'memory usage before del domain',mem_usage() 224 del domain 225 print 'memory usage after del domain',mem_usage() 226 227 swwfile = kwargs['output_dir']+kwargs['aa_scenario_name'] 228 print'swwfile',swwfile 229 230 export_grid(swwfile, extra_name_out = 'town', 231 quantities = ['speed','depth','stage','elevation'], # '(xmomentum**2 + ymomentum**2)**0.5' defaults to elevation 232 timestep = None, 233 reduction = max, 234 cellsize = 25, 235 NODATA_value = -9999, 236 easting_min = project_urs.eastingmin, 237 easting_max = project_urs.eastingmax, 238 northing_min = project_urs.northingmin, 239 northing_max = project_urs.northingmax, 240 verbose = True, 241 origin = None, 242 datum = 'WGS84', 243 format = 'asc') 244 245 buildings_filename = project_urs.buildings_filename 246 buildings_filename_out = project_urs.buildings_filename_out 247 248 inundation_damage(swwfile+'.sww', buildings_filename, buildings_filename_out) 249 print '\n Augmented building file written to %s \n' %buildings_filename_out 241 250 242 251 barrier()
Note: See TracChangeset
for help on using the changeset viewer.