LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Introduction to IMAQ Count Objects 2

Hi Guys,

 

My LabView connection and the front panel is as such. My Software is designed in a way whereby it will auto detect any cells that fulfill the size requirement of 3000 - 100000.

 

During this process, a region of interest is created around the the cells and at the same time a ID number is assigned to it. However, whenever i move the joystick which moves the area of interest around, the position of the cells changes and new cells might appear and disappear due to the limitation coverage provided by the camera itself. As a result, the ID number changes (even though it is the same cell) as the programme works in a way which it will always start assigning the number from a top-down and left to right approach.  I was wondering is there any way i could permantly assigned the ID number to every specific cells without changes everyime i move the cover-slip (Glass use to store the cells)? Probably based on the size of the cells or any other unique specifications i could rely on to make a permanent ID number to it. 

 

Thank you in advance.

 

Best Regards,

Scott 

Download All
0 Kudos
Message 1 of 7
(4,357 Views)
Yes, as far as numbering in Particle analysis is top-down and left-right as you said. And this is very well expected behavior of particle analysis, because everytime you will give new image to it and you cannot expect fixed names or ID numbers.
-If you want to make fixed names for particles, you can try keeping ID numbers to the particles based on your criteria and store them in an array and keep checking particles of that criteria in the previous array and then rename the particles.
-Lets see if anyone else has better idea.
-Please post vision related queries in this dedicated board to get better audience http://forums.ni.com/t5/Machine-Vision/bd-p/200
Thanks
uday
0 Kudos
Message 2 of 7
(4,341 Views)

Hi Udka,

 

Thanks for your response. Based on your suggestion, you stated sotring the id numbers into an array, can i know how do i achieve this? For the second part, what do you mean by rechecking the particles in the previous array and rename the particles? WIll do so from the subsequent post. Sorry for posting at the wrong board. 

 

Best Regards,

Scott

0 Kudos
Message 3 of 7
(4,154 Views)
Where should i start?
-Do you have problem generating ID numbers? or ading them to array?
-Lets say you keep your id numbers along with criteria like say area of the particle. Then in the new image also, if you get particle of same area you should give same id.
-As altenbach, suggested for now keep this discussion in one thread and in future you can post them appropriately.
Thanks
uday
0 Kudos
Message 4 of 7
(4,120 Views)

Hi udka,

 

Thanks, will keep in mind altenbach and your suggestion.

 

1) Generate ID - not much a issue since it is carried out internally by the IMAQ Count Objects 2. 

2) As attached is how i add them into the array. However i am not sure am i doing the right way. During my trial, i have 3 particles, And ID number from 0-2 was given by the IMAQ Count Objects, then subsequently, my output array contains the same data but with duplicated data using ID number 3-5 similar to 0-2 data. 

 

3) Next, i believe for the criteria setting, I might need to use a case structure to set a range as the data of the cells is varies slightly at all times. In the event, i gets back the same criteria, how am i going to assign the same id? Any idea, what VI to use? 

0 Kudos
Message 5 of 7
(4,107 Views)

Hi Scott, thanks for reply.

1) Yes, creating ID is not a problem since it does already.

2)What you are trying is inserting array elements to the same array, which will append the same elements. That is the reason why you are getting duplicate entries.

Infact output of IMAQ count objects is array of object elements.you don't need to do insert elements into array.

3)Yes, you might require case strucure. As told already you need to find nearest value in the array (search in forum itself,plenty of examples and ideas are availbale) and how much cell can vary is what defines threshold for nearest element.

 

-How do you plan to run IMAQ count object for second image? I did not see any loop!!!

-When you run for first image, you get IMAQ count object output and when you run for second image where will the results go??? They will just replace the previous output currenly in your code.(you might need to learn how to use for loops and shift registers)
-You need both outputs arrays previous and current for comparing and then only you can go further.

-Then you search for the current ouput value in the previous output value and if it is present already then you replace the ID with previous ID.

Thanks
uday
0 Kudos
Message 6 of 7
(4,045 Views)

Hi Udka,

 

Thanks for rectifying my problem. 

 

For your pointer (3): What do you mean by finding nearest value in the array and how much cell can vary is what defines threshold for nearest element? 

 

For the subsequent questions:

At this point of time, I only having one image and the new images is formulated when i move my joystick which controls the stage. I roughly gets an idea what you wants me to do. Let me read up on for loops and shift register and try it out before getting back to you. Thank you in advance. 

 

Regards,

Scott

0 Kudos
Message 7 of 7
(3,986 Views)