Changeset 6756
- Timestamp:
- Apr 8, 2009, 8:32:34 AM (15 years ago)
- Location:
- anuga_work/production/australia_ph2
- Files:
-
- 11 edited
Legend:
- Unmodified
- Added
- Removed
-
anuga_work/production/australia_ph2/bundaberg/project.py
r6743 r6756 7 7 from anuga.utilities.system_tools import get_user_name, get_host_name 8 8 from time import localtime, strftime, gmtime 9 #from anuga.lib.add_csv_header import add_csv_header10 from add_csv_header import add_csv_header11 9 from os.path import join, exists 12 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 13 11 14 12 #------------------------------------------------------------------------------- … … 20 18 state = 'australia_ph2' 21 19 scenario_name = 'bundaberg' 22 scenario_folder = scenario_name23 20 24 21 #------------------------------------------------------------------------------- … … 28 25 # Model specific parameters. 29 26 # One or all can be changed each time the run_model script is executed 30 tide = 0 # difference between MSL and HAT 31 zone = 56 # specify zone of model 32 ##central_meridian = 143.5 # nonstandard projection 33 34 27 28 central_meridian = 153.0 # Central meridian for projection (optional) 29 #zone = 56 35 30 import sys 36 31 if len(sys.argv) > 1: … … 38 33 else: 39 34 event_number = 31756 # the event number or the mux file name 40 35 41 36 event_number_list = [31756, 51469, 62840] # To piggy back multiple events 42 # using run_multiple_events.py 43 37 38 tide = 0 # difference between MSL and HAT 44 39 alpha = 0.1 # smoothing parameter for mesh 45 40 friction=0.01 # manning's friction coefficient 46 41 starttime=0 # start time for simulation 47 finaltime=80000 # final time for simulation 48 49 # index is only used when wave = Tb 50 index = 1889 # index from the PTHA 51 wave = 'Tb' # Bf (sts wave) Tb (index wave) 52 42 finaltime=1000 #60000 # final time for simulation 53 43 setup = 'trial' # This can be one of three values 54 44 # trial - coarsest mesh, fast 55 45 # basic - coarse mesh 56 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = 3274 # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 57 52 58 53 internal_polygon = False … … 72 67 internal_poly_comment = 'internal' 73 68 else: 74 internal_poly_comment = None69 internal_poly_comment = '' 75 70 76 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] … … 85 80 ascii_grid_filenames = ['grid250m_pro'] # 250m grid 2005 86 81 87 # Format for point is x,y,elevation (with header) 88 ##point_filenames = [] 82 # Format for points is x,y,elevation (with header) 89 83 point_filenames = ['ahs100_0.txt', 90 84 'ahs100_1.txt', … … 102 96 'ahs100_13.txt'] # LADS data 103 97 98 ### Add csv header list to all files in point_filenames 99 ##headerlist = ['x', 'y', 'elevation'] 100 ##for f in point_filenames: 101 ## add_csv_header(join(topographies_folder, f), headerlist) 102 104 103 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 105 104 # Used in build_elevation.py 106 # Format for points easting,northing (no header)105 # Format for points: easting,northing (no header) 107 106 bounding_polygon_filename = 'bounding_polygon.csv' 108 107 bounding_polygon_maxarea = 125000 … … 133 132 # Used in run_building_inundation.py 134 133 # Format latitude,longitude etc (geographic) 135 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS134 building_exposure_filename = '.csv' # from NEXIS 136 135 137 136 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 151 150 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 152 151 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 153 ##mux_input_filename = event_number # to be found in event_folder 154 # (ie boundaries/event_number/) 152 ##mux_input_filename = 'Java-0016-z.grd' 155 153 ##multi_mux = False 156 154 mux_input_filename = 'event.list' 157 155 multi_mux = True 156 157 # Specify if share cache is to be used 158 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 159 # If nothing is specified, local cache will be used. 160 cachedir = '.python_cache_phII' 158 161 159 162 … … 178 181 179 182 #------------------------------------------------------------------------------- 183 # Output Elevation Data 184 #------------------------------------------------------------------------------- 185 186 # Output filename for elevation 187 # this is a combination of all the data generated in build_elevation.py 188 combined_elevation_basename = scenario_name + '_combined_elevation' 189 190 #------------------------------------------------------------------------------- 180 191 # Directory Structure 181 192 #------------------------------------------------------------------------------- … … 190 201 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 191 202 muxhome = os.getenv(ENV_MUXHOME) 203 204 # Create absolute pathname for cache directory 205 # and change caching to use it 206 if 'cachedir' in dir(): 207 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 208 from anuga.caching import caching 209 caching.set_option('cachedir', cachedir) 192 210 193 211 # check various directories/files that must exist 194 anuga_folder = join(home, state, scenario_ folder, 'anuga')212 anuga_folder = join(home, state, scenario_name, 'anuga') 195 213 topographies_folder = join(anuga_folder, 'topographies') 196 214 polygons_folder = join(anuga_folder, 'polygons') … … 206 224 207 225 #------------------------------------------------------------------------------- 208 # Output Elevation Data209 #-------------------------------------------------------------------------------210 211 # Output filename for elevation212 # this is a combination of all the data generated in build_elevation.py213 combined_elevation_basename = scenario_name + '_combined_elevation'214 215 #-------------------------------------------------------------------------------216 226 # Location of input and output data 217 227 #------------------------------------------------------------------------------- -
anuga_work/production/australia_ph2/bundaberg/run_multiple_events.py
r6743 r6756 1 1 """This script executes models for a range of event numbers. 2 2 3 Events must have been created first 3 Events folders and event.list must have been created first from 4 the event selection program 4 5 """ 5 6 -
anuga_work/production/australia_ph2/cairns/project.py
r6744 r6756 8 8 from time import localtime, strftime, gmtime 9 9 from os.path import join, exists 10 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 11 11 12 12 #------------------------------------------------------------------------------- … … 18 18 state = 'australia_ph2' 19 19 scenario_name = 'cairns' 20 scenario_folder = scenario_name21 20 22 21 #------------------------------------------------------------------------------- … … 26 25 # Model specific parameters. 27 26 # One or all can be changed each time the run_model script is executed 28 tide = 0 # difference between MSL and HAT 29 zone = 55 # specify zone of model 30 ##central_meridian = 143.5 # nonstandard projection 31 32 27 28 central_meridian = 147 # Central meridian for projection (optional) 29 #zone = 55 33 30 import sys 34 31 if len(sys.argv) > 1: 35 32 event_number = int(sys.argv[1]) 36 33 else: 37 event_number = 31975# the event number or the mux file name38 39 event_number_list = [ 31975, 51469, 63767] # To piggy back multiple events40 # using run_multiple_events.py 41 34 event_number = # the event number or the mux file name 35 36 event_number_list = [] # To piggy back multiple events 37 38 tide = 0 # difference between MSL and HAT 42 39 alpha = 0.1 # smoothing parameter for mesh 43 40 friction=0.01 # manning's friction coefficient 44 41 starttime=0 # start time for simulation 45 finaltime=80000 # final time for simulation 46 47 # index is only used when wave = Tb 48 index = 1889 # index from the PTHA 49 wave = 'Tb' # Bf (sts wave) Tb (index wave) 50 42 finaltime=1000 #60000 # final time for simulation 51 43 setup = 'trial' # This can be one of three values 52 44 # trial - coarsest mesh, fast 53 45 # basic - coarse mesh 54 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 55 52 56 53 internal_polygon = False … … 70 67 internal_poly_comment = 'internal' 71 68 else: 72 internal_poly_comment = None69 internal_poly_comment = '' 73 70 74 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] … … 83 80 ascii_grid_filenames = ['grid250m_pro'] # 250m grid 2005 84 81 85 # Format for point is x,y,elevation (with header) 86 ##point_filenames = [] 82 # Format for points is x,y,elevation (with header) 87 83 point_filenames = ['ahs100_0.txt', 88 84 'ahs100_1.txt', … … 100 96 'ahs100_13.txt'] # LADS data 101 97 98 ### Add csv header list to all files in point_filenames 99 ##headerlist = ['x', 'y', 'elevation'] 100 ##for f in point_filenames: 101 ## add_csv_header(join(topographies_folder, f), headerlist) 102 102 103 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 103 104 # Used in build_elevation.py 104 # Format for points easting,northing (no header)105 # Format for points: easting,northing (no header) 105 106 bounding_polygon_filename = 'bounding_polygon.csv' 106 107 bounding_polygon_maxarea = 125000 … … 131 132 # Used in run_building_inundation.py 132 133 # Format latitude,longitude etc (geographic) 133 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS134 building_exposure_filename = '.csv' # from NEXIS 134 135 135 136 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 149 150 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 150 151 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 151 ##mux_input_filename = event_number # to be found in event_folder 152 # (ie boundaries/event_number/) 152 ##mux_input_filename = 'Java-0016-z.grd' 153 153 ##multi_mux = False 154 154 mux_input_filename = 'event.list' 155 155 multi_mux = True 156 157 # Specify if share cache is to be used 158 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 159 # If nothing is specified, local cache will be used. 160 cachedir = '.python_cache_phII' 156 161 157 162 … … 196 201 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 197 202 muxhome = os.getenv(ENV_MUXHOME) 203 204 # Create absolute pathname for cache directory 205 # and change caching to use it 206 if 'cachedir' in dir(): 207 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 208 from anuga.caching import caching 209 caching.set_option('cachedir', cachedir) 198 210 199 211 # check various directories/files that must exist 200 anuga_folder = join(home, state, scenario_ folder, 'anuga')212 anuga_folder = join(home, state, scenario_name, 'anuga') 201 213 topographies_folder = join(anuga_folder, 'topographies') 202 214 polygons_folder = join(anuga_folder, 'polygons') … … 235 247 event_sts = join(event_folder, scenario_name) 236 248 237 238 239 249 # The absolute pathname for the output folder names 240 250 # Used for build_elevation.py -
anuga_work/production/australia_ph2/cairns/run_multiple_events.py
r6744 r6756 1 1 """This script executes models for a range of event numbers. 2 2 3 Events must have been created first 3 Events folders and event.list must have been created first from 4 the event selection program 4 5 """ 5 6 -
anuga_work/production/australia_ph2/cooktown/project.py
r6745 r6756 8 8 from time import localtime, strftime, gmtime 9 9 from os.path import join, exists 10 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 11 11 12 12 #------------------------------------------------------------------------------- … … 18 18 state = 'australia_ph2' 19 19 scenario_name = 'cooktown' 20 scenario_folder = scenario_name21 20 22 21 #------------------------------------------------------------------------------- … … 26 25 # Model specific parameters. 27 26 # One or all can be changed each time the run_model script is executed 28 tide = 0 # difference between MSL and HAT 29 zone = 55 # specify zone of model 30 ##central_meridian = 143.5 # nonstandard projection 31 32 27 28 central_meridian = 147.0 # Central meridian for projection (optional) 29 #zone = 55 33 30 import sys 34 31 if len(sys.argv) > 1: … … 36 33 else: 37 34 event_number = 31977 # the event number or the mux file name 38 35 39 36 event_number_list = [31977, 51469, 63735] # To piggy back multiple events 40 # using run_multiple_events.py 41 37 38 tide = 0 # difference between MSL and HAT 42 39 alpha = 0.1 # smoothing parameter for mesh 43 40 friction=0.01 # manning's friction coefficient 44 41 starttime=0 # start time for simulation 45 finaltime=80000 # final time for simulation 46 47 # index is only used when wave = Tb 48 index = 1889 # index from the PTHA 49 wave = 'Tb' # Bf (sts wave) Tb (index wave) 50 42 finaltime=1000 #60000 # final time for simulation 51 43 setup = 'trial' # This can be one of three values 52 44 # trial - coarsest mesh, fast 53 45 # basic - coarse mesh 54 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = 2065 # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 55 52 56 53 internal_polygon = False … … 70 67 internal_poly_comment = 'internal' 71 68 else: 72 internal_poly_comment = None69 internal_poly_comment = '' 73 70 74 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] … … 81 78 # Used in build_elevation.py 82 79 # Format for ascii grids, as produced in ArcGIS + a projection file 83 ascii_grid_filenames = ['grid250m_pro'] # 250m grid 2005 84 85 # Format for point is x,y,elevation (with header) 86 ##point_filenames = [] 80 ascii_grid_filenames = [] 81 82 # Format for points is x,y,elevation (with header) 87 83 point_filenames = ['ahs100_0.txt', 88 84 'ahs100_1.txt', … … 100 96 'ahs100_13.txt'] # LADS data 101 97 98 ### Add csv header list to all files in point_filenames 99 ##headerlist = ['x', 'y', 'elevation'] 100 ##for f in point_filenames: 101 ## add_csv_header(join(topographies_folder, f), headerlist) 102 102 103 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 103 104 # Used in build_elevation.py 104 # Format for points easting,northing (no header)105 # Format for points: easting,northing (no header) 105 106 bounding_polygon_filename = 'bounding_polygon.csv' 106 107 bounding_polygon_maxarea = 125000 … … 131 132 # Used in run_building_inundation.py 132 133 # Format latitude,longitude etc (geographic) 133 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS134 building_exposure_filename = '.csv' # from NEXIS 134 135 135 136 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 149 150 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 150 151 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 151 ##mux_input_filename = event_number # to be found in event_folder 152 # (ie boundaries/event_number/) 152 ##mux_input_filename = 'Java-0016-z.grd' 153 153 ##multi_mux = False 154 154 mux_input_filename = 'event.list' 155 155 multi_mux = True 156 157 # Specify if share cache is to be used 158 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 159 # If nothing is specified, local cache will be used. 160 cachedir = '.python_cache_phII' 156 161 157 162 … … 196 201 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 197 202 muxhome = os.getenv(ENV_MUXHOME) 203 204 # Create absolute pathname for cache directory 205 # and change caching to use it 206 if 'cachedir' in dir(): 207 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 208 from anuga.caching import caching 209 caching.set_option('cachedir', cachedir) 198 210 199 211 # check various directories/files that must exist 200 anuga_folder = join(home, state, scenario_ folder, 'anuga')212 anuga_folder = join(home, state, scenario_name, 'anuga') 201 213 topographies_folder = join(anuga_folder, 'topographies') 202 214 polygons_folder = join(anuga_folder, 'polygons') … … 235 247 event_sts = join(event_folder, scenario_name) 236 248 237 238 239 249 # The absolute pathname for the output folder names 240 250 # Used for build_elevation.py -
anuga_work/production/australia_ph2/cooktown/run_multiple_events.py
r6745 r6756 1 1 """This script executes models for a range of event numbers. 2 2 3 Events must have been created first 3 Events folders and event.list must have been created first from 4 the event selection program 4 5 """ 5 6 -
anuga_work/production/australia_ph2/gold_coast/project.py
r6531 r6756 8 8 from time import localtime, strftime, gmtime 9 9 from os.path import join, exists 10 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 11 11 12 12 #------------------------------------------------------------------------------- … … 18 18 state = 'australia_ph2' 19 19 scenario_name = 'gold_coast' 20 scenario_folder = scenario_name21 20 22 21 #------------------------------------------------------------------------------- … … 26 25 # Model specific parameters. 27 26 # One or all can be changed each time the run_model script is executed 27 28 central_meridian = 153.0 # Central meridian for projection (optional) 29 #zone = 56 30 import sys 31 if len(sys.argv) > 1: 32 event_number = int(sys.argv[1]) 33 else: 34 event_number = 50883 # the event number or the mux file name 35 36 event_number_list = [50883, 51318, 51453] # To piggy back multiple events 37 28 38 tide = 0 # difference between MSL and HAT 29 zone = 56 # specify zone of model30 event_number = 51314 # the event number or the mux file name31 39 alpha = 0.1 # smoothing parameter for mesh 32 40 friction=0.01 # manning's friction coefficient 33 41 starttime=0 # start time for simulation 34 finaltime=80000 # final time for simulation 35 36 # index is only used when wave = Tb 37 index = 3727 # index from the PTHA 38 wave = 'Tb' # Bf (sts wave) Tb (index wave) 39 40 setup = 'final' # This can be one of three values 42 finaltime=1000 #60000 # final time for simulation 43 setup = 'trial' # This can be one of three values 41 44 # trial - coarsest mesh, fast 42 45 # basic - coarse mesh 43 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = 3727 # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 52 53 internal_polygon = False 44 54 45 55 #------------------------------------------------------------------------------- … … 54 64 #------------------------------------------------------------------------------- 55 65 56 output_comment = [setup, tide, event_number, index, wave] 66 if internal_polygon: 67 internal_poly_comment = 'internal' 68 else: 69 internal_poly_comment = '' 70 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] 57 72 58 73 #------------------------------------------------------------------------------- … … 63 78 # Used in build_elevation.py 64 79 # Format for ascii grids, as produced in ArcGIS + a projection file 65 ascii_grid_filenames = [] # 250m grid 200566 67 # Format for point is x,y,elevation (with header)80 ascii_grid_filenames = [] 81 82 # Format for points is x,y,elevation (with header) 68 83 point_filenames = ['brisbane_250m.txt', 69 84 'GBR_250m.txt', … … 75 90 ## add_csv_header(join(topographies_folder, f), headerlist) 76 91 77 92 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 78 93 # Used in build_elevation.py 79 # Format for points easting,northing (no header)94 # Format for points: easting,northing (no header) 80 95 bounding_polygon_filename = 'bounding_polygon.csv' 81 bounding_polygon_maxarea = 1 0000096 bounding_polygon_maxarea = 125000 82 97 83 98 # INTERIOR REGIONS - for designing the mesh … … 86 101 interior_regions_data = [] 87 102 103 # add an internal polygon to force different mesh generation 104 # used to test for discretisation error when building elevation 105 # make sure file is in same folder as interior regions and bouding polygon; 106 # format is same (2 column .csv; easting, northing; no header) 107 if internal_polygon: 108 interior_regions_data.append(['internal_polygon.csv', 109 bounding_polygon_maxarea]) 110 88 111 # LAND - used to set the initial stage/water to be offcoast only 89 112 # Used in run_model.py. Format for points easting,northing (no header) … … 98 121 # Used in run_building_inundation.py 99 122 # Format latitude,longitude etc (geographic) 100 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS123 building_exposure_filename = '.csv' # from NEXIS 101 124 102 125 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 107 130 # Thinned ordering file from Hazard Map (geographic) 108 131 # Format is index,latitude,longitude (with header) 109 urs_order_filename = 'urs_order .csv'132 urs_order_filename = 'urs_order_simple.csv' 110 133 111 134 # Landward bounding points … … 116 139 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 117 140 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 118 ##mux_input_filename = event_number # to be found in event_folder 119 # (ie boundaries/event_number/) 141 ##mux_input_filename = 'Java-0016-z.grd' 120 142 ##multi_mux = False 121 143 mux_input_filename = 'event.list' 122 144 multi_mux = True 145 146 # Specify if share cache is to be used 147 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 148 # If nothing is specified, local cache will be used. 149 cachedir = '.python_cache_phII' 123 150 124 151 … … 163 190 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 164 191 muxhome = os.getenv(ENV_MUXHOME) 192 193 # Create absolute pathname for cache directory 194 # and change caching to use it 195 if 'cachedir' in dir(): 196 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 197 from anuga.caching import caching 198 caching.set_option('cachedir', cachedir) 165 199 166 200 # check various directories/files that must exist 167 anuga_folder = join(home, state, scenario_ folder, 'anuga')201 anuga_folder = join(home, state, scenario_name, 'anuga') 168 202 topographies_folder = join(anuga_folder, 'topographies') 169 203 polygons_folder = join(anuga_folder, 'polygons') … … 220 254 # full path to where MUX files (or meta-files) live 221 255 mux_input = join(event_folder, mux_input_filename) 222 #full path to boundary polygon csv 223 boundary_csv = join(event_folder, 'sts_gauge_' + str(index) +'.csv') 224 256 257 # sts gauge with desired index number - used for wave 'Tb' 258 boundary_csv = join(event_folder, 'sts_gauge_' + str(index) + '.csv') 259 260 -
anuga_work/production/australia_ph2/lucinda/project.py
r6747 r6756 8 8 from time import localtime, strftime, gmtime 9 9 from os.path import join, exists 10 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 11 11 12 12 #------------------------------------------------------------------------------- … … 18 18 state = 'australia_ph2' 19 19 scenario_name = 'lucinda' 20 scenario_folder = scenario_name21 20 22 21 #------------------------------------------------------------------------------- … … 26 25 # Model specific parameters. 27 26 # One or all can be changed each time the run_model script is executed 28 tide = 0 # difference between MSL and HAT 29 zone = 55 # specify zone of model 30 ##central_meridian = 143.5 # nonstandard projection 31 32 27 28 central_meridian = 147.0 # Central meridian for projection (optional) 29 #zone = 55 33 30 import sys 34 31 if len(sys.argv) > 1: … … 36 33 else: 37 34 event_number = 31982 # the event number or the mux file name 38 35 39 36 event_number_list = [31982, 51311, 63735] # To piggy back multiple events 40 # using run_multiple_events.py 41 37 38 tide = 0 # difference between MSL and HAT 42 39 alpha = 0.1 # smoothing parameter for mesh 43 40 friction=0.01 # manning's friction coefficient 44 41 starttime=0 # start time for simulation 45 finaltime=80000 # final time for simulation 46 47 # index is only used when wave = Tb 48 index = 1889 # index from the PTHA 49 wave = 'Tb' # Bf (sts wave) Tb (index wave) 50 42 finaltime=1000 #60000 # final time for simulation 51 43 setup = 'trial' # This can be one of three values 52 44 # trial - coarsest mesh, fast 53 45 # basic - coarse mesh 54 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = 2313 # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 55 52 56 53 internal_polygon = False … … 70 67 internal_poly_comment = 'internal' 71 68 else: 72 internal_poly_comment = None69 internal_poly_comment = '' 73 70 74 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] … … 83 80 ascii_grid_filenames = ['grid250m_pro'] # 250m grid 2005 84 81 85 # Format for point is x,y,elevation (with header)82 # Format for points is x,y,elevation (with header) 86 83 ##point_filenames = [] 87 84 point_filenames = ['ahs100_0.txt', … … 100 97 'ahs100_13.txt'] # LADS data 101 98 99 ### Add csv header list to all files in point_filenames 100 ##headerlist = ['x', 'y', 'elevation'] 101 ##for f in point_filenames: 102 ## add_csv_header(join(topographies_folder, f), headerlist) 103 102 104 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 103 105 # Used in build_elevation.py 104 # Format for points easting,northing (no header)106 # Format for points: easting,northing (no header) 105 107 bounding_polygon_filename = 'bounding_polygon.csv' 106 108 bounding_polygon_maxarea = 125000 … … 131 133 # Used in run_building_inundation.py 132 134 # Format latitude,longitude etc (geographic) 133 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS135 building_exposure_filename = '.csv' # from NEXIS 134 136 135 137 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 149 151 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 150 152 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 151 ##mux_input_filename = event_number # to be found in event_folder 152 # (ie boundaries/event_number/) 153 ##mux_input_filename = 'Java-0016-z.grd' 153 154 ##multi_mux = False 154 155 mux_input_filename = 'event.list' 155 156 multi_mux = True 157 158 # Specify if share cache is to be used 159 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 160 # If nothing is specified, local cache will be used. 161 cachedir = '.python_cache_phII' 156 162 157 163 … … 196 202 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 197 203 muxhome = os.getenv(ENV_MUXHOME) 204 205 # Create absolute pathname for cache directory 206 # and change caching to use it 207 if 'cachedir' in dir(): 208 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 209 from anuga.caching import caching 210 caching.set_option('cachedir', cachedir) 198 211 199 212 # check various directories/files that must exist 200 anuga_folder = join(home, state, scenario_ folder, 'anuga')213 anuga_folder = join(home, state, scenario_name, 'anuga') 201 214 topographies_folder = join(anuga_folder, 'topographies') 202 215 polygons_folder = join(anuga_folder, 'polygons') … … 235 248 event_sts = join(event_folder, scenario_name) 236 249 237 238 239 250 # The absolute pathname for the output folder names 240 251 # Used for build_elevation.py -
anuga_work/production/australia_ph2/lucinda/run_multiple_events.py
r6747 r6756 1 1 """This script executes models for a range of event numbers. 2 2 3 Events must have been created first 3 Events folders and event.list must have been created first from 4 the event selection program 4 5 """ 5 6 -
anuga_work/production/australia_ph2/rockhampton/project.py
r6748 r6756 8 8 from time import localtime, strftime, gmtime 9 9 from os.path import join, exists 10 10 from anuga.lib.add_csv_header.add_csv_header import add_csv_header 11 11 12 12 #------------------------------------------------------------------------------- … … 18 18 state = 'australia_ph2' 19 19 scenario_name = 'rockhampton' 20 scenario_folder = scenario_name21 20 22 21 #------------------------------------------------------------------------------- … … 26 25 # Model specific parameters. 27 26 # One or all can be changed each time the run_model script is executed 28 tide = 0 # difference between MSL and HAT 29 zone = 56 # specify zone of model 30 ##central_meridian = 143.5 # nonstandard projection 31 32 27 28 central_meridian = 153.0 # Central meridian for projection (optional) 29 #zone = 56 33 30 import sys 34 31 if len(sys.argv) > 1: … … 36 33 else: 37 34 event_number = 31939 # the event number or the mux file name 38 35 39 36 event_number_list = [31939, 51314, 63737] # To piggy back multiple events 40 # using run_multiple_events.py 41 37 38 tide = 0 # difference between MSL and HAT 42 39 alpha = 0.1 # smoothing parameter for mesh 43 40 friction=0.01 # manning's friction coefficient 44 41 starttime=0 # start time for simulation 45 finaltime=80000 # final time for simulation 46 47 # index is only used when wave = Tb 48 index = 1889 # index from the PTHA 49 wave = 'Tb' # Bf (sts wave) Tb (index wave) 50 42 finaltime=1000 #60000 # final time for simulation 51 43 setup = 'trial' # This can be one of three values 52 44 # trial - coarsest mesh, fast 53 45 # basic - coarse mesh 54 46 # final - fine mesh, slowest 47 48 # index is only used when wave = Tb 49 index = 3163 # index from the PTHA - Y2000 0.257m 50 wave = 'Tb' # Bf (sts wave) Tb (index wave) 51 55 52 56 53 internal_polygon = False … … 70 67 internal_poly_comment = 'internal' 71 68 else: 72 internal_poly_comment = None69 internal_poly_comment = '' 73 70 74 71 output_comment = [setup, tide, event_number, index, wave, internal_poly_comment] … … 83 80 ascii_grid_filenames = ['grid250m_pro'] # 250m grid 2005 84 81 85 # Format for point is x,y,elevation (with header)82 # Format for points is x,y,elevation (with header) 86 83 ##point_filenames = [] 87 84 point_filenames = ['ahs100_0.txt', … … 100 97 'ahs100_13.txt'] # LADS data 101 98 99 ### Add csv header list to all files in point_filenames 100 ##headerlist = ['x', 'y', 'elevation'] 101 ##for f in point_filenames: 102 ## add_csv_header(join(topographies_folder, f), headerlist) 103 102 104 # BOUNDING POLYGON - for data clipping and estimate of triangles in mesh 103 105 # Used in build_elevation.py 104 # Format for points easting,northing (no header)106 # Format for points: easting,northing (no header) 105 107 bounding_polygon_filename = 'bounding_polygon.csv' 106 108 bounding_polygon_maxarea = 125000 … … 131 133 # Used in run_building_inundation.py 132 134 # Format latitude,longitude etc (geographic) 133 building_exposure_filename = ' busselton_res_clip.csv' # from NEXIS135 building_exposure_filename = '.csv' # from NEXIS 134 136 135 137 # BOUNDING POLYGON - used in build_boundary.py and run_model.py respectively … … 149 151 # If a meta-file from EventSelection is used, set 'multi-mux' to True. 150 152 # If a single MUX stem filename (*.grd) is used, set 'multi-mux' to False. 151 ##mux_input_filename = event_number # to be found in event_folder 152 # (ie boundaries/event_number/) 153 ##mux_input_filename = 'Java-0016-z.grd' 153 154 ##multi_mux = False 154 155 mux_input_filename = 'event.list' 155 156 multi_mux = True 157 158 # Specify if share cache is to be used 159 # Whatever is specified here will be relative to INUNDATION_HOME/.cache 160 # If nothing is specified, local cache will be used. 161 cachedir = '.python_cache_phII' 156 162 157 163 … … 196 202 home = join(os.getenv(ENV_INUNDATIONHOME), 'data') # Absolute path for data folder 197 203 muxhome = os.getenv(ENV_MUXHOME) 204 205 # Create absolute pathname for cache directory 206 # and change caching to use it 207 if 'cachedir' in dir(): 208 cachedir = join(os.getenv(ENV_INUNDATIONHOME), '.cache', cachedir) 209 from anuga.caching import caching 210 caching.set_option('cachedir', cachedir) 198 211 199 212 # check various directories/files that must exist 200 anuga_folder = join(home, state, scenario_ folder, 'anuga')213 anuga_folder = join(home, state, scenario_name, 'anuga') 201 214 topographies_folder = join(anuga_folder, 'topographies') 202 215 polygons_folder = join(anuga_folder, 'polygons') … … 235 248 event_sts = join(event_folder, scenario_name) 236 249 237 238 239 250 # The absolute pathname for the output folder names 240 251 # Used for build_elevation.py -
anuga_work/production/australia_ph2/rockhampton/run_multiple_events.py
r6748 r6756 1 1 """This script executes models for a range of event numbers. 2 2 3 Events must have been created first 3 Events folders and event.list must have been created first from 4 the event selection program 4 5 """ 5 6
Note: See TracChangeset
for help on using the changeset viewer.