Skip to content

Commit

Permalink
Added --source_parameter sites_info
Browse files Browse the repository at this point in the history
  • Loading branch information
sungeunbae committed Jul 16, 2024
1 parent af78a60 commit de8a2f8
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -191,9 +191,8 @@ def generate_from_gcmt(
#rdist_sigma = 2
#depth_sigma = additional_source_parameters["depth_sigma"]

sites_info_csv = Path(additional_source_parameters["sites_info_csv"])
sites_info_csv = Path(additional_source_parameters["sites_info"])
assert sites_info_csv.exists()

sites_info = pd.read_csv(sites_info_csv)


Expand All @@ -212,11 +211,11 @@ def generate_from_gcmt(
if sites_info is not None:
rrup_data = sites_info.rrup
rrup_data_perturbed = distributions.truncated_log_normal(rrup_data , 0.1, 4)
sites_info["rrup_perturbed"] = rrup_data_perturbed
sites_info["rrup"] = rrup_data_perturbed
new_sites_info_csv = sites_info_csv.parent / f"{sites_info_csv.stem}_rrup_perturbed.csv"
sites_info.to_csv(new_sites_info_csv, index=False)
else:
print("Didn't get rrup")
print("Didn't get sites_info CSV")


#temp = Geodesic.WGS84.Direct(sources_line.lat, sources_line.lon, theta, r_distance)
Expand Down

0 comments on commit de8a2f8

Please sign in to comment.