Crash in ClassifyPixels

I get a crash when I run ClassifyPixels using the attached classifier from ilastik in CellProfiler 2.1.0 (rev a7839af and rev 0c7b94). In CP 2.0 it works fine.
ClassifyPixelsCrash.zip (274 KB)

Hi,

The PNG image supplied is actually RGB. Once you choose “Color image” in NamesAndTypes and then use a ColorToGray module, the pipeline works fine. (see my attached pipeline)

Even though the image looks grayscale, my first indication that it was not was when I mouse over the image, the intensity values at the bottom of the CellProfiler window reported RGB and not just a single intensity plane. I confirmed it in FIJI just to be sure. Of course, it would be better if you save a single channel image to begin with and run ilastik on that so that it doesn’t have to load in 3x as much data, and the same goes for CP, but that depends on your workflow.

In any case, I’ll file a Github issue to have ClassifyPixels warn the user if the training was done on a multi-plane image and ClassifyPixels has a grayscale image as input.
Cheers,
David
DLproj.cpproj (290 KB)

Thanks, David. That makes sense.
/Petter