From: Josh Blum Date: Mon, 12 Oct 2009 22:44:17 +0000 (-0700) Subject: simplfied the code while i was looking at it X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=4fad7bd5a431a113bf66459b8b4c7536671c9c14;p=debian%2Fgnuradio simplfied the code while i was looking at it --- diff --git a/gnuradio-core/src/python/gnuradio/blks2impl/stream_to_vector_decimator.py b/gnuradio-core/src/python/gnuradio/blks2impl/stream_to_vector_decimator.py index 39c8b505..8f75729c 100644 --- a/gnuradio-core/src/python/gnuradio/blks2impl/stream_to_vector_decimator.py +++ b/gnuradio-core/src/python/gnuradio/blks2impl/stream_to_vector_decimator.py @@ -72,8 +72,7 @@ class stream_to_vector_decimator(gr.hier_block2): self.one_in_n.set_n(self._decim) def _update_decimator(self): - self._decim = max(1, int(round(self._sample_rate/self._vec_len/self._vec_rate))) - self.one_in_n.set_n(self._decim) + self.set_decimation(self._sample_rate/self._vec_len/self._vec_rate) def decimation(self): """