Determining size and distribution of bubbles

imagej
segmentation
watershed

#1

Hi, I am new to ImageJ and this forum.
I am trying to use ImageJ to analyze bubble size and distribution in water. The picture was taken with high speed camera. My problem are that 1. some bubbles are very close to each other, so after I perform Threshold and Analyze Particles, those bubbles would be counted as one bubble (refer to no.20 and no.32 in the following pics); 2. some bubble has a large shaded area, after I use Analyze Particles, the outline of the shaded area would be counted as a bubble (refer to no.24). For the first problem, I tried to use Watershed, but it didn’t work.

Original picture:

After Threshold and Analyze Particles:


#2

Does it work if you add a rule for the circularity of the particles in analyze particles. You’ll have to test what works but possibly bump up the range from default 0-1 to 0.1-1?


#3

Hi Susan,

Thank you for your advice. I tried it, but it does not work well. I set the circularity to 0.1 - 1, then it could not recognize no.24 and still count no.20 as one bubble.


#4

Welcome to the forum, @TMXK!

Watershed seems ideal here. Did you follow the standard Segmentation workflow?

I briefly tried with your image, and was able to apply watershed to the mask just fine:

Then Analyze Particles on the mask, adding the result to the ROI Manager. Then close the mask, reselect your original image, reset the threshold, tick the Show All option in the ROI manager, and it should look something like this:

Here is a macro I recorded which reproduces the workflow I used for the above picture:

setThreshold(0, 254);
run("Create Mask");
run("Fill Holes");
run("Watershed");
run("Analyze Particles...", "exclude clear add");
close();
resetThreshold();
roiManager("Show All");

#5

Thank you ctrueden!
I really appreciate your help!


#6

Dear friends, I have a similar problem. I want to count the bubbles and analyze bubble size and distribution. Would you please help me to do this with imagej? The picture was taken by highspeed camera. My problem is, there is an impeller interact with the image. The bubbles are not clear enough to detect automatically through filters and sharp edge. Also, when I use watershed all picture become dark. I would appreciate if someone could help me.