Batch measuring artefacts

Hi,
I have never used ImageJ before and have a couple of thousand images similar to the example attached. The original images are in colour and quite detailed taken at various magnifications between 15x-25x.
I am wondering if it is possible to batch measure a number of features in the image, such as:

  1. x and y axis measurements (white area, the artefact)
  2. surface area of artefact (non-black area)
  3. best fit for a circle centred on central black hole.

As I have yet to start using ImageJ I was not sure how to search the forum for this info.

Regards
Tim

Threshold the image, see:

http://imagej.net/docs/guide/146-28.html#toc-Subsection-28.2

Set the measurements you are interested in:

http://imagej.net/docs/guide/146-30.html#toc-Subsection-30.7

Then use the Particle Analyze function in ImageJ to measure the different areas, etc. Seperate the different areas with the options to measure only particle with, e.g., roundness x and size y:

http://imagej.net/docs/guide/146-30.html#toc-Subsection-30.2

Record your analyzing steps in the Macro recorder:

http://imagej.net/docs/guide/146-31.html#toc-Subsection-31.1

Apply your macro on a bunch of images with the Batch macro:

http://imagej.net/docs/guide/146-29.html#toc-Subsection-29.12

Here as an example a small macro which measures the circle area and shows an elliptical fit (for simplification I convert the image to 8-bit) :

run("8-bit");
setAutoThreshold("Default");
//run("Threshold...");
run("Set Measurements...", "area fit redirect=None decimal=3");
run("Analyze Particles...", "size=400-Infinity circularity=0.60-1.00 show=Ellipses display");

Create your own macro to include all other measurements!

5 Likes

Hi Bio7

Thanks for the response. I’ll read the links and see if I can get an understanding of it all.
I appreciate the time you have taken to respond.

Regards
Tim

Hello Tim,

you will also find some useful tutorials on the ImageJ site:

http://imagej.net/User_Guides

and YouTube:

1 Like

To fit the Circle, see also:

http://imagej.net/docs/guide/146-27.html#sub:Fit-Ellipse

1 Like

Thanks Bio7,

Do you think many of these processes can be done in batches (automated as it were), or will they need to be applied separately to individual images?

I will begin to read through all the links you gave me, they look to be very helpful.

Tim

You can create one macro (use the macro recorder do get the commands easily) with all your measurements.

Threshold, measure circle, threshold again, measure the white area, theshold and measure the grey area (artefacts).

The artefacts (in the white area) could also be measured if necessary by substracting the circle+white area from the white area+including the holes (see the Analyze Particles dialog).

You can even save the results or single results with the macro to get a control for the measurements.

Then try to apply it to all images (if all images are similar then it should work for all images)

1 Like

In addition to the excellent comments by @Bio7, I can recommend using KNIME to process large datasets, as it makes batch processing really easy.

2 Likes

Thanks Jan,

What a helpful forum, I will have a look at KNIME, as the datasets are quite large. There are over 2500 samples and multiple views to measure, with various parameters to deal with.
My background is in CAD and Graphics on Mac, so I’m not familiar these programs or the coding.

I am asking the questions for my daughter who is studying the artefacts (archaeological samples).
Thanks again to yourself and Bio7 for the input.

Regards
Tim

2 Likes