From 606ed2960238d1d28ec777adacb0209f9563c032 Mon Sep 17 00:00:00 2001 From: Guillaume Pellerin Date: Thu, 31 Oct 2013 22:50:00 +0100 Subject: [PATCH] add parent list iterating in pipe, fix analyzer.odf results --- timeside/analyzer/odf.py | 2 +- timeside/core.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/timeside/analyzer/odf.py b/timeside/analyzer/odf.py index 06c91ae..fab3e70 100644 --- a/timeside/analyzer/odf.py +++ b/timeside/analyzer/odf.py @@ -70,7 +70,7 @@ class OnsetDetectionFunction(Analyzer): def post_process(self): #spectrogram = self.parents()[0]['spectrogram_analyzer'].data - spectrogram = self.pipe._results['spectrogram_analyzer'].data + spectrogram = self.pipe.results['spectrogram_analyzer'].data #spectrogram = self.pipe._results[self.parents()[0].id] # Low-pass filtering of the spectrogram amplitude along the time axis diff --git a/timeside/core.py b/timeside/core.py index b88bcea..2e95410 100644 --- a/timeside/core.py +++ b/timeside/core.py @@ -252,7 +252,10 @@ class ProcessPipe(object): def __ior__(self, other): if isinstance(other, Processor): - self |= other.parents + parents = other.parents + if parents: + for parent in parents: + self |= parent self.processors.append(other) elif isinstance(other, ProcessPipe): self.processors.extend(other.processors) -- 2.39.5