fixed pickprops for empty picks
@@ -3437,6 +3437,7 @@ class View(QtGui.QLabel):
no_locs = np.empty(len(picked_locs))
for i, pick_locs in enumerate(picked_locs):
no_locs[i] = len(pick_locs)
+ if no_locs[i] > 0:
if not hasattr(pick_locs, 'len'):
pick_locs = postprocess.link(pick_locs, self.infos[channel], r_max=r_max, max_dark_time=max_dark)
pick_locs = postprocess.compute_dark_times(pick_locs)
@@ -3897,8 +3898,8 @@ class View(QtGui.QLabel):
for j in range(len(self._picks)):
for k in range(len(groups)):
x_pick, y_pick = self._picks[j]
- for m in range(len(shift_x)):
- self._picks.append((x_pick+shift_x[m],x_pick+shift_y[m]))
+ self._picks.append((x_pick+shift_x[k], y_pick+shift_y[k]))
+
self.n_picks = len(self._picks)
self.update_pick_info_short()
