1 | """Common filenames for truescale Okushiri Island validation |
---|
2 | Formats are given as ANUGA native netCDF where applicable. |
---|
3 | |
---|
4 | """ |
---|
5 | from os import sep, environ, getenv, getcwd, umask |
---|
6 | from os.path import expanduser, basename, join |
---|
7 | from anuga.utilities.polygon import read_polygon, plot_polygons, polygon_area, is_inside_polygon, number_mesh_triangles |
---|
8 | import sys |
---|
9 | from anuga.coordinate_transforms.redfearn import degminsec2decimal_degrees |
---|
10 | from time import localtime, strftime, gmtime |
---|
11 | from anuga.utilities.system_tools import get_user_name, get_host_name |
---|
12 | |
---|
13 | codename = 'project_grad.py' # FIXME can be obtained automatically as __file__ |
---|
14 | |
---|
15 | home = join(getenv('INUNDATIONHOME'), 'data', 'anuga_validation', |
---|
16 | 'convergence_okushiri_2008')# Location of Data |
---|
17 | user = get_user_name() |
---|
18 | host = get_host_name() |
---|
19 | #needed when running using mpirun, mpirun doesn't inherit umask from .bashrc |
---|
20 | umask(002) |
---|
21 | |
---|
22 | #time stuff |
---|
23 | time = strftime('%Y%m%d_%H%M%S',gmtime()) #gets time for new dir |
---|
24 | run_time = time+'_run' |
---|
25 | |
---|
26 | #Set anuga directories |
---|
27 | anuga_dir = join(home, 'anuga') |
---|
28 | |
---|
29 | dir_comment='_'+setup+'_'+str(tide)+'_'+\ |
---|
30 | str(user)+'_'+boundary_event+'_'+which_data |
---|
31 | |
---|
32 | mesh_dir = join(anuga_dir, 'meshes') |
---|
33 | mesh_name = join(mesh_dir, 'okushiri_truescale') |
---|
34 | |
---|
35 | polygons_dir = join(anuga_dir, 'polygons') # Created with ArcGIS (csv files) |
---|
36 | tide_dir = join(anuga_dir, 'tide_data') |
---|
37 | |
---|
38 | #output locations |
---|
39 | output_dir = join(anuga_dir, 'outputs')+sep |
---|
40 | output_run_time_dir = output_dir +run_time+dir_comment+sep |
---|
41 | output_run_time_dir_name = output_run_time_dir + scenario_name #Used by post processing |
---|
42 | |
---|
43 | #gauges |
---|
44 | gauges_dir = join(anuga_dir,'gauges') |
---|
45 | gauge_name = 'gauge_location_onslow.csv' |
---|
46 | gauges_dir_name = gauges_dir + gauge_name |
---|
47 | |
---|
48 | # Given boundary wave |
---|
49 | boundary_filename = 'okushiri_truescale_input.tms' |
---|
50 | |
---|
51 | # Observed timeseries |
---|
52 | validation_filename = 'okushiri_output_truescale_ch5-7-9.txt' |
---|
53 | |
---|
54 | # Digital Elevation Model |
---|
55 | bathymetry_filename = 'okushiri_truescale_bathymetry.pts' |
---|
56 | |
---|
57 | # Triangular mesh |
---|
58 | mesh_filename = 'okushiri_truescale.msh' |
---|
59 | |
---|
60 | # Model output |
---|
61 | output_filename = 'okushiri_truescale.sww' |
---|
62 | |
---|
63 | |
---|
64 | |
---|