Probability maps cannot be converted - Threshold and Size Filter not working

Sample image and/or code

Background

image type EM image.

Analysis goals

I want to try if it is possible to detect single synaptic vesicles from electron microscope (EM) images.

Challenges

I used the cell density counting algorithm as a first step to try to detect synaptic vesicles from electron microscope images (since they are fairly homogeneous in shape and size).
I trained it and then I tested on another image by creating and exporting a probability map for that other image.
To distinguish the single objects I then turned to the object classification workload and uploaded the probability map along with the raw image. As far as I understood the following step would be to binarize the image using the Threshold and Size Filter “function”. I tried it but it didn’t work. Since I am familiar with Pyhton I loaded the probability map there and noticed that the pixel values (0-1 range) were very, very low, with the maximum one being just above 0.005. Since, as far as I understood, I can turn down the threshold to a minimum value of 0.01 it is likely that the reason why the threshold is not having any effect on the probability map is that it is above the maximum value of it. Am I right or am I missing something? If my hypothesis is true, is there nevertheless a way to get the image binarized with Ilastik despite the very low pixel values? Could the relatively low signal-to-noise ratio of EM images be the reason of the very low values?

Thanks a lot for any feedback

Barbara

Hi @Imbrosci,

welcome to the forum!

The results of the counting workflow are not meant to be used in pixel classification. While it says “probabilities” in the export applet, the image that is exported is the density image. Also it is only suitable for circular objects and it is also assumed that the size is the same. (Thank you for pointing it out! I have openend an issue to keep track of that.)

I’m pretty sure that the Pixel Classification is what you are after. You can use it to find the pixels that belong to synaptic vesicles. With the probability map from pixel classification you can go into object classification.

Cheers
Dominik

Thanks a lot for the clarification. I tried with the Pixel Classification but since vesicles are indeed rather uniform in size and shape the Cell Density Counting turned out to work better. I just modified the density to probability with few lines of codes in Python and with the probability I could then continue with the Object Classification!
Best
Barbara