I am using a simple CellProfiler pipeline to compute the ratio between the area of the nucleus to the total cell area. To do this, I identify primary objects (nuclei), expand them by 40 pixels to determine secondary objects (cells), MeasureObjectSizeShape and compute the ratio [nucleus area]/[cell area] in a CalculateMath module. However, when CellProfiler tries to compute the ratio, I get the error message below (even though areas are positive numbers).
I would appreciate any suggestion on what is causing the problem. The pipeline is attached to this post, as well as sample images.
Encountered error while processing. Do you want to stop processing?
Error while processing CalculateMath:
cannot convert float NaN to integer
Do you want to stop processing?
Traceback (most recent call last):
File “cellprofiler\gui\pipelinecontroller.pyc”, line 932, in do_step
File “cellprofiler\modules\calculatemath.pyc”, line 304, in run
ValueError: cannot convert float NaN to integer
test.cp (8.78 KB)