Changeset 6300


Ignore:
Timestamp:
Feb 10, 2009, 8:45:18 AM (15 years ago)
Author:
myall
Message:
 
Location:
anuga_work/production/australia_ph2/eucla_motel
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • anuga_work/production/australia_ph2/eucla_motel/build_boundary_27255.py

    r6294 r6300  
    55Input: order_filename from project.py
    66       event_number needs to be reflected in the project file
    7 Output: creates a sts file and csv files stored in project.boundaries_dir_event.
     7Output: creates a sts file and csv files stored in project.event_folder.
    88The run_busselton.py is reliant on the output of this script.
    99"""
     
    9595
    9696    maxname = 'max_sts_stage.csv'
    97     fid_max = open(project.boundaries_dir_event+sep+maxname,'w')
     97    fid_max = open(project.event_folder+sep+maxname,'w')
    9898    s = 'index, x, y, max_stage \n'
    9999    fid_max.write(s)   
     
    112112
    113113    minname = 'min_sts_stage.csv'
    114     fid_min = open(project.boundaries_dir_event+sep+minname,'w')
     114    fid_min = open(project.event_folder+sep+minname,'w')
    115115    s = 'index, x, y, max_stage \n'
    116116    fid_min.write(s)   
     
    126126
    127127
    128         fid_sts = open(project.boundaries_dir_event+sep+basename+'_'+ str(index)+'.csv', 'w')
     128        fid_sts = open(project.event_folder+sep+basename+'_'+ str(index)+'.csv', 'w')
    129129        s = 'time, stage, xmomentum, ymomentum \n'
    130130        fid_sts.write(s)
     
    144144    return quantities,elevation,time
    145145
    146 quantities,elevation,time=get_sts_gauge_data(os.path.join(project.boundaries_dir_event,project.scenario_name),verbose=False)
     146quantities,elevation,time=get_sts_gauge_data(project.event_sts,verbose=False)
    147147
    148148print len(elevation), len(quantities['stage'][0,:])
  • anuga_work/production/australia_ph2/eucla_motel/build_elevation.py

    r6294 r6300  
    5050# Create Geospatial data from ASCII files
    5151geospatial_data = {}
    52 for filename in project.ascii_grid_filenames:
    53     absolute_filename = join(project.topographies_folder, filename)
    54     convert_dem_from_ascii2netcdf(absolute_filename,
    55                                   basename_out=absolute_filename,
    56                                   use_cache=True,
    57                                   verbose=True)
    58     dem2pts(absolute_filename, use_cache=True, verbose=True)
    59 
    60     geospatial_data[filename] = Geospatial_data(file_name=absolute_filename+'.pts',
    61                                                 verbose=True)
     52##for filename in project.ascii_grid_filenames:
     53##    absolute_filename = join(project.topographies_folder, filename)
     54##    convert_dem_from_ascii2netcdf(absolute_filename,
     55##                                  basename_out=absolute_filename,
     56##                                  use_cache=True,
     57##                                  verbose=True)
     58##    dem2pts(absolute_filename, use_cache=True, verbose=True)
     59##
     60##    geospatial_data[filename] = Geospatial_data(file_name=absolute_filename+'.pts',
     61##                                                verbose=True)
    6262
    6363### Create Geospatial data from TXT files
    64 ##for filename in project.point_filenames:
    65 ##    absolute_filename = join(project.topographies_folder, filename)
    66 ##    geospatial_data[filename] = Geospatial_data(file_name=absolute_filename,
    67 ##                                                verbose=True)
     64for filename in project.point_filenames:
     65    absolute_filename = join(project.topographies_folder, filename)
     66    geospatial_data[filename] = Geospatial_data(file_name=absolute_filename,
     67                                                verbose=True)
    6868
    6969
  • anuga_work/production/australia_ph2/eucla_motel/project.py

    r6294 r6300  
    3232# Note, the user needs to set up the directory system accordingly
    3333state = 'australia_ph2'
    34 scenario_name = 'ceduna'
     34scenario_name = 'eucla_motel'
    3535
    3636#------------------------------------------------------------------------------
     
    4444friction = 0.01           # manning's friction coefficient
    4545starttime = 0             
    46 finaltime = 80000         # final time for simulation
     46finaltime = 1000 #80000         # final time for simulation
    4747
    48 setup = 'trial'  # Final can be replaced with trial or basic.
     48setup = 'final'  # Final can be replaced with trial or basic.
    4949               # Either will result in a coarser mesh that will allow a
    5050               # faster, but less accurate, simulation.
     
    8181# Used in build_elevation.py
    8282# Format for ascii grids, as produced in ArcGIS + a projection file
    83 ascii_grid_filenames = ['grid250m'] # 250m grid 2005
     83##ascii_grid_filenames = ['grid250m'] # 250m grid 2005
    8484
    8585# Format for point is x,y,elevation (with header)
    86 ##point_filenames = ['Busselton_Contour0.txt',     # Coastline
    87 ##                   'Busselton_BeachSurvey.txt',    # Beach survey
    88 ##                   'Busselton_NavyFinal.txt',  # Bathymetry
    89 ##                   'Busselton_Chart.txt', # Bathymetry Charts
    90 ##                   'Busselton_Digitised.txt', # Digitised Fairsheet
    91 ##                   'Busselton_250m.txt', # 250m
    92 ##                   'Bunbury_TIN.txt', # Bunbury aoi TIN'd in ArcGIS
    93 ##                   'Busselton_TIN.txt', # Busselton aoi TIN'd in ArcGIS
    94 ##                   'XYAHD_clip.txt'] # To extend boundary
     86point_filenames = ['grid250m_pts.txt'] # To extend boundary
    9587
    9688# BOUNDING POLYGON - for data clipping and estimate of triangles in mesh
     
    156148event_sts = join(boundaries_folder, str(event_number), scenario_name)
    157149
     150# The absolute pathname of the event folder
     151event_folder = join(boundaries_folder, str(event_number))
     152
    158153# The absolute pathname for the output folder names
    159154# Used for build_elevation.py
Note: See TracChangeset for help on using the changeset viewer.