Grain size analysis

Hello all!

I am new to ImageJ/Fiji, so please bear with me! I am interested in analyzing grain size of some SEM images:

There are many ImageJ tutorials out there that make use of Image > Adjust > Threshold and then Analyze > Analyze particles in order to select the distinct grains. I find that this method is only good for round particles, and not for grains with very rough edges and overlapping like my SEM samples.

Here is the image after making use of Analyze Particle: As you can see, this tool cannot select any of my grains.

I have also tried the Trainable Weka Segmentation on more “defined” particles/grains as follows:
Original image and one of the probability maps, as well as the overlay results
865-FX1-1E_0002.tif (8.1 MB)


I am unable to make use of Analyze particle to measure the grain size, so any advice or plugin recommendations will definitely be helpful.

Thanks so much for your time!

@asdfg

Wait - so are you happy with your segmentation results then? At least with Trainable Weka?

For calculating grain size - I’m assuming an area measurement would be sufficient in your case… so just go to Set Measurements and select those parameters you wish to measure.

To perform measurements you need to turn the results of the Weka Segmentation into a binary mask like so:

Press get Results to get a 8-bit RGB image. Each color denoting a specific class e.g. foreground and background. You can turn this into a 8-bit greyscale image by:
Image > Type > 8-bit.

Each class gets a specific grey value. Which you can then threshold:
Image > Adjust > Threshold…

This turns the image then in a binary mask that allows you to use the Particle Analyzer.

Alternatively by pressing “Get probability” you get a back at 32-bit greyscale image that is a the probability map for the segmentation. This you could theoretically segment for a specific probability threshold again generating a binary mask.

I would urge some caution here. I’ve seen a lot of SEM images like this from agglomerated colloidal particles. There are some very small particles in the original image. Do they count as “a grain”? Without knowledge of the composition of the sample and how it was prepared (e.g. dried on a substrate or a fracture surface) it is hard to decide if the results make sense for the material.

Thanks so much! I know the sample composition, but you are right regarding the issue whether small particles being counted as a grain.
I imagine that this issue will be resolved with EDX along with SEM, unfortunately we do not have such equipment. I was thinking of using an area cutoff after obtaining the particle size since I have some idea of the size of the “necessary” particles.
If you have any alternatives, please let me know!

Hello @asdfg and @John_Minter,

just for my information, what do you mean by “grains” in your image? The black areas? I’m not a specialist but they look like pores to me. If it’s really the black areas, then the segmentation provided by the Weka plugin is ok, and the first segmentation, too. You just need to analyse the black particles, not the white ones (after removing the scale bar, off course).

I suggest optimizing the specimen preparation and imaging conditions before final optimization of the image analysis.

Can you prepare a more dilute preparation with less agglomeration? For colloidal particles we used 5x5 mm Si chips Ted Pella #16008 plasma-ashed in air (in our 1980 vintage “standard” plasma asher) or - later - in our Gatan Solarus plasma asher with a H2/O2 gas mixture. This treatment produced a wetable surface for deposition from a suitable solvent.

Getting colloidal particles well-dispersed is often challenging even when the solvent wets the substrate. We had some success with a glass nebulizer
Ted Pella #14601. There are now commercial electrospray devices that do a great job; I wanted one but the lab could not afford it… Our best dispersion came from depositing on ashed Si chips in a Beckman Airfuge.

Once the prep is optimized, perhaps consider recording images with a higher magnification so the smaller grains are better sampled in the image. Depending upon the polydispersity of the particle area you may need to record images from many fields to get reliable statistics. We typically included the Shape descriptors in the Set Measurement dialog.

I’d like to share with you something my Ph. D. advisor, Prof. E. L. Thomas, taught me from my first day: That I should be the biggest skeptic regarding my image/data analysis. One of the first documents he gave me was an excerpt from Henry Baker’s book “The Microscope Made Easy” (1743). I suspect that Baker learned this the hard way. I sure did on a couple of occasions when I ignored his advice…

The quote below comes from pages 62 and 63. I changed the case of some words for modern English usage.

Beware of determining and declaring your opinion suddenly on any object; for imagination often gets the start of judgment and makes people believe they see things which better observations will convince them could not possibly be seen: therefore assert nothing til after repeated experiments and examinations in all lights and all positions.

When you employ the microscope, shake off all prejudice, nor harbor any favorite opinions; for, if you do, 'tis not unlikely fancy will betray you into error, and make you see what you wish to see.

Remember, that truth alone is the matter you are in search after; and if you have been mistaken, let not vanity seduce you to persist in your mistake.

Pass no judgment upon things over-extended by force or contracted by dryness or in any manner out of their natural state without making suitable allowances.

Nicholas, I can’t be sure either. I have seen fracture surfaces and dried colloidal particles that look like this. I can make some guesses from the data bar, but they are just that - guesses… I’m hoping @asdfg gives us a bit more information.

Hello @Nicolas and @John_Minter
Unfortunately, these are images that I have received; I am not involved at all in sample prep… But thanks so much for the words of advice! Will definitely keep that in mind when I actually do prep work. My apologies for not being able to provide more information about this sample.

@Nicolas sorry for how unclear I was in describing what was happening. I’ve circled some of the grains from the second image that are grains to be analyzed.

Hello @asdfg,

it appears that your problem is a little bit more complicated than you expected. Actually, you won’t find any plugin that will do the job automatically unless you first find a way to clearly describe the characteristics of your grains.
Your first attempt resulted in discriminating the bright and dark regions, but it appears this is not what you need, since small voids can be included in the grains.
So, the main question is: How would you describe your grains? Regions with approximately uniform brightness, but with smaller dark regions inside? And what with the regions with fine dark and bright regions which look like foam (e.g. bottom left)? Grains or not ?
Last question: what did you expect on the second image (close-up view)?
Once you you have answered these questions, you can train the Weka classifier with proper objects, or try to find pre-processing operators, e.g. for discriminating approximately uniform regions versus textured ones, then applying binarization.

But, if all of this seems complicated and if you only have a few images to process, and only need an average value, I suggest you perform your task manually:

  • draw a set of horizontal / vertical lines, or circles with varying diameters on the image (use the ROI manager),
  • count the number of intersections with the grain boundaries (that you’ll identify yourself),
  • and divide it by the linear length.

That’ll give you an average diameter, ASTM old style ;).
And you’ll get the results in a matter of 1/2h.
In the image you provided I’m not sure you have enough grains to make a sound statistical evaluation, but some ASTM norm can tell you that.
Good luck!