Changeset 2505
- Timestamp:
- Mar 9, 2006, 11:27:05 AM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
inundation/pyvolution/data_manager.py
r2500 r2505 1197 1197 1198 1198 dem_elevation_r = reshape(dem_elevation, (nrows, ncols)) 1199 totalnopoints = nrows*ncols 1199 1200 1200 1201 # calculating number of NODATA_values for each row 1201 1202 nn = 0 1202 1203 no_counts = [] 1204 print 'I think NODATA_values is: ', NODATA_value 1203 1205 for i in range(nrows): 1204 1206 v = [dem_elevation_r[i,:]] … … 1207 1209 no_counts.append(this_count) 1208 1210 1209 if verbose and nn > 0: print 'There are %d NODATA_values in the elevation' %nn 1211 if verbose and nn > 0: 1212 print 'There are %d values in the elevation', %totalnopoints 1213 print 'There are %d NODATA_values in the elevation' %nn 1210 1214 1211 1215 # dimension definitions … … 1214 1218 1215 1219 nopoints = nrows_in_bounding_box*ncols_in_bounding_box-nn 1220 #nopoints = nrows_in_bounding_box*ncols_in_bounding_box 1216 1221 outfile.createDimension('number_of_points', nopoints) 1217 1222 outfile.createDimension('number_of_dimensions', 2) #This is 2d data … … 1239 1244 else: 1240 1245 newcols = ncols_in_bounding_box 1241 1246 1242 1247 telev = zeros(newcols, Float) 1243 1248 tpoints = zeros((newcols, 2), Float)
Note: See TracChangeset
for help on using the changeset viewer.