Replaced fixed plotting advice with iplot parameter.

This commit is contained in:
Ludger Küperkoch 2016-10-28 14:54:55 +02:00
parent c2c2047dcf
commit b69387e49f

View File

@ -6,6 +6,7 @@ from __future__ import print_function
import argparse import argparse
import glob import glob
import os import os
import pdb
from obspy import read_events from obspy import read_events
@ -157,13 +158,15 @@ def autoPyLoT(inputfile):
# calculating seismic moment Mo and moment magnitude Mw # calculating seismic moment Mo and moment magnitude Mw
moment_mag = MomentMagnitude(corr_dat, evt, parameter.get('vp'), moment_mag = MomentMagnitude(corr_dat, evt, parameter.get('vp'),
parameter.get('Qp'), parameter.get('Qp'),
parameter.get('rho'), True, 0) parameter.get('rho'), True, \
parameter.get('iplot'))
# update pick with moment property values (w0, fc, Mo) # update pick with moment property values (w0, fc, Mo)
for station, props in moment_mag.moment_props.items(): for station, props in moment_mag.moment_props.items():
picks[station]['P'].update(props) picks[station]['P'].update(props)
evt = moment_mag.updated_event() evt = moment_mag.updated_event()
local_mag = RichterMagnitude(corr_dat, evt, local_mag = RichterMagnitude(corr_dat, evt,
parameter.get('sstop'), True, 0) parameter.get('sstop'), True,\
parameter.get('iplot'))
for station, amplitude in local_mag.amplitudes.items(): for station, amplitude in local_mag.amplitudes.items():
picks[station]['S']['Ao'] = amplitude.generic_amplitude picks[station]['S']['Ao'] = amplitude.generic_amplitude
evt = local_mag.updated_event() evt = local_mag.updated_event()
@ -207,13 +210,15 @@ def autoPyLoT(inputfile):
# calculating seismic moment Mo and moment magnitude Mw # calculating seismic moment Mo and moment magnitude Mw
moment_mag = MomentMagnitude(corr_dat, evt, parameter.get('vp'), moment_mag = MomentMagnitude(corr_dat, evt, parameter.get('vp'),
parameter.get('Qp'), parameter.get('Qp'),
parameter.get('rho'), True, 0) parameter.get('rho'), True, \
parameter.get('iplot'))
# update pick with moment property values (w0, fc, Mo) # update pick with moment property values (w0, fc, Mo)
for station, props in moment_mag.moment_props.items(): for station, props in moment_mag.moment_props.items():
picks[station]['P'].update(props) picks[station]['P'].update(props)
evt = moment_mag.updated_event() evt = moment_mag.updated_event()
local_mag = RichterMagnitude(corr_dat, evt, local_mag = RichterMagnitude(corr_dat, evt,
parameter.get('sstop'), True, 0) parameter.get('sstop'), True, \
parameter.get('iplot'))
for station, amplitude in local_mag.amplitudes.items(): for station, amplitude in local_mag.amplitudes.items():
picks[station]['S']['Ao'] = amplitude.generic_amplitude picks[station]['S']['Ao'] = amplitude.generic_amplitude
evt = local_mag.updated_event() evt = local_mag.updated_event()