Datasets:

ArXiv:
DOI:
License:
zhuwq0 chapsticklover commited on
Commit
38b02ef
·
1 Parent(s): 69ce029

fix dataset generation error (#7)

Browse files

- fix dataset generation error (e8ea1a2f7ada3743436f886339c6be0f907b1295)


Co-authored-by: Sal Blanco <chapsticklover@users.noreply.huggingface.co>

Files changed (1) hide show
  1. quakeflow_nc.py +1 -1
quakeflow_nc.py CHANGED
@@ -316,7 +316,7 @@ class QuakeFlow_NC(datasets.GeneratorBasedBuilder):
316
  is_sick = False
317
  for sta_id in station_ids:
318
  attrs = event[sta_id].attrs
319
- if attrs["phase_index"][attrs["phase_type"] == "P"] == attrs["phase_index"][attrs["phase_type"] == "S"]:
320
  is_sick = True
321
  break
322
  if is_sick:
 
316
  is_sick = False
317
  for sta_id in station_ids:
318
  attrs = event[sta_id].attrs
319
+ if not np.intersect1d(attrs["phase_index"][attrs["phase_type"] == "P"], attrs["phase_index"][attrs["phase_type"] == "S"]):
320
  is_sick = True
321
  break
322
  if is_sick: