cellpose-napari icon indicating copy to clipboard operation
cellpose-napari copied to clipboard

Best way to segment with multiple channels?

Open mat10d opened this issue 10 months ago • 0 comments

Quick question--I am trying to use cellpose-napari, but am working with irregular cell types where including a DNA stain as the nuclear channel for cellpose is essential to get proper segmentations. What is the best way to prepare images for this in Napari? Currently, I have tried two things:

Merge to stack

  1. Loading a multichannel image through drag and drop. This creates three different "layers" in Napari
  2. If we right click all the layers available (3) and "Merge to stack", this creates a "multi-channel" image (meaning that you appear to be able to scroll through the different channels) with an arbitrary color
  3. Cellpose segmentation, setting the correct channel as nuclear, and the correct channel as my cytoplasmic background, then fails:

15:58:29 : ERROR : MainThread : tuple index out of range

Merge to RGB

  1. Loading a multichannel image through drag and drop. This creates three different "layers" in Napari
  2. Setting the three channels to one of red, green, blue (through colormap)
  3. If we right click all the layers available (3) and "Merge to RGB", this creates an apparently "single-channel" image with three different colors (as previously specified, these are red, green and blue)
  4. Cellpose segmentation, setting the correct channel as nuclear, and the correct channel as my cytoplasmic background, then works

This suggests that segmenting a stacked image is not something that is possible in cellpose-napari. Is this accurate?

mat10d avatar Jan 30 '25 21:01 mat10d