Skip to content

Commit

Permalink
updates to fermi inversion
Browse files Browse the repository at this point in the history
  • Loading branch information
cossatot committed Dec 10, 2024
1 parent b24da22 commit dad21a5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 2 additions & 0 deletions openquake/fnm/all_together_now.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@
'surface_type': 'simple',
'min_mag': None,
'max_mag': None,
"filter_seed": 69,
}


Expand Down Expand Up @@ -333,6 +334,7 @@ def build_fault_network(
filter_proportionally_to_plausibility(
fault_network['rupture_df'],
fault_network['plausibility']['total'],
seed=settings['filter_seed'],
)
)
t8 = time.time()
Expand Down
6 changes: 4 additions & 2 deletions openquake/fnm/inversion/soe_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -197,8 +197,10 @@ def make_rel_gr_mfd_eqns(

rel_mag_eqns_lhs = rel_mag_eqns
rel_mag_eqns_rhs = np.zeros(rel_mag_eqns_lhs.shape[0]) # flat, not column
rel_mag_eqns_errs = np.sqrt([(rel_rates_adj[M]) for M in unique_mags[1:]])
rel_mag_eqns_errs /= weight
# rel_mag_eqns_errs = np.sqrt([(rel_rates_adj[M]) for M in unique_mags[1:]])
rel_mag_eqns_errs = np.array([(rel_rates_adj[M]) for M in unique_mags[1:]])
# rel_mag_eqns_errs = rel_mag_eqns_errs**-2
rel_mag_eqns_errs *= weight

return rel_mag_eqns_lhs, rel_mag_eqns_rhs, rel_mag_eqns_errs

Expand Down

0 comments on commit dad21a5

Please sign in to comment.