CellProfiler segmentation of DAPI and GFP

Hi! I’m creating a pipeline to quantify transfection efficiency by comparing the number of GFP+ to total cells (DAPI). The outline of my pipeline is set up, but I’m having trouble getting my segmentation accurate and robust enough for general use.

In brief, I count DAPI and GFP cells with IdentifyPrimaryObject modules, relate the two with nuclei as the child, then filter out nuclei without GFP+ parents. However, my segmentation of both DAPI and GFP+ cells isn’t always accurate/consistent across different images (especially since the percentage and intensity of GFP+ cells can vary greatly between images).

Any advice about settings in IdentifyPrimaryObjects for DAPI and GFP+ cells, or other modules that could help, would be greatly appreciated! Thanks!

Pipeline:
TransfectionForum_DAPI1_GFP1_10x.cpproj ! (84.9 KB)

Image set that works well
2114_1_10x_d_30_1_7.02.20|666x500

!

Counts DAPI well, ‘oversegments’ GFP:
2120_1_10x_d_30_1_7.02.20|666x500

!

Counts DAPI well, ‘undercounts’ GFP (there are faint cells it doesn’t count. This sometimes happens with DAPI as well)
2120_1_10x_d_30_2_7.02.20|666x500

Hi @EmilyP,

When looked at the pipeline,
For DAPI, to avoid over segmentation you could try reducing the declumping smooth filter, it might help.
It sometimes challenge to get the weak signal segmented correctly especially when your difference between Background & signal is low. You could try some illumination correction or rescale intensity might help. Also, in case of GFP image segmentation, you should increase the maximum diameter (for ex. 500) I think. In addition, may be you try “Robust Background” threshold method as well.
Hope this helps.

Regards,
Lakshmi
www.wakoautomation.com

A much easier workflow if literally all you care about is transfection efficiency (and not cell size/shape) would be to just call Nuclei as objects, not also cells, Threshold the GFP channel, then use the “MaskObjects” module in “Remove based on overlap” mode to say you only want to call Nuclei that overlap with GFP+ areas more or less than some arbitrary cutoff amount (the default 50% is a good place to start). It is fewer steps, and you have more options to say, set GFP thresholding strict and require a not huge-fraction of the nucleus to call as +, OR set GFP thresholding much more loosely than otherwise but make most of the nucleus be positive to truly call it a positive nucleus.

1 Like

Hi Beth!
Thanks for the idea! That seems like a lot simpler way to do it. Potentially basic question - how should I then set up ‘CalculateMath’ to get the efficiency? I tried with these settings, but I’m getting an efficiency of 100 even though only a fraction of nuclei/GFP overlap (based on ‘MaskObjects’ and just looking at the pictures)

Thanks!!

What I typically suggest to users with similar questions:

  • segment the nuclei (IdentifyPrimaryObjects)
  • expand the nuclei a bit to define cell objects (IdentifySecondaryObjects - Distance-N), call these objects cells
  • MeasureObjectIntensity of GFP in nuclei and cell objects
  • Export all the measuerements
  • Do the analysis using the exported Object tables (ideally using something like Python or R, but Excel will do).

You can then use the IntegratedIntensity measurement for the cells to determine how much GFP is in each cell. If you set a threshold on this value you can split into GFP positive/GFP negative. This way you can set different thresholds for positivity quickly without runnning the whole pipeline.

Note that this is just a coarse outline, you should also subtract the background intensity in GFP before measuring intensity and adjust for uneven illumination if necessary.

1 Like

That is a super good way to go as well, Volker, and gives you much more flexibility downstream, though sometimes having a quick in-pipeline-headcheck number is nice, so it doesn’t hurt to do both :slight_smile:

Emily, without your updated pipeline I can’t see why you’re always getting 100% there, can you upload?

Here’s the updated pipeline based on Beth’s suggestion: testBethsIdea.cpproj (80.4 KB)

I’m assuming I just set up calculateMath incorrectly, or need some type of measure module to count things first?

Thanks!
(Also thanks Nasim for the help at office hours!)