Commit 5756aa9c authored by payno's avatar payno
Browse files

[tomoscanbase] add `_get_flats_weights`

# Conflicts:
#	tomoscan/scanbase.py
#	tomoscan/test/test_scanbase.py
parent f54423eb
Pipeline #33243 passed with stages
in 3 minutes and 32 seconds
......@@ -77,6 +77,13 @@ class TestFlatFieldCorrection(unittest.TestCase):
def test_get_flats_weights(self):
"""test the _get_flats_weights function and insure flat weights
are correct"""
projections = {}
for i in range(-2, 30):
projections[i] = numpy.random.random(100).reshape((10, 10))
self.scan.projections = projections
def test_get_flats_weights(self):
flat_weights = self.scan._get_flats_weights()
self.assertTrue(isinstance(flat_weights, dict))
self.assertEqual(len(flat_weights), 32)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment