Skip to content

Commit

Permalink
Create NSHA models from gridded b values
Browse files Browse the repository at this point in the history
  • Loading branch information
Joanne Stephenson committed Jan 23, 2020
1 parent 1a23b7e commit 332a012
Show file tree
Hide file tree
Showing 22 changed files with 101,547 additions and 6 deletions.
8 changes: 4 additions & 4 deletions jobs/run_oq_deag_high_mem_mde_batch.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def find_replace(rep, infile_s, outfile_s):

SA = "0.2"
SA_s = "SA02"
poe = "0.02"
poe = "0.02" # check this is needed - more than one peo may be needed


with open("cities_021019.csv") as csvfile:
Expand Down Expand Up @@ -146,8 +146,8 @@ def find_replace(rep, infile_s, outfile_s):


# Change to output directory and submit job
# batch jobs need to go into ALL the folders and run the coresponding scripts
# there must be a way to loop through akl folder smartly.
# batch jobs needs to go into ALL the folders and run the coresponding scripts
# there must be a way to loop through all folders smartly?
output_dirs.append(output_dir)

for i,directory in enumerate(output_dirs):
Expand All @@ -158,7 +158,7 @@ def find_replace(rep, infile_s, outfile_s):
print cmd
os.system(cmd)

# add section to clean up job files putting them in the right directories
# TODO: add section to clean up job files putting them in the right directories



Expand Down
5 changes: 3 additions & 2 deletions jobs/run_oq_model_high_mem.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@

# Build run_<model>.sh
outlines = '#PBS -P w84\n'
outlines += '#PBS -q normalbw\n' # for high-memory jobs
outlines += '#PBS -q normal\n' # for high-memory jobs
outlines += '#PBS -l storage=scratch/w84\n'
outlines += '#PBS -l walltime=%s\n' % params['walltime']
outlines += '#PBS -l ncpus=%s\n' % params['ncpus']
Expand All @@ -112,7 +112,8 @@
#outlines += 'module load openquake/2.1.1\n'
#outlines += 'module load openquake/2.4\n'
#outlines += 'module load openquake/3.1\n' # used in the NSHA18
outlines += 'module load openquake/3.6\n'
#outlines += 'module load openquake/3.6\n'
outlines += 'module load openquake/3.7.1\n'
outlines += 'oq-ini.all.sh\n'
# zip inputs - oq zip /path/to/your/job.ini job.zip
#outlines += 'oq zip %s job.zip\n' % full_job_dir
Expand Down
50 changes: 50 additions & 0 deletions jobs/test_gridded_b/job_maps_PGA_gridded_bval.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
[general]

description = NSHA 2018 PGA - NATIONAL MAP
calculation_mode = classical
random_seed = 23
optimize_same_id_sources=True
#concurrent_tasks = 1008

[geometry]

#region = 109 -47, 109 -8, 158 -8, 158 -47
#region_grid_spacing = 15.0
sites_csv = nsha18_map_sites.csv

[logic_tree]

number_of_logic_tree_samples = 0

[erf]

rupture_mesh_spacing = 2
complex_fault_mesh_spacing = 20
width_of_mfd_bin = 0.1
area_source_discretization = 15.0

[site_params]

reference_vs30_type = measured
reference_vs30_value = 760.0
reference_depth_to_2pt5km_per_sec = 0.0
reference_depth_to_1pt0km_per_sec = 100.0

[calculation]

source_model_logic_tree_file = nsha18_source_model_logic_tree_gridded_bval.xml
gsim_logic_tree_file = NSHA18_Aus_GMPE_75thp_logic_tree_cal_power_p0.4_simplified_July18.xml
investigation_time = 50.0
intensity_measure_types_and_levels = {"PGA": [0.00007, 0.0001, 0.0003, 0.0005, 0.0007, 0.001, 0.003, 0.005, 0.007, 0.0098, 0.0137, 0.0192, 0.0269, 0.0376, 0.0527, 0.0738, 0.103, 0.145, 0.203, 0.284, 0.397, 0.556, 0.778, 1.09]}
truncation_level = 3
maximum_distance = {"Cratonic": 400.0, "Non_cratonic": 400.0, "Subduction": 1000.0}

[output]

export_dir = ./results_maps_PGA
mean_hazard_curves=true
individual_curves=false
quantile_hazard_curves =
hazard_maps=true
uniform_hazard_spectra =
poes = 0.1 0.0952 0.02
50 changes: 50 additions & 0 deletions jobs/test_gridded_b/job_maps_PGA_nsha_bval.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
[general]

description = NSHA 2018 PGA - NATIONAL MAP
calculation_mode = classical
random_seed = 23
optimize_same_id_sources=True
#concurrent_tasks = 1008

[geometry]

#region = 109 -47, 109 -8, 158 -8, 158 -47
#region_grid_spacing = 15.0
sites_csv = nsha18_map_sites.csv

[logic_tree]

number_of_logic_tree_samples = 0

[erf]

rupture_mesh_spacing = 2
complex_fault_mesh_spacing = 20
width_of_mfd_bin = 0.1
area_source_discretization = 15.0

[site_params]

reference_vs30_type = measured
reference_vs30_value = 760.0
reference_depth_to_2pt5km_per_sec = 0.0
reference_depth_to_1pt0km_per_sec = 100.0

[calculation]

source_model_logic_tree_file = nsha18_source_model_logic_tree_nsha_bval.xml
gsim_logic_tree_file = NSHA18_Aus_GMPE_75thp_logic_tree_cal_power_p0.4_simplified_July18.xml
investigation_time = 50.0
intensity_measure_types_and_levels = {"PGA": [0.00007, 0.0001, 0.0003, 0.0005, 0.0007, 0.001, 0.003, 0.005, 0.007, 0.0098, 0.0137, 0.0192, 0.0269, 0.0376, 0.0527, 0.0738, 0.103, 0.145, 0.203, 0.284, 0.397, 0.556, 0.778, 1.09]}
truncation_level = 3
maximum_distance = {"Cratonic": 400.0, "Non_cratonic": 400.0, "Subduction": 1000.0}

[output]

export_dir = ./results_maps_PGA
mean_hazard_curves=true
individual_curves=false
quantile_hazard_curves =
hazard_maps=true
uniform_hazard_spectra =
poes = 0.1 0.0952 0.02
Loading

0 comments on commit 332a012

Please sign in to comment.