Skip to content

Commit

Permalink
merge
Browse files Browse the repository at this point in the history
  • Loading branch information
zhuwq0 committed Nov 23, 2023
1 parent a16d0de commit 5915770
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions eqnet/data/das.py
Original file line number Diff line number Diff line change
Expand Up @@ -503,6 +503,7 @@ def __init__(
skip_existing=False,
pick_path="./",
folder_depth=1, # parent folder depth of pick_path
folder_depth=1, # parent folder depth of pick_path
num_patch=2,
masking=False,
highpass_filter=0.0,
Expand Down Expand Up @@ -596,6 +597,7 @@ def __init__(
self.skip_existing = skip_existing
self.pick_path = pick_path
self.folder_depth = folder_depth
self.folder_depth = folder_depth
self.num_patch = num_patch
self.masking = masking
self.highpass_filter = highpass_filter
Expand Down Expand Up @@ -797,7 +799,6 @@ def sample_training(self, file_list):

def sample(self, file_list):
for file in file_list:

if not self.cut_patch:
existing = self.check_existing(file)
if self.skip_existing and existing:
Expand Down Expand Up @@ -968,12 +969,12 @@ def check_existing(self, file, sample=None):
os.path.join(
self.pick_path,
parent_dir,
parent_dir,
os.path.splitext(file.split("/")[-1])[0] + f"_{i:04d}_{j:04d}.csv",
)
):
existing = False


return existing


Expand Down

0 comments on commit 5915770

Please sign in to comment.