Changeset 3616
- Timestamp:
- Sep 18, 2006, 5:37:19 PM (17 years ago)
- Files:
-
- 1 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/abstract_2d_finite_volumes/neighbour_mesh.py
r3560 r3616 726 726 str += 'Mesh statistics:\n' 727 727 str += ' Number of triangles = %d\n' %self.number_of_elements 728 str += ' Extent :\n'728 str += ' Extent [m]:\n' 729 729 str += ' x in [%f, %f]\n' %(min(x), max(x)) 730 730 str += ' y in [%f, %f]\n' %(min(y), max(y)) 731 str += ' Areas :\n'731 str += ' Areas [m^2]:\n' 732 732 str += ' A in [%f, %f]\n' %(min(areas), max(areas)) 733 733 str += ' number of distinct areas: %d\n' %(len(areas)) … … 764 764 765 765 766 str += ' Boundary:\n'767 str += ' Number of boundary segments == %d\n' %(len(self.boundary))768 str += ' Boundary tags == %s\n' %self.get_boundary_tags()766 str += ' Boundary:\n' 767 str += ' Number of boundary segments == %d\n' %(len(self.boundary)) 768 str += ' Boundary tags == %s\n' %self.get_boundary_tags() 769 769 str += '------------------------------------------------\n' 770 770 -
anuga_core/source/anuga/coordinate_transforms/redfearn.py
r3614 r3616 178 178 Output 179 179 180 zone: UTM zone for converted points181 180 points: List of converted points 181 zone: Common UTM zone for converted points 182 182 183 183 … … 205 205 206 206 207 return old_geo.get_zone(), utm_points207 return utm_points, old_geo.get_zone() 208 208 209 209 -
anuga_core/source/anuga/coordinate_transforms/test_redfearn.py
r3614 r3616 229 229 230 230 points = [[lat_gong, lon_gong], [lat_2, lon_2]] 231 zone, points= convert_points_from_latlon_to_utm(points)231 points, zone = convert_points_from_latlon_to_utm(points) 232 232 233 233 assert allclose(points[0][0], 308728.009) … … 255 255 256 256 try: 257 zone, points = convert_points_from_latlon_to_utm(points)257 points, zone = convert_points_from_latlon_to_utm(points) 258 258 except ANUGAError: 259 259 pass … … 277 277 278 278 try: 279 zone, points = convert_points_from_latlon_to_utm(points)279 points, zone = convert_points_from_latlon_to_utm(points) 280 280 except ANUGAError: 281 281 pass -
anuga_core/source/anuga/pmesh/mesh_interface.py
r3541 r3616 65 65 # check the segment indexes - throw an error if they are out of bounds 66 66 #(DSG) Yes! 67 67 68 68 69 #In addition I reckon the polygons could be of class Geospatial_data … … 73 74 #Note, Both poly's have the same geo_ref, therefore don't take into account 74 75 # geo_ref 76 77 # Simple check 78 bounding_polygon = ensure_numeric(bounding_polygon, Float) 79 msg = 'Bounding polygon must be a list of points or an Nx2 array' 80 assert len(bounding_polygon.shape) == 2, msg 81 assert bounding_polygon.shape[1] == 2, msg 82 83 84 # 75 85 if interior_regions is not None: 76 86 # Test that all the interior polygons are inside the bounding_poly … … 88 98 # Resolve geo referencing 89 99 if mesh_geo_reference is None: 90 bounding_polygon = ensure_numeric(bounding_polygon, Float)91 100 xllcorner = min(bounding_polygon[:,0]) 92 101 yllcorner = min(bounding_polygon[:,1])
Note: See TracChangeset
for help on using the changeset viewer.