From bd2c6e3c4e2357a042790d3f55c401c5a13f8d21 Mon Sep 17 00:00:00 2001 From: Peter Swain <peter.swain@ed.ac.uk> Date: Fri, 10 Feb 2023 16:33:08 +0000 Subject: [PATCH] Reverted change of variable name in reduce_extract --- src/extraction/core/extractor.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/extraction/core/extractor.py b/src/extraction/core/extractor.py index f22898a8..c12f581f 100644 --- a/src/extraction/core/extractor.py +++ b/src/extraction/core/extractor.py @@ -347,7 +347,7 @@ class Extractor(StepABC): def reduce_extract( self, - tiles_data: np.ndarray, + traps: np.ndarray, masks: t.List[np.ndarray], red_metrics: t.Dict[reduction_method, t.Collection[str]], **kwargs, @@ -373,11 +373,11 @@ class Extractor(StepABC): """ # create dict with keys naming the reduction in the z-direction and the reduced data as values reduced_tiles_data = {} - if tiles_data is not None: + if traps is not None: for red_fun in red_metrics.keys(): reduced_tiles_data[red_fun] = [ self.reduce_dims(tile_data, method=RED_FUNS[red_fun]) - for tile_data in tiles_data + for tile_data in traps ] d = { red_fun: self.extract_funs( @@ -502,7 +502,7 @@ class Extractor(StepABC): img = None # apply metrics to image data d[ch] = self.reduce_extract( - tiles_data=img, + traps=img, masks=masks, red_metrics=red_metrics, labels=labels, -- GitLab