[bugfix] catch empty pickdics during comparison
Only the P phase might be picked by purpose, or the autopicker might not find any valid S onsets
This commit is contained in:
parent
00df77e723
commit
c65d6b8376
20
QtPyLoT.py
20
QtPyLoT.py
@ -1668,10 +1668,22 @@ class MainWindow(QMainWindow):
|
|||||||
if event.pylot_picks and event.pylot_autopicks:
|
if event.pylot_picks and event.pylot_autopicks:
|
||||||
for station in event.pylot_picks:
|
for station in event.pylot_picks:
|
||||||
if station in event.pylot_autopicks:
|
if station in event.pylot_autopicks:
|
||||||
autopick_p = event.pylot_autopicks[station]['P']['spe']
|
try:
|
||||||
manupick_p = event.pylot_picks[station]['P']['spe']
|
autopick_p = event.pylot_autopicks[station]['P']['spe']
|
||||||
autopick_s = event.pylot_autopicks[station]['S']['spe']
|
except KeyError:
|
||||||
manupick_s = event.pylot_picks[station]['S']['spe']
|
autopick_p = None
|
||||||
|
try:
|
||||||
|
manupick_p = event.pylot_picks[station]['P']['spe']
|
||||||
|
except KeyError:
|
||||||
|
manupick_p = None
|
||||||
|
try:
|
||||||
|
autopick_s = event.pylot_autopicks[station]['S']['spe']
|
||||||
|
except KeyError:
|
||||||
|
autopick_s = None
|
||||||
|
try:
|
||||||
|
manupick_s = event.pylot_picks[station]['S']['spe']
|
||||||
|
except KeyError:
|
||||||
|
manupick_s = None
|
||||||
if autopick_p and manupick_p:
|
if autopick_p and manupick_p:
|
||||||
return True
|
return True
|
||||||
elif autopick_s and manupick_s:
|
elif autopick_s and manupick_s:
|
||||||
|
Loading…
Reference in New Issue
Block a user