Reversed changes made in previous commit, initialize ObsPy-event object including path.

This commit is contained in:
Ludger Küperkoch 2017-08-17 12:31:42 +02:00
parent ea7b609091
commit 24ded1cf2b
3 changed files with 3 additions and 2 deletions

View File

@ -201,6 +201,7 @@ def autoPyLoT(input_dict=None, parameter=None, inputfile=None, fnames=None, even
filename = os.path.join(eventpath, 'PyLoT_' + evID + fext)
try:
data = Data(evtdata=filename)
data.get_evt_data().path = eventpath
print('Reading event data from filename {}...'.format(filename))
except Exception as e:
print('Could not read event from file {}: {}'.format(filename, e))

View File

@ -228,8 +228,9 @@ class Data(object):
else:
evtdata_org = self.get_evt_data()
picks = evtdata_org.picks
eventpath = evtdata_org.path
picks_copy = copy.deepcopy(picks)
evtdata_copy = Event(fnout)
evtdata_copy = Event(eventpath)
evtdata_copy.picks = picks_copy
# check for stations picked automatically as well as manually

View File

@ -291,7 +291,6 @@ def autopickstation(wfstream, pickparam, verbose=False,
if algoP == 'HOS':
# calculate HOS-CF using subclass HOScf of class
# CharacteristicFunction
print(cuttimes)
cf1 = HOScf(z_copy, cuttimes, thosmw, hosorder) # instance of HOScf
elif algoP == 'ARZ':
# calculate ARZ-CF using subclass ARZcf of class