[refs #200] ongoing work on parameter derivation

This commit is contained in:
Sebastian Wehling-Benatelli 2016-08-31 13:41:18 +02:00
parent facffa1bf2
commit 81640d30f9

View File

@ -947,7 +947,14 @@ class MainWindow(QMainWindow):
self.getData().applyEVTData(lt.read_location(locpath), type='event') self.getData().applyEVTData(lt.read_location(locpath), type='event')
def calc_magnitude(self): def calc_magnitude(self):
if self.getData().getEvtData().origins: e = self.getData().getEvtData()
if e.origins:
o = e.origins[0]
for a in o.arrivals:
pid = a.pick_id
pick = pid.get_referred_object()
station = self.getStationID(pick.waveform_id.station_code)
wf = self.getData().getWFData().select(station=station)
mag = None mag = None
return mag return mag
else: else: