Changeset 7346
- Timestamp:
- Aug 9, 2009, 5:34:33 PM (14 years ago)
- Location:
- anuga_core
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_core/documentation/user_manual/demos/channel_variable.py
r7345 r7346 23 23 len1=length, len2=width) 24 24 domain = Domain(points, vertices, boundary) 25 domain.set_name('channel 3') # Output name25 domain.set_name('channel_variable') # Output name 26 26 print domain.statistics() 27 domain.set_quantities_to_be_stored({'elevation': 1, #2, 28 'stage': 2}) 27 29 28 30 #------------------------------------------------------------------------------ -
anuga_core/source/anuga/shallow_water/data_manager.py
r7342 r7346 6003 6003 outfile.variables[q+Write_sww.RANGE][1] = -max_float # Max 6004 6004 6005 # FIXME: Backwards compat - get rid of z once old view has retired 6006 outfile.createVariable('z', sww_precision, 6007 ('number_of_points',)) 6005 if 'elevation' in self.static_quantities: 6006 # FIXME: Backwards compat - get rid of z once old view has retired 6007 outfile.createVariable('z', sww_precision, 6008 ('number_of_points',)) 6008 6009 6009 6010 for q in self.dynamic_quantities: … … 6167 6168 # This populates the _range values 6168 6169 outfile.variables[q + Write_sww.RANGE][0] = num.min(x) 6169 outfile.variables[q + Write_sww.RANGE][1] = num.max(x) 6170 outfile.variables[q + Write_sww.RANGE][1] = num.max(x) 6170 6171 6171 outfile.variables['z'][:] = outfile.variables['elevation'][:] #FIXME HACK 6172 # FIXME: Hack for backwards compatibility with old viewer 6173 if 'elevation' in self.static_quantities: 6174 outfile.variables['z'][:] = outfile.variables['elevation'][:] 6172 6175 6173 6176
Note: See TracChangeset
for help on using the changeset viewer.