Nd2 file processing in cellprofiler (multi point z-stacks, grouping, IdentifyPrimaryObjects))

Dear all,
I try to analyse files recored with Nikon NIS and the Jobs extension. I read in a 96 well plate with 25 positions per well, 5 z sections and 3 colors. NIS Elements gives me all the images from one well in one nd2 file.
When I add these files to CP I extract informations by Metadata (Extract from image file header) and this looks fine:

Each position is labelled by “Series” and consists of 15 images (3 channels, 5 z-positions).
In the next step I assign the channels based on the channels name. This also works fine.

In a next step I define groups based on the series metadata column:

This looks fine to me as well. I get 25 groups

Then I want to do a maximum projection of the individual channels based for each group and identify primary objects (cell nuclei).

When I now run this pipeline with a test image, I realised that the input image and the result images do not correspond in the identify primary object output.

When I move to the “Next image Set” The input image stays the same, but the IdentifyPrimaryObject window changes.
Do I anything wrong? Is there an error with the grouping?
Attached is the pipeline, the input image is rather large.
nd2_multipooint_well.cpproj (1.9 MB)
Thanks for the help,

Hi @alexra

You’ve done everything correct with regards to the input of your images, all looks great! However, an important thing to know is that you will not be able to “access” your projection in the same pipeline as the processing as it’s not created until the end of the pipeline for each group.

The below quote is taken from the MakeProjection module part of CellProfiler manual

Keep in mind that the projection image is not immediately available in subsequent modules because the output of this module is not complete until all image processing cycles have completed. Therefore, the projection should be created with a separate pipeline from your analysis pipeline.

So what you need to do is have a pipeline with your MakeProjection modules per channel, then a SaveImage module to save each projection and then have a second pipeline that will do the segmentation and analysis.

This has been discussed a few times on the forum before

So what you were seeing clicking “Next Image Set” you were just loading the next Z-slice for that image, that’s why it looked so similar and you thought it wasn’t selecting a new one.

Additionally, I’m sure your input image and the result image “match” but that the settings for IdentifyPrimaryObjects are making you think they are not because it is picking up very low signal areas. If you make your projection images first and then try again and get stuck then feel free to come back to the forum and ask for more help.

Good luck!


Hi Laura,
thanks for the reply,
I will test your suggestions. Sorry for not looking in the manual.

1 Like