Changeset 5386 for anuga_work/production/perth/build_perth.py
- Timestamp:
- May 30, 2008, 3:34:13 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_work/production/perth/build_perth.py
r5360 r5386 117 117 118 118 print'add all geospatial objects' 119 G = G1 + G2 + G3 + G4 + G5 + G6 + G_off + G_off1119 G = G1 + G2 + G3 + G4 + G5 + G6 + G_off 120 120 121 121 print'clip combined geospatial object by bounding polygon' 122 G_clipped = G.clip(project.bounding_polygon) 123 #FIXME: add a clip function to pts 124 #print'shape of clipped data', G_clipped.get_data_points().shape 122 G_clipped = G.clip(project.poly_all) 125 123 126 124 print'export combined DEM file' … … 128 126 mkdir (project.topographies_dir) 129 127 G_clipped.export_points_file(project.combined_dir_name + '.pts') 130 #G_clipped.export_points_file(project.combined_dir_name + '.xya') 131 132 ''' 133 print'project.combined_dir_name + 1.xya',project.combined_dir_name + '1.xya' 134 G_all=Geospatial_data(file_name = project.combined_dir_name + '1.xya') 135 print'split' 136 G_all_1, G_all_2 = G_all.split(.10) 137 print'export 1' 138 G_all_1.export_points_file(project.combined_dir_name+'_small1' + '.xya') 139 print'export 2' 140 G_all_2.export_points_file(project.combined_dir_name+'_other1' + '.xya') 141 128 #G_clipped.export_points_file(project.combined_dir_name + '.xya') - use for comparision in ARC 142 129 143 130 #------------------------------------------------------------------------- … … 145 132 #------------------------------------------------------------------------- 146 133 print 'starting to create boundary conditions' 134 from anuga.shallow_water.data_manager import urs2sww, urs_ungridded2sww 135 147 136 boundaries_in_dir_name = project.boundaries_in_dir_name 137 print 'boundaries_in_dir_name',project.boundaries_in_dir_name 148 138 149 from anuga.shallow_water.data_manager import urs2sww150 151 print 'minlat=project.north_boundary, maxlat=project.south_boundary',project.north_boundary, project.south_boundary152 print 'minlon= project.west_boundary, maxlon=project.east_boundary',project.west_boundary, project.east_boundary153 139 154 140 #import sys; sys.exit() 155 141 156 #if access(project.boundaries_dir,F_OK) == 0: 157 # mkdir (project.boundaries_dir) 158 159 from caching import cache 160 cache(urs2sww, 161 (boundaries_in_dir_name, 162 project.boundaries_dir_name1), 163 {'verbose': True, 164 'minlat': project.south_boundary, 165 'maxlat': project.north_boundary, 166 'minlon': project.west_boundary, 167 'maxlon': project.east_boundary, 168 # 'minlat': project.south, 169 # 'maxlat': project.north, 170 # 'minlon': project.west, 171 # 'maxlon': project.east, 172 'mint': 0, 'maxt': 40000, 173 # 'origin': domain.geo_reference.get_origin(), 174 'mean_stage': project.tide, 175 # 'zscale': 1, #Enhance tsunami 176 'fail_on_NaN': False}, 177 verbose = True, 178 ) 179 # dependencies = source_dir + project.boundary_basename + '.sww') 180 181 ''' 142 urs_ungridded2sww(project.boundaries_in_dir_name, project.boundaries_in_dir_name, 143 verbose=True, mint=4000, maxt=10000, zscale=1) 182 144 183 145 … … 187 149 188 150 151 152 153
Note: See TracChangeset
for help on using the changeset viewer.