Software improves vision hardware
By Steve Scheiber, Contributing Technical Editor -- Test & Measurement World, 8/1/2007
To achieve the best possible image quality on machine-vision systems used for robotic assembly and inspection, you need software that can improve on the hardware-generated results. Every lens produces spherical distortion that increases toward the image extremities, making points appear closer to the center of the field of view than they are. The wider the field of view, the more severe the distortion.
Vision-system software must compensate for this discrepancy to permit accurate measurements and to ensure that an inspection system correctly identifies good and bad parts. The software also ensures that a robot relying on the image will know where to reach for components or other objects.
Calibrating a vision systemBryan Boatner, product manager for Cognex, explained, “An important function of good vision software is to perform a nonlinear calibration that compensates for the spherical distortion. A common calibration technique involves a grid of very precisely etched dots or drilled holes on a glass or ceramic substrate. When you insert the grid into a vision system’s field of view, the dotted lines appear curved [Figure 1].
“Calibration software calculates the degree of distortion at each location in the field of view and the necessary adjustment that would be required to eliminate it [Figure 2]. With that information, the software can modify pixel locations for any image acquired by the system, permitting precise measurements and other analysis.” The missing dots along the axes in the figures allow the software to unambiguously identify which is the x- and which is the y-axis.
![]() |
![]() |
|
Fig. 1 A precise orthogonal dot grid may appear curved because of spherical distortion from any lens. Courtesy of Cognex. |
Fig. 2 A software algorithm calculates compensating displacements to generate an accurate image. Courtesy of Cognex. |
Boatner continued, “Another issue is how the system identifies components in the field of view. The simplest method is called 'blob analysis,’ which looks explicitly for the object itself. Accuracy is at most 1 pixel, and unless the object is oriented in the correct direction, identification may be difficult.
“Also, many inspection stages are not evenly lit, a situation that can interfere with the image analysis, and there are many cases where two allegedly identical parts will not reflect the light in exactly the same way. To reduce the variation, you may have to buy additional lighting equipment or enclose the inspection stage in some kind of shroud. Components from two vendors may not be quite the same shape and can be a totally different color.
“Using a geometric pattern-matching algorithm that detects component edges is much more accurate. You look only for the transition between the board surface and the component surface. The technique is much less affected by uneven lighting and other irregularities in the 'appearance’ of the inspection stage in the field of view.”
Preventing false failuresOne of the chief criticisms of automated inspection is the preponderance of false failures. You want your pass/fail criteria to be flexible but sufficiently limited to avoid escapes. If your standards are too narrow, good parts will fail. Where do you draw the line?
“Typically, the pattern-finding tool determines an overall score for the object,” said Boatner. “If there is anything unwanted in the image, that too gets a score. You decide how closely you want the part under inspection to match the learned or programmed part. We typically analyze a large selection of good parts and bad parts, performing an analysis that will establish statistical boundaries around 'good’ and 'bad’ to reduce the number of false calls.”
Some hardware manufacturers develop their own vision software, while others partner with an independent software supplier. Developing hardware and software within the same company means that you have complete control over the integration process. The same engineers who build the robot itself design its native “language.”
But a robot company’s expertise is robots. Those engineers may not take advantage of the software’s full potential or produce the most capable or accurate result. Boatner concluded, “Working with a partner means that each engineering group addresses the issues that it knows best.”




















