Machine Vision

cancel
Showing results for 
Search instead for 
Did you mean: 

Vision Builder AI cooridnate system

Solved!
Go to solution

I would like to be able to create a coordinate system from two points within "Vision Builder for Automated inspection", where the first point (x1,y1) is the origin, and the second point (x2,y2) is the x axis, but also the direction from x1 to x2 is positive. This does not seem to function in VB4AI, as it will take the coordinates, and use the correct angle, but does not accept direction.
Any help thoughts would be appreciated.

0 Kudos
Message 1 of 5
(3,199 Views)

Hi Kaivan29,

 

This is Austin at NI; thanks for posting to the Vision Forum to get some help with your Vision Builder for Automated Inspection (VBAI) application! Generally, the Set Coordinate System step in VBAI relies on other features your inspection has detected. For example, if I've detected an edge on an image and can set my x or y axis perpendicular to that edge.

 

However, to use two separate points, you may have to do some creative processing in order to find features that you can build a coordinate system off of. For example, you could detect two objects that always appear in your images, then use the Geometry step to calculate the line between them. Once that has been accomplished, you can use the Set Coordinate System step to use the feature located at the origin and then use the 'Horizontal, Vertical and Angular Motion' mode of the step to orient your axis the proper direction.

 

If you could post the image you're hoping to use and the VBAI inspection you're building, we'd be able to give more specific guidance.

 

Best!

Austin H.
Chief Product Manager
Test Software
Message 2 of 5
(3,161 Views)
Solution
Accepted by topic author kaivan29

Use the Geometry step to get the angle between the two points and then the coordinate system step can use point 1 as the origin and the result of the Geometry step as the angle. 

Hope that helps

Brad

Message 3 of 5
(3,156 Views)

Hi Austin,

 

Yes I have detected two or more objects that appear in my images. I calculated the distance between the two selected points using the Geometry Step. Then I tried to set coordinate system with the way you described but was unable to get the desired result.

Now, I tried @Brad approach by getting the "Angle from Horizontal" between the two points and successfully setup the coordinate system using the one of the points and the angle obtained from the geometry step.

I am attaching the image after successfully getting the desired result.

Thank you,
Kaivan

0 Kudos
Message 4 of 5
(3,134 Views)

Hi Brad,

 

That worked and gave me the desired result!

Thank you,

Kaivan

0 Kudos
Message 5 of 5
(3,131 Views)