diff --git a/dap/algos/aggregation.py b/dap/algos/aggregation.py index ae83523..3b10789 100644 --- a/dap/algos/aggregation.py +++ b/dap/algos/aggregation.py @@ -5,6 +5,7 @@ from .thresh import threshold def calc_apply_aggregation(results, data, pixel_mask_pf, aggregator): + calc_apply_threshold(results, data) # changes data in place data = calc_data(results, data, aggregator) calc_mask_pixels(data, pixel_mask_pf) # changes data in place aggregation_ready = calc_aggregation_ready(results, data, aggregator) @@ -17,16 +18,10 @@ def calc_data(results, data, aggregator): return data apply_aggregation = results.get("apply_aggregation", False) - apply_threshold = results.get("apply_threshold", False) if not apply_aggregation: aggregator.reset() - if not apply_aggregation and not apply_threshold: - return data - - calc_apply_threshold(results, data) # changes data in place - return calc_aggregate(results, data, aggregator)