Rockwell Automation 5370-CVIM2 Module User Manual

Page 199

Advertising
background image

Chapter 6

Reference Tools

6–40

X Scale, Y Scale Selections

The

X Scale

and

Y Scale

“compression” ratio selections, shown in

Figure 6.34, determine the ratio of pixel averaging or “compression” to be
used on the images in the feature and search windows.

Figure 6.34

X Scale and Y Scale Ratio Selections

The scaling trade–offs are these: The higher the numeric ratio, the lower the
image resolution but the faster the search. Conversely, the lower the numeric
ratio, the higher the image resolution, but the slower the search.

As Figure 6.34 shows, the scaling ratios are 1:1, 1:2, 1:4 (default), and 1:8.
The concept is this: For a 1:x ratio, x pixels are replaced with one pixel
whose gray scale value equals the average gray scale value of the x pixels.

Figure 6.35 (page 6–41) illustrates this concept using the 1:4 ratio for both

X

Scale

and

Y Scale

. With the 1:4 scaling ratio selected, the 16 gray scale

values of each 4–by–4 block of pixels are averaged (“compressed”) to one
gray scale value in one pixel.

Figure 6.35 shows four such 4–by–4 blocks of pixels: A, B, C, and D. Thus,
block (A) is compressed to a single “pixel” (A

) whose gray value is 41,

block (B) is compressed to a single “pixel” (B

) whose gray value is 33, and

so on.

This “compression” applies to the images in both the feature window and the
search window. The result is that since both images have fewer pixels, the
effectively smaller feature window requires less time to search the effectively
smaller
search window.

In some applications, an asymmetrical scaling selection may be appropriate.
In such cases, high resolution (1:1 ratio) may be required on one axis in order
to avoid loss of necessary detail, but low resolution (such as 1:4 or 1:8) may
be acceptable on the other axis because details are not present or are not
important for template–matching purposes.

Advertising