Closed dr-glenn closed 2 years ago
Good point @dr-glenn ! I think a simple change to station_picks
after this line would simply fix this.
Do you want to try adding the line:
if _swin != "all":
station_picks = [p for p in station_picks if p.phase_hint]
just after station_picks
is defined (it should be line 730) and see if that gets around the issue? If that works we should make a pull-request with that change and a small test to fix this bug.
This should be fixed in #510 - closing.
I want to use swin='P' or swin='P_all' in template_gen, but program sometimes aborts.
Unfortunately some of the event picks are missing phase_hint. template_gen throws an exception on line 687:
if pick.phase_hint.upper()[0] == 'P' and
Of course this problem does not occur if swin='all', because the phase_hint attribute is not used.Expected behavior
Would be nice if it would just skip over any pick that had no phase_hint attribute.
Desktop