FilterObjects error when no objects present

Hello, I am trying to remove cells that touch each other using FilterObjects based on neighbor touching percentage of secondary objects. Some of my images are quite sparse or do not contain any cells (and therefore objects) at all. When such an image (with no objects) is input for FilterObjects, there is an indexing error and pipeline breaks down. Is there any way to have FilterObjects “skip” images where there are no objects, or some workaround? I have 3000+ images so it would be tedious to manually delete images without cells, or images with only cells at the image borders, which I remove in the IdentifyPrimaryObjects and IdentifySecondaryObjects.

Any help would be appreciated!

Thanks,
Simon

Hi Simon,

You might want to give the FlagImage module a try. It allows you to set a flag based on a measurement criteria that you specify (e.g., object count = 0) and lets you skip the rest of the modules for that processing cycle if the criteria is met. The key is place the FlagImage module before the filtering step.

Would you mind posting your pipeline and an example image set where this error occurs? It would be good to find out whether it’s been corrected in our code since the release a few years back!

Regards,
-Mark