From cf05db611d22ddc0f482cf9ea2ace88c424ddfcf Mon Sep 17 00:00:00 2001 From: Leonardo Schwarz Date: Thu, 24 Oct 2024 16:22:16 +0200 Subject: [PATCH] update --- .../methods/calibration_method_global_constant_shift.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/depiction/calibration/methods/calibration_method_global_constant_shift.py b/src/depiction/calibration/methods/calibration_method_global_constant_shift.py index efa5786..4431995 100644 --- a/src/depiction/calibration/methods/calibration_method_global_constant_shift.py +++ b/src/depiction/calibration/methods/calibration_method_global_constant_shift.py @@ -35,9 +35,11 @@ def preprocess_image_features(self, all_features: MultiChannelImage) -> MultiCha n_spectra = all_features.n_nonzero return MultiChannelImage( data=DataArray( - np.full((n_spectra, 1, 1), global_distance), dims=["y", "x", "c"], coords=all_features.coords + np.full((n_spectra, 1, 1), global_distance), dims=["y", "x", "c"], coords=all_features.coordinates_flat + ), + is_foreground=DataArray( + np.ones((n_spectra, 1), dtype=bool), dims=["y", "x"], coords=all_features.coordinates_flat ), - is_foreground=DataArray(np.ones((n_spectra, 1), dtype=bool), dims=["y", "x"], coords=all_features.coords), ) def fit_spectrum_model(self, features: DataArray) -> DataArray: