diff options
author | mormj <mormjb@gmail.com> | 2020-10-30 10:59:50 -0400 |
---|---|---|
committer | Marcus Müller <marcus@hostalia.de> | 2020-10-30 17:52:53 +0100 |
commit | 7a0948ba85758fba1cc3858ef99bfa600dcc7416 (patch) | |
tree | 610d7f9d773a193562def6df2d4b50f1bb3b3f86 /gr-blocks/python/blocks/qa_argmax.py | |
parent | 12192ee7d58de95ddca35a3e93bfc172bdb5c820 (diff) |
qa: run autopep8 formatting on qa python files
find ./ -iname qa*.py | xargs autopep8 --in-place -a -a
mostly formats whitespace and gets rid of trailing semicolons
Diffstat (limited to 'gr-blocks/python/blocks/qa_argmax.py')
-rw-r--r-- | gr-blocks/python/blocks/qa_argmax.py | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/gr-blocks/python/blocks/qa_argmax.py b/gr-blocks/python/blocks/qa_argmax.py index 3aac837c62..70797b330b 100644 --- a/gr-blocks/python/blocks/qa_argmax.py +++ b/gr-blocks/python/blocks/qa_argmax.py @@ -13,6 +13,7 @@ from gnuradio import gr, gr_unittest, blocks import math + class test_arg_max(gr_unittest.TestCase): def setUp(self): @@ -24,9 +25,9 @@ class test_arg_max(gr_unittest.TestCase): def test_001(self): tb = self.tb - src1_data = [0,0.2,-0.3,0,12,0] - src2_data = [0,0.0,3.0,0,10,0] - src3_data = [0,0.0,3.0,0,1,0] + src1_data = [0, 0.2, -0.3, 0, 12, 0] + src2_data = [0, 0.0, 3.0, 0, 10, 0] + src3_data = [0, 0.0, 3.0, 0, 1, 0] src1 = blocks.vector_source_f(src1_data) s2v1 = blocks.stream_to_vector(gr.sizeof_float, len(src1_data)) @@ -48,15 +49,15 @@ class test_arg_max(gr_unittest.TestCase): tb.connect(s2v2, (argmax, 1)) tb.connect(s2v3, (argmax, 2)) - tb.connect((argmax,0), dst1) - tb.connect((argmax,1), dst2) + tb.connect((argmax, 0), dst1) + tb.connect((argmax, 1), dst2) tb.run() index = dst1.data() source = dst2.data() - self.assertEqual(index, [4,]) - self.assertEqual(source, [0,]) + self.assertEqual(index, [4, ]) + self.assertEqual(source, [0, ]) + if __name__ == '__main__': gr_unittest.run(test_arg_max) - |