Skip to content

Commit

Permalink
MAINT: Allow 'None' segmentation to turn off segmentations.
Browse files Browse the repository at this point in the history
  • Loading branch information
jwboth committed Jun 12, 2024
1 parent 7548712 commit 1e993aa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/darsia/presets/fluidflower/simplefluidflower.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,10 @@ def setup(
self.baseline = correction(self.baseline)

# ! ---- SETUP SEGMENTATION ----
self.labels = self.setup_segmentation(segmentation)
if segmentation is None:
self.labels = darsia.zeros_like(self.baseline, dtype=np.uint8)
else:
self.labels = self.setup_segmentation(segmentation)

# ! ---- SETUP COLOR CORRECTION ----
illumination_mode = kwargs.get("illumination_mode", "automatic")
Expand Down

0 comments on commit 1e993aa

Please sign in to comment.