Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Control Motor Via Motion Detection

Dear sir,

 

One more thing please send the VI working with vision assistant secondly the files are not compatible to 12.0 (there is error coming during opening of VI).

 

Thanks,

With regards,

Gagandeep sharma
0 Kudos
Message 11 of 18
(1,983 Views)

Strange about the error, it looks ok if i open it.

 

I am attaching the vi's saved for LV2010.

 

I do not use vision assistant, but it is really straightforward to do geometric matching. Load the rgb image, extract intensity plane and do geometric matching (train the template, and be careful to consider all the scales when you are adjusting the settings). Then just generate the labview code.

 

Best regards,

K


https://decibel.ni.com/content/blogs/kl3m3n



"Kudos: Users may give one another Kudos on the forums for posts that they found particularly helpful or insightful."
0 Kudos
Message 12 of 18
(1,976 Views)

Dear sir,

 

Got it and will reply soon.

 

Thanks,

 

 

Gagandeep sharma
0 Kudos
Message 13 of 18
(1,972 Views)

Thank You for your response 
I solved my Problem 
But I have another question :

When I searched in web, I found this equation :

d = (FL * RHO * IH)/(OH*SH)
 
Where:
d = distance to object (mm)
FL = focal length (mm)
RHO = real height of the object (mm)
IH = image height (pixels)
OH = object height (pixels)
SH = sensor height (mm)

but I don't know how to find focal length and sensor height to determine distance
Can you help me ?
0 Kudos
Message 14 of 18
(1,968 Views)

Just treat the equation as a bunch of unknowns that can be combined into a single constant, which is divided by OH.  You get:

 

d = C / OH

 

This is really easy to calibrate.  Measure a few distances and the object height in pixels.  Multiply each pair together to get an approximate value for C.  Average all these values to get a good value for C.

 

If you don't like this method, focal length is usually printed on your lens (something like 16 mm), and sensor height is the physical dimension of your sensor.  You can calculate it by multiplying the vertical number of pixels in the image and the physical pixel sensor size (something like 5 um), which would be in your camera manual.

 

Bruce

Bruce Ammons
Ammons Engineering
0 Kudos
Message 15 of 18
(1,964 Views)

Hello 
I am sorry, I'll tire you but I can't know until now  how to get the focal length and  physical pixel sensor size 
I'm using HD Webcam of my laptop 

0 Kudos
Message 16 of 18
(1,958 Views)

Hello 
I am sorry, I'll tire you but I can't know until now  how to get the focal length and  physical pixel sensor size 
I'm using HD Webcam of my laptop 

0 Kudos
Message 17 of 18
(1,958 Views)

Since you can't get these measurements, the only way is to do the calibration I talked about.  Measure the object height (pixels) at a bunch of different distances (mm) and fit a 1/x curve to the data.

 

Bruce

Bruce Ammons
Ammons Engineering
0 Kudos
Message 18 of 18
(1,956 Views)