Hi shaurya,
you can give a try with the lines of code below (macro language).
Here is a link to the result I got on the first image you provide us with :
https://dl.dropboxusercontent.com/u/22602328/shauryaTest.jpg
Cheers,
Romain
title = getTitle();
sigma = 2; // GaussianBlur radius
selectImage (title);
run("Duplicate...", "title=blurpx");
run("Gaussian Blur...", "sigma="+sigma);
selectImage (title);
run("Duplicate...", "title=blur1.6px");
sigma16 = 1.6*sigma;
run("Gaussian Blur...", "sigma="+sigma16);
// difference of Gaussian Blur images
imageCalculator("Subtract create 32-bit", "blur1.6px","blurpx");
// set a threshold
setAutoThreshold("Default");
setOption("BlackBackground", true);
run("Convert to Mask");
rename(title+"mask");
// set some output, Major and minor axis length , etc
run("Set Measurements...", "area perimeter fit shape limit display redirect=None decimal=3");
// analyze particles inside the image
run("Analyze Particles...", "size=10-Infinity display exclude clear add");
// if you process-> batch this code , comment the line above and uncomment the one below to keep results over images
// run("Analyze Particles...", "size=10-Infinity display exclude add");
---------------------------------------------------------------
Dr. Romain Guiet
Bioimaging and Optics Platform (PT-BIOP)
Ecole Polytechnique Fédérale de Lausanne (EPFL)
Faculty of Life Sciences
Station 19, AI 0140
CH-1015 Lausanne
Phone: [+4121 69] 39629
http://biop.epfl.ch/
---------------------------------------------------------------
________________________________________
De : ImageJ Interest Group [[hidden email]] de la part de shauryasachdev [[hidden email]]
Envoyé : samedi 7 février 2015 19:56
À : [hidden email]
Objet : Object Detection, Length Detection
Hi,
I have a sequence of images and I want to detect length or elongation of the
objects in it. For reference I have attached the images below.
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X114.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X144.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X185.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X585.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X360.jpg>
And what I want from these images is the length of the elongated objects in
it. The problem is that there are a lot of out of focus objects that are
corrupting the image and they should somehow be removed or not be detected.
To explain better I am attaching the same images below but with and
indication of what to be detected and what not to be detected. The lines and
the sharp dots are what I want and the objects in the circle are what I
DON'T want.
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X114_changed.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X144_changed.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X185_changed.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X360_changed.jpg>
<http://imagej.1557.x6.nabble.com/file/n5011503/25_nov_14_63x_512x512_4x4_126fps_1_1000_X585_changed.jpg>
These images above belong to a sequence of images or a video and I want to
record the elongation of the objects in the video that are sharp (or in
focus) and discard the ones that are blurred (or out of focus).
Is there any way I can go about doing this job? I have tried a few filters
but they work for some images and not for all. I also have the video for
this event and if it might be better to work on the video then I can post
that as well.
Thanking you for your help and kind consideration.
Regards,
Shaurya
--
View this message in context: http://imagej.1557.x6.nabble.com/Object-Detection-Length-Detection-tp5011503.html
Sent from the ImageJ mailing list archive at Nabble.com.
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html
If you reply to this email, your message will be added to the discussion below:http://imagej.1557.x6.nabble.com/Object-Detection-Length-Detection-tp5011503p5011581.html
Free forum by Nabble | Disable Popup Ads | Edit this page |