source: anuga_work/production/hobart_2006/export_results.py @ 3721

Last change on this file since 3721 was 3721, checked in by sexton, 18 years ago

hobart testing and report making

File size: 2.0 KB
RevLine 
[3615]1import project, os
2import sys
3
[3650]4from anuga.shallow_water.data_manager import sww2dem
[3661]5from anuga.abstract_2d_finite_volumes.util import Screen_Catcher
[3615]6from os import sep
7
[3721]8time_dir = '20061006_062319' # Mw 8-5
[3680]9
[3615]10directory = project.outputdir
[3661]11name = directory + time_dir +sep + 'source'
[3615]12
[3661]13print 'output dir:', name
14which_var = 4
[3615]15if which_var == 0:  # Stage
16    outname = name + '_stage'
17    quantityname = 'stage'
18
19if which_var == 1:  # Absolute Momentum
20    outname = name + '_momentum'
21    quantityname = '(xmomentum**2 + ymomentum**2)**0.5'  #Absolute momentum
22
23if which_var == 2:  # Depth
[3721]24    outname = name + '_depth_bruny'
[3615]25    quantityname = 'stage-elevation'  #Depth
26
27if which_var == 3:  # Speed
28    outname = name + '_speed'
29    quantityname = '(xmomentum**2 + ymomentum**2)**0.5/(stage-elevation+1.e-30)'  #Speed
30
31if which_var == 4:  # Elevation
[3721]32    outname = name + '_elevation'
[3615]33    quantityname = 'elevation'  #Elevation
34
[3661]35print 'start sww2dem'
[3721]36# for hobart
37##sww2dem(name, basename_out = outname,
38##            quantity = quantityname,
39##            cellsize = 25,      # would prefer this at 25
40##            # define region for viz purposes
41##            easting_min = project.eastingmin25,
42##            easting_max = project.eastingmax25,
43##            northing_min = project.northingmin25,
44##            northing_max = project.northingmax25,       
45##            reduction = max, #this is because we want max quantityname
46##            verbose = True,
47##            format = 'asc')
48
49# for bruny
[3615]50sww2dem(name, basename_out = outname,
51            quantity = quantityname,
[3721]52            cellsize = 25,      # would prefer this at 25
[3615]53            # define region for viz purposes
[3721]54            easting_min = project.eastingmin25_2,
55            easting_max = project.eastingmax25_2,
56            northing_min = project.northingmin25_2,
57            northing_max = project.northingmax25_2,       
[3615]58            reduction = max, #this is because we want max quantityname
59            verbose = True,
60            format = 'asc')
Note: See TracBrowser for help on using the repository browser.