From 41f0584c8622d8e4c58e66e896e70be75fbcd84e Mon Sep 17 00:00:00 2001 From: Jakub Both Date: Fri, 22 Nov 2024 15:48:18 +0100 Subject: [PATCH] MAINT: Adapt to numbering of heterogeneous labels. --- src/darsia/presets/analysis/multichromatictracer.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/darsia/presets/analysis/multichromatictracer.py b/src/darsia/presets/analysis/multichromatictracer.py index 8e3ba144..d8a35d15 100644 --- a/src/darsia/presets/analysis/multichromatictracer.py +++ b/src/darsia/presets/analysis/multichromatictracer.py @@ -163,9 +163,8 @@ def calibrate(self, colors, concentrations) -> None: concentrations (list): list of concentrations """ - for i, _ in enumerate(darsia.Masks(self.labels)): - - self.model[0][i].update(supports=colors[i], values=concentrations[i]) + for i, (_, label) in enumerate(darsia.Masks(self.labels, return_label=True)): + self.model[0][label].update(supports=colors[i], values=concentrations[i]) def calibrate_from_image( self,