01-13-2014 08:54 AM
Hello,
I'm performing image processing and after some processing steps i get a black and white image with either 1 or none particles. However i like to set a default case if more than one particle arise . As the other particles are due to noise their size will be reduced but still unknown .Hence I thought of extracting the areas of these particles using particle analysis vi of labview through a for loop but i have no idea how to select the particle with the largest area and determine it's center. Can anyone provide a solution for this?
Solved! Go to Solution.
01-13-2014 10:17 AM
Hi Prathiksha,
you may not need for loop. By default particle analysis gives you all particles data.
-What you should do is use particle filter first and then use your filter criteria which can give single particle according to your requirement.
-is it possible to add image?
-There is readily available example which demonstrates this in labview. got to Help>>find examples>>particle filter.
01-13-2014 11:46 PM - edited 01-13-2014 11:47 PM
The main problem is that size of particle of interest can vary rapidly as the images are taken and processed in real-time and occlusions can also be present . It is also not possible to accurately set the minimum or average size of the particle as noises cannot be determined before-hand.
01-14-2014 12:30 AM
I would like the labview program to just compare and extract particle with largest area and find it's center. Is it possible
01-14-2014 12:32 AM
Hello,
how about doing something like this:
I have used "count objects", but you can use any other function that reports the area and object center of the particles.
Best regards,
K
01-14-2014 03:31 AM
Hello,
I understood that we bundled the 2 measures that we need...but i did not understand why the input cluster is outside the for loop? I seem to be getting issues during bundling the 2 measures. What have you given as the input cluster?
01-14-2014 03:54 AM - edited 01-14-2014 03:55 AM
Because the cluster is bundled by name (please see "Bundle by Name" function, see "cluster pallete) and the input cluster is constant in each iteration, but gets overwritten with new values also in every iteration. You need to create a constant of each bundled element and make a new bundle that is the input of the "input cluster". Check some examples online.
You can avoid this by using the basic "Bundle" function, but I kept the name to make it more readable.
The "bundle by name" accesses the elements by name, whereas the "bundle" by their position. If you have a large bundle, you can get in trouble quickly.
Best regards,
K
01-14-2014 04:27 AM
Thank you.....i think i figured it out. Area is used as first element for sorting in ascending and then final array was reversed. I was able to extract the center by clustering and unbundling the 1st array and element.
I do have a doubt. Is there any difference between the center calculated in blob detection technique and the one used for particle analysis
01-14-2014 05:20 AM
Hello,
if you have a doubt:
a.) read the documentation and
b.) test both examples on the same input sample(s). Compare the results.
For me, this is always the best way to test stuff for specific application needs (sometimes its b.) before a.), but that is only due to my impatient nature).
Best regards,
K
11-14-2014 12:28 AM
Hello,
I have to accept nut having diameter 1cm and reject other nuts , if I place them in front of my camera using particle analysis.
I have Labview 2012 version and Camera used is Basler aca 2000-50gc .
I tried to make a VI by using concepts of " Particle analysis .vi " example, but it is not showing proper results.
I am attaching my VI and Image of nuts .
Please suggest me modifications as soon as possible.
Thanks.