Ten points to look for when choosing pattern-matching software
Ten points to look for when choosing pattern-matching software
Bill Silver
Chief Technology Officer Cognex Corp.
Natick, MA 01760
The promise of geometric pattern matching is to locate objects by shape, independent of orientation, size, and shading, and at a much higher accuracy than previously possible, but without sacrificing the speed, ease of training, and degradation tolerance of gray-scale correlation. The limitations of correlation stem from tying the representation of a pattern both to gray values (shading) and to a spatially quantized grid. However, they can be overcome by representing and matching patterns using a geometrical description of shape rather than a template of gray values. Making this work in practice is challenging, as there are differences in various product offerings. Here are ten points to watch for:
1. Orientation and size independence. The first test of a true geometric pattern matcher should be the ability to find objects independent of orientation (0°-360°) and size (limited only by field of view and camera resolution). Also, can the tool also handle aspect-ratio variation? Even if your object does not exhibit such variations, it can often simplify training to use a standard synthetic pattern and then adjust the geometry at run time, without retraining.
2. Accuracy unaffected by orientation and size. Whereas many tools offer high accuracy when there is no variation in orientation and size, another key test of a geometric pattern matcher is that accuracy be unaffected by these variations. This is key because almost all applications exhibit some variation, and it defeats the purpose of geometric matching if accuracy falls off beyond a few degrees or a few percent of size as Normalized Grayscale Correlation (NGC) does. This is particularly key in networked factories where patterns may be distributed to machines with varying optical magnification and camera angle.
3. Speed. The promise of orientation and size independence is of little use if the tool is too slow. While it is easy to offer high speed when there is no orientation and size variation, be sure to test speed for the 0°-360° case, for a large size variation, or both.
4. Tolerate shading variations. Pattern matchers based on geometry rather than gray scale should tolerate wide variations in shading, such as might occur with nonoriented metal parts or due to the chemical, mechanical, and planarization step in wafer processing.
5. Tolerate missing features, occlusion, and clutter. Template-matching methods such as NGC were good at tolerating degradation such as missing features and scene clutter; in switching to geometric matching one should sacrifice none of this.
6. Tolerate defocus and low contrast. Severe defocus and low contrast can present a particular challenge to some geometric matchers. Even if your application does not exhibit these problems, it is a good idea to check both as a test of general robustness.
7. Tolerate pattern with poor edges. If a geometric pattern matcher uses edge detection to extract shape information, it might fail on images that have poor edges but where NGC would still work. This can be serious if you do not know in advance the edge quality of the images in your application. A geometric matcher that uses a tuneable feature detector instead of simple edge detection can solve this problem and even find patterns that would stump NGC. Push your tool to the limit by trying patterns made of random texture without sharp boundaries.
8. Train by showing. One of the benefits of NGC is that a pattern can be trained by drawing a box around the desired portion of an image. Training a geometric pattern matcher should be just as simple. Beware of fancy wizards and pattern editing tools. Although they can be useful in unusual circumstances, they should not be necessary in most cases, and most machine operators have enough challenges already without having to learn to use these training tools.
9. Runs on PCs. If the pattern-matching tool runs on an ordinary PC without special hardware, you can be sure that you`ll keep up with Intel`s performance improvements. Beware of custom accelerators from small companies who can not keep up with Intel.
10. Customers. In the end, the marketplace is the best judge of quality. Be sure to ask about actual installations of geometric pattern matching.