Tough Cell Segmentation

The images are DAPI stained nuclei of colorectal origin. As you can see, the cell detection / segmentation is not very accurate. I have played with the cell detection parameters but the results are not improving.

I was wondering if there’s a way to use the cell-membrane stain to improve the segmentation along with DAPI.

QuPath’s built-in cell detection algorithm is very general and doesn’t support using the cell membrane stain. That would require another cell detection method to be added.

QuPath + StarDist is an early example of how this might look:

Alternatively you could try coming up with another method using QuPath + ImageJ:

Or you may be able to construct something with pixel classification:

I suspect all of these will be quite challenging though.

1 Like

The StarDist approach seems promising! Will give it a try. Thanks for the links @petebankhead

1 Like

I used the ImageJ plugin version of the StarDist. I may have to train the network with my data to improve the results. Thanks @petebankhead for directing me to this.

I have another issue now - how do I achieve QuPath-like cell-segmentation in ImageJ after the nuclei are segmented by StarDist? Any suggestion? @uschmidt83

I don’t know what that means :slightly_smiling_face:

1 Like

Currently an “cytoplasmic” expansion of X microns where overlaps are split equal distance from the nuclei.

Not sure why @manaser wouldn’t use StarDist through QuPath in that case, though.

1 Like

Sorry @uschmidt83, I should have explained that; my bad.
@Research_Associate has explained it nicely “cytoplasmic expansion of X microns where overlaps are split equal distance from the nuclei”. To achieve similar thing in ImageJ, I wrote a macro to extend the nucleus boundary generated by StarDist. However, I don’t know how to split the overlap between two extended boundaries - for all cells. The final result would look like the image I posted above. Note, the cells that are correctly segmented has a boundary bigger than the nucleus.

@Research_Associate yes, that might be the best solution. I guess I was just trying to avoid editing scripts. Also, the ImageJ plugin was super quick to implement.

@Research_Associate The “cell expansion and measurement” code in StarDist-QuPath is exactly what I was looking for. Thanks so much.

Just wanted to add a few things for a new user -

  1. Pixel size affected the segmentation - I had to play with it to get acceptable outcome
  2. The code will not run unless the annotation is selected - throws an error
  3. And don’t forget to change the back slashes to forward
    def pathModel = ‘D:/qupath/dsb2018_heavy_augment’
1 Like