From d9777eaa05573355ed252ed6e7fbb041c5b6f5e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludger=20K=C3=BCperkoch?= Date: Mon, 17 Jun 2019 17:26:23 +0200 Subject: [PATCH] Take into account seismograms too short for given cut times! --- pylot/core/pick/charfuns.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pylot/core/pick/charfuns.py b/pylot/core/pick/charfuns.py index 94483df9..acb5a335 100644 --- a/pylot/core/pick/charfuns.py +++ b/pylot/core/pick/charfuns.py @@ -158,6 +158,8 @@ class CharacteristicFunction(object): zz = self.orig_data.copy() z1 = zz[0].copy() zz[0].data = z1.data[int(start):int(stop)] + if zz[0].stats.npts == 0: # cut times do not fit data length! + zz[0].data = z1.data # take entire data data = zz return data elif len(self.orig_data) == 2: