Changeset 5458


Ignore:
Timestamp:
Jul 2, 2008, 11:51:19 AM (14 years ago)
Author:
jakeman
Message:

updates of scripts used for boxingday validation to include boundary ordering

Location:
anuga_work/development/boxingday08
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • anuga_work/development/boxingday08/project.py

    r5419 r5458  
    7777#read in polyline boundary
    7878from anuga.shallow_water.data_manager import urs2sts,create_sts_boundary
    79 base_name='polyline'
     79urs_name='polyline'
     80#base_name=urs_name
     81tide=0.35
     82base_name='tide_polyline'
     83#base_name='most_polyline'
    8084import os
    8185if os.path.exists(base_name+'.sts'):
    82         print 'sts boundary file already created.'
     86    print 'sts boundary file already created.'
    8387else:
    84         urs2sts(base_name,mean_stage=0.0,verbose=False)
     88    print 'creatin sts file'
     89    urs2sts(urs_name,base_name,mean_stage=tide,verbose=False)
    8590
    8691order_filename='sts_order.txt'
     
    118123mesh_elevname = 'phuket_mesh_elev'
    119124boundary_most_in = dir+sep+'out'
    120 boundary_most_out = dir+sep+'most_boundary_condition'
     125#boundary_most_out = dir+sep+'most_boundary_condition'
     126boundary_most_out = dir+sep+'tide_most_boundary_condition'
    121127
    122128dir='mesh_polygons'
     
    140146    from pylab import plot,show,hold
    141147    bounding_polygon=ensure_numeric(bounding_polygon)#for plotting only
     148    #boundary=ensure_numeric(boundary)
     149    #plot(boundary[:,0],boundary[:,1],'o')
    142150    plot(bounding_polygon[:,0],bounding_polygon[:,1],'o')
    143151    plot(bounding_polygon[:,0],bounding_polygon[:,1])
  • anuga_work/development/boxingday08/run_boxingday_most.py

    r5442 r5458  
    143143#------------------------------------------------------------------------------
    144144     
    145 tide = 0.0
     145tide = 0.35
    146146domain.set_quantity('stage', tide)
    147147domain.set_quantity('friction', 0.01)
     
    187187           'origin': domain.geo_reference.get_origin(),
    188188           'mean_stage': tide,
    189            'zscale': 1,                 #Enhance tsunami
     189           'zscale': 1.0,                 #Enhance tsunami
    190190           'fail_on_NaN': False,
    191191           'inverted_bathymetry': True},
     
    195195
    196196print 'Available boundary tags', domain.get_boundary_tags()
    197 #Bf = File_boundary(project.boundary_most_out+'.sww',
    198 #                    domain, time_thinning=1, use_cache=True,verbose = True)
     197Bf = File_boundary(project.boundary_most_out+'.sww',
     198                    domain, time_thinning=1, use_cache=True,verbose = True)
    199199Br = Reflective_boundary(domain)
    200200Bd = Dirichlet_boundary([tide,0.0,0.0])
    201201
    202 domain.set_boundary({'ocean': Bd,
     202domain.set_boundary({'ocean': Bf,
    203203                     'otherocean': Bd,
    204204                     'land': Br,
  • anuga_work/development/boxingday08/run_boxingday_polyline.py

    r5442 r5458  
    4646#------------------------------------------------------------------------------
    4747
    48 #scenario = 'poor_simulation'
    49 scenario = 'good_simulation'
     48scenario = 'poor_simulation'
     49#scenario = 'good_simulation'
    5050
    5151if os.access(scenario, os.F_OK) == 0:
     
    9292
    9393from Numeric import arange,allclose
     94#This needs to be done by the user. Not easy at the moment
    9495boundary_tags={'ocean': arange(0,41).tolist(), 'otherocean': [41,44], 'land': [42,43]}
    9596
     
    145146#------------------------------------------------------------------------------
    146147     
    147 tide = 0.0
     148tide = 0.35
    148149domain.set_quantity('stage', tide)
    149150domain.set_quantity('friction', 0.01)
     
    165166# Setup boundary conditions
    166167#------------------------------------------------------------------------------
    167 boundary_urs_in='data/boxing'
    168168boundary_urs_out=project.base_name
    169169
Note: See TracChangeset for help on using the changeset viewer.