Calculating features on an image, based on a separate tracked labelling

Hello everyone,

I am using the ImageJ extension in KNIME to do some chromatin image analyses. The goal is to measure both the nucleus volume and chromatin volume of a cell. I have managed to use simple thresholding to generate nucleus and chromatin binary images. Eventually I will be doing this on a field image of multiple cells so I have also used Trackmate tracker to track the nuclei and chromatin.
Here is a table where I have the nucleus image and tracking (label) and the chromatin image and tracking. For now, please focus on the nucleus on the left.

My issue is that the chromatin stain within a nucleus can be discontinuous (a feature of the biological phenomenon Iā€™m studying), and therefore identified by the tracker as separate objects. Since my goal is to have the nucleus and chromatin volume of a cell, how do I make KNIME recognise that, say, chromatin objects 1, 2, 3, all belong to the same nucleus (e.g. nucleus 1)?

I have tried using Image Segment Features, using nucleus track for ā€˜Labellingā€™ and the thresholded binary chromatin image for ā€˜Imageā€™, selecting numpix in Features, and checking the boxes for ā€˜Append labels for overlapping segmentsā€™ & ā€˜Overlapping segments do not need to completely overlapā€™. However, the result in ā€˜Calculated Features tableā€™ is still the nucleus volume, not the chromatin volume.
Based on a this thread (Feature Calculator) it seems that Iā€™m using the right node for what I want to do. Would anyone have any suggestions?
Thank you!

Hi @rquincy,

I get the idea behind your approach, namely that you only want to take into account the positive pixels from the binary mask. This approach, however, is currently not supported since the Num Pix feature computation is based on the labeling only.

Therefore, you should use the Labeling Arithmetic node in order to AND the tracked nucleus and the chromatin. The AND operation will assign the label from the first labeling to a pixel iff a label is assigned in both images. This will effectively assign the label from the nucleus labeling to all pixels in the chromatin labeling. Computing Num Pix on the output will compute the pixel number for the chromatin labeling grouped by the nucleus labeling.

Best regards,