summaryrefslogtreecommitdiff
path: root/gr-blocks/python
diff options
context:
space:
mode:
authorrear1019 <rear1019@posteo.de>2020-04-13 17:03:41 +0200
committerMartin Braun <martin@gnuradio.org>2021-01-11 08:57:22 -0800
commitfc6d5cb82007dfe6f75984d33660b1bfa73e9150 (patch)
tree54017bf83ffccf64b7acabd82cdda357955dc4c7 /gr-blocks/python
parent97c6fe790c8f93490775357f4595a41b404e9ba8 (diff)
peak_detector2: Make the recently added test case fail
Diffstat (limited to 'gr-blocks/python')
-rw-r--r--gr-blocks/python/blocks/qa_peak_detector2.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/gr-blocks/python/blocks/qa_peak_detector2.py b/gr-blocks/python/blocks/qa_peak_detector2.py
index d31b8ad146..8650bb86bb 100644
--- a/gr-blocks/python/blocks/qa_peak_detector2.py
+++ b/gr-blocks/python/blocks/qa_peak_detector2.py
@@ -119,15 +119,15 @@ class test_peak_detector2(gr_unittest.TestCase):
#print "\n\nTEST 5"
tb = self.tb
- data = [0, 1, 3, 7, 5, 2, 1, 0]
- alpha = 0.1
+ data = [0, 0, 0, 10, 0, 0, 0, 0]
+ alpha = 0.25
expected_result_peak = [0, 0, 0, 1, 0, 0, 0, 0]
expected_result_average = [0]
for i in data:
expected_result_average.append(expected_result_average[-1] * (1 - alpha) + i * alpha)
src = blocks.vector_source_f(data, False)
- regen = blocks.peak_detector2_fb(3.0, 2, alpha)
+ regen = blocks.peak_detector2_fb(2.0, 2, alpha)
dst = blocks.vector_sink_b()
avg = blocks.vector_sink_f()