Changeset 4184
- Timestamp:
- Jan 19, 2007, 4:26:57 PM (18 years ago)
- Location:
- anuga_core/source/anuga
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/source/anuga/coordinate_transforms/test_geo_reference.py
r3134 r4184 8 8 from geo_reference import * 9 9 from Numeric import allclose,array 10 11 # Ignore these warnings, since we still want to test .xya code. 12 import warnings 13 warnings.filterwarnings(action = 'ignore', 14 message='.xya format is deprecated. Please use .txt.', 15 category=DeprecationWarning) 16 17 warnings.filterwarnings(action = 'ignore', 18 message='Text file format is moving to comma se', 19 category=DeprecationWarning) 20 10 21 11 22 class geo_referenceTestCase(unittest.TestCase): -
anuga_core/source/anuga/fit_interpolate/fit.py
r4175 r4184 261 261 # self.mesh.get_boundary_polygon() 262 262 263 # Why are these global? 264 self.inside_poly_indices, self.outside_poly_indices = \ 263 inside_poly_indices, outside_poly_indices = \ 265 264 in_and_outside_polygon(point_coordinates, 266 265 self.mesh.get_boundary_polygon(), … … 270 269 271 270 272 n = len( self.inside_poly_indices)271 n = len(inside_poly_indices) 273 272 if verbose: print 'Building fitting matrix from %d points' %n 274 273 #Compute matrix elements for points inside the mesh 275 for k, i in enumerate( self.inside_poly_indices):274 for k, i in enumerate(inside_poly_indices): 276 275 #For each data_coordinate point 277 276 if verbose and k%((n+10)/10)==0: print 'Doing %d of %d' %(k, n) -
anuga_core/source/anuga/fit_interpolate/test_fit.py
r4175 r4184 254 254 255 255 256 fileName = tempfile.mktemp(". xya")256 fileName = tempfile.mktemp(".txt") 257 257 file = open(fileName,"w") 258 file.write(" elevation \n\258 file.write(" x, y, elevation \n\ 259 259 -2.0, 2.0, 0.\n\ 260 260 -1.0, 1.0, 0.\n\ … … 270 270 3.0, 1.0 , 4.\n") 271 271 file.close() 272 272 print "fileName",fileName 273 273 geo = Geospatial_data(fileName) 274 274 fileName_pts = tempfile.mktemp(".pts")
Note: See TracChangeset
for help on using the changeset viewer.