Professional Documents
Culture Documents
Rest PDF
Rest PDF
An image consists of a list of identifiable places, called feature points, observed in an image, > The model consists of several images—minimally three for polyhedra. Furthermore, let us agree to call each unidentified object an unknown. Using this vocabulary of models and unknowns, you want to know whether it is practicable to match an unknown with a model by comparing the points in an image of the unknown with a templatelike collection of points produced from the model. In figure 26.1, for example, the nine points seen in the image of an unknown match the nine points in an overlaid, custom-made obelisk template. Whenever a general question is hard, itis natural to deal with a special case first. Accordingly, suppose that objects are allowed to rotate around te vertical axis only; there are to be no translations and n0 rotations about other axes, In figure 26.2, for example, the obelisk shown in figure 26.1 is, viewed in its original position, and then is rotated about the vertical axis by 80°, 60°, and 90°. In each of the images shown in figure 26.2, the obelisk is projected orthographically along the z axis. As explained in figure 26.3, the x and y coordinate values for points in the image are exactly the x and y coordinate values of the obelisk’s vertexes in three dimensions.One Approach Is Matching Against Templates. 535 Figure 26.2 An “obelisk” and three orthographic projections of the obelisk, one each for 30°, 60°, and 90° rotations. Figure 26.3 Onhographic projection. Light moves along paths paralll to the z axis to ‘an image plane somewhere fon the z axis, The x and 'y coordinate values of the vertexes in an image equal their three-dimensional x and ¥y coordinate valuet | | image plane536 Chapter 26 Recognizing Objects Somewhat unusually, the coordinate system shown in figure 26.3 is a left-handed coordinate system, but most people like to have the distance from the image plane increase with increasing z, which dictates the left- handed arrangement. Next, note that corresponding points in figure 26.2 are labeled with corresponding numbers. In general, matching points in one image with those in another to establish correspondence may be difficult; for the mo- ment, however, just assume that the necessary matching can be done. You learn about several approaches in the next section. Now, by way of preview, consider a point that appears with an z coordinate value of 2, in one obelisk model image, and with an x coordinate value of zy, in another obelisk model image. Soon, you learn that the 2 ‘coordinate value of the same point in an observed image is a weighted sum of the coordinate values seen in the model images: Bry = ty, + Bay, Next you see that a and 8 can be recovered using a few corresponding. points, making it easy to predict where the remaining points should be; providing, ultimately, an identification test. For One Special Case, Two Images Are Sufficient to Generate a Third ‘The nature of orthographic projection is such that a point corresponding to vertex located at (2, y, 2) in space is located at (z, y) in the orthographic image. After rotation about the y axis, however, the vertex is no longer at (z, y, 2). Although the y coordinate value is unchanged, both the and 2 coordinate values change. As demonstrated by some straightforward. trigonometry, the coordinate values, after rotation, are determined by the sines and cosines of the rotation angle, . More precisely, the new 2, y, and 2 coordinate values, 2, yo, and 2, are related to the old x, y, and = coordinate values by the following equations: 1% = 2c036— 2sin8, w=. ag = 28ind + =c0s8. Because the y coordinate value endures rotation and orthographic projec tion without change, and because the 2 coordinate value does not enter into orthographic projection, your interest is exclusively in the fate of the x coordinate value as an object rotates. “To keep the discussion as concrete as possible, assume that the obelisk is rotated from its original position twice, once by 67, and once by 8),, to produce two model images, f, and f, What you want to know is what the obelisk looks like when rotated from its original position a third time, by 1 producing imageConsider a particular point with original coordinate values x,y, and. In the two model images of the rotated obelisk, the z coordinate values of the same point are 21, and 27,. The problem isto find a way of determining a, ven the known values, 7j, and 2j,. Once you can do this for any particular point, you csn doit for all points and thus construct the desired third image of the obelisk, So far, however, you can only relate 21, Ts and 2, to the original 2 and = values and the angles of rotation: a, = £00804 ~ 28in Or, 1, = £0881, — =8iN Bi, 1g = 00864, — =8in Big ‘To understand what these equations can do for you, you need to understand cone subtle point, 1), Tip, and 21, vary from point to point, but 81. 814, fand 8, do not. The angles do not change as long as you are working with a fixed set of images. Accordingly, if you are trying to solve the equations for a7, for a fixed set of images, the sines and cosines of the angles ate constants. Better still, the equations are three linear equations in the three un- knowns, 2/,, 2, and 2, From elementary algebra, you know that you can solve three linear equations in three unknowns, leaving 1, expressed a8 & weighted sum of 21, and 2, n, = 0%, + Bary Describing this expression in mathematical language, 21, is given by a linear combination of z, and 2, and a and f are called the coefficients of the linear combination Now, if you only knew the actual values for a and 9 relating observed points %0 points in the two model images, you could predict where every point should be from where it appears in the two model images. If the Predicted points match the actual points observed, then the observed object matches the model object. Of course, you could work through the algebra and determine how and 8 can be expressed in terms of sines and cosines of 8, Gis, and 81 But that would not help you, because you normally do not know any of those angles, You need another approach Identification Is a Matter of Finding Consistent Coefficients ‘You have just learned that there must be constants a and such that the coordinate values in an observed image are predicted by the equation 219 = 021, + By. Because a and 8 depend on only the three images, 11, Jz, and J,, you need only two linear equations to determine their values. Fortunately, two sets of corresponding points provide those equations. Suppose, for example, that you have found a point Py in the observed image538 Chapter 26 Recognizing Objects Figure 26.4 Two unknown objects compared with templates made trom obelisk images to ft points P, and Pa. The unknown on the left is actually an obelisk rotated by 45°. It matches the template of circles produced trom the two ‘obelisk models. The unknown fon the right—the one that looks. Tike @ jukebox—doos not match the template made fo and the corresponding points in the model images. Similarly, suppose you have found point P, and its corresponding points. Then, the x coordinate values of both points in the observed image must satisfy the following equations: Pity = O2P\h + BEPL Hy 20st = 2751, + 82,1 ‘Now you have two, easily solved equations in two unknowns. The solutions are, of course, gw Tala 7Pshy~ 2PsloPs Ph TPs, ~ Pah =P la gx TalotPah — 2Psto2Psh 2P.nDPah — FPah Bile ‘Once you have used two of n sets of corresponding points to find a and 8, ‘you can use a and 8 to predict the positions of the remaining n — 2 sets of corresponding points of the observed object ‘The predicted point positions then act like a template that the points in the observed image must match if the object in the image is the same object seen in the model images. For the obelisk example, the following table gives the z coordinate values for points P; and P, in the images of the obelisk after rotation by 30° and 60°. The table also gives the x coordinate values of corresponding aap,1, + BEPi te‘The Template Approach Handles Arbitrary Rotation and Translation 539 points on the two unknown objects shown in figure 26.4. The y coordinate values are not shown, because they do not vary from image to image, Position in| Position in | Position in | Position in image 1 | image | image Ui | image U> =, 2.73 —2.18 2.83 354 =P 073 0.73 0 O71 Using the x coordinate values, you can caleulate what a and must be for each of the two unknown objects by substituting values from the table into 20,14 = 0p, 1 + B80, .4- For the first unknown object, you have, for ‘example, the following equations after substitution: -2.83 = a(-2.73) + (-2.73), 0 = a(0.73) + (0.73). Solving these equations, you have a = 0.518315 and 6 = 0.518315. Solving the corresponding equations forthe second unknown yields «x= 1.13465 and {8 = 0.16205. You can use these a and f values to predict the x coordinate ‘values for each of the remaining points, with the following results: T; predicted | Uy actual | Us predicted [Uy actual | ze | __—288 =283 354 ~354 ry 0 o 070 070 ey ial 1a 212 212 he 283 283 34 424 Te 283 288 354 354 Zi ° ° =070 =070 ze | 288 = 2.88 “354 =288 zm | _—1ai 1a =212 =2az Zr ° ° “070 —~*| OO Evidently, the first unknown is an obelisk, because all predicted points are where they should be, as shown in figure 26.4; the second unknown is not an obelisk, because three predicted points are in the wrong place. ‘Although the second unknown has much in common with the obelisk, the ‘Second unknown is wider, and its front and back are tapered, rather than vertical, making it look a bit like a jukebox. ‘The Template Approach Handles Arbitrary Rotation and Translation In one special case, you have seen that identification can be done using only ‘two model images together with two points that appear in both of those540 Chapter 26 Recognizing Objects model images and in an image of an unknown object. The special case is severely restricted, however; only rotation around one axis is permitted. ‘You have concentrated on the one-axis-rotation special case for two rea- sons. First, looking at special cases is the sort of thing researchers generally do when they are trying to develop a feel for what is going on. Second, the one-axis-rotation special case is within the reach of straightforward mathematics More gonerally, however, you have to expect that an unknown may have been arbitrarily rotated, arbitrarily translated, and even arbitrarily scaled relative to an arbitrary orignal postion. ‘To deal with these changes, you first have to believe, without proof here, that an arbitrary rotation of an object transforms the coordinate values of any point on that object according to the following equations: fa = rel O)t + PyolO) + Pel O)2, Wo = Fey(B) + Foy (Oy + Pay) 2g = Peal O) + Tye (B)y + ree(B)2, ‘Note that r,,(0) is the parameter that shows how much the z coordinate of a point, before rotation, contributes to the 7 coordinate of the same point after rotation. Similarly, 7,.(@) is the parameter that shows how much the 1 coordinate of a point, before rotation, contributes to the = coordinate of the same point after rotation If, in addition, the object is translated as well as rotated, each equation sains another parameter 29 = Tel O)2 + tya(O) + Fer)? + by to = PaylO)2 + Fy OW + yl O)E + ty rex(O)2 + tya(O)y + Pas(O)2 + tee where the ‘sare al parameters that are determined by how much the object is translated. ‘Now you can repeat the development for the one-axis-only special case, only there mast be three model images, These three model images yield the following equations relating model and unknown coordinate values to unrotated, untranslated coordinate values, x, y, and 2: rn (Oa) + ry) + Pex (Bn)= + te (Ba)e 11, = Fea(®a)t + Tyla) + Pex (Bn)2 + te (Pa)e ra a2 + Fye(8)0 + Pen(8a)2 + f(a) 21, = Tes(0)0 + Fye(BoY + Pox Oo)s + (Bo): Plainly, these equations can be viewed as four equations in four unknowns, 1, y, 2, and 27,, which can be solved to yield 2, in terms of 27,27, and 2, and a collection of four constants 21 21g = eth, + Bot + 722h + 2s‘The Template Approach Handles Arbitrary Rotation and Translation 541 where a, Be, Ye, and 6, are the constants required for 2-coordinate-value prediction, each of which can be expressed in terms of rs and ts. There is ho reason to go through the algebra, however, because, as in the one-axis- Only case, there is another way to obtain the values of ag, Be, Ye» and 6s without knowing the rotations and translations. Following the development for the one-axis-only special case, you can use a few corresponding points to determine the constants. This time, hhowever, there are four constants, so four points are required: pytg = ey 1s + BaP sta + TeBPsIs + Be 2Paty = CePyt, + BatPala + TetPaly + Oy Epyto = Ox BPyhy + Be Pals + YePa!s + Bar Pity = 2 tPchh + Be thet + YetP aly +52 Solving these equations for as, Be, Ye, and 6, enables you to predict the 2 coordinate values of any point in the unknown image from the eorrespond- ing points in the three model images. Note, however, that you have to consider the y coordinate values also. ‘There was no need to consider y coordinate values in the one-axis-ouly special case because rotation was around the y axis, leaving all y coordinate Values constant from image to image. In the case of general rotation and ‘translation, the y coordinate values vary as well Fortunately, the development of equations for y values follows the de- velopment of equations for the 2 values exactly, producing another, differ- ent set of four constants, ay, By, %y, and 8, for the following equation: Mio = yh + By + Wits + By ‘Thus, the identification procedure requires three model images for each identity that an object might have: a To identify an unknown object, > Until a satisfactory match is made or there are no more ‘models in the model library, > Find four corresponding points in the observed image and in a model’s three library images. Use the corresponding points to determine the coeff cients used to predict the x and y coordinate values of other image points. > Determine whether a satisfactory match is made by ‘comparing the predicted x and y coordinate values with, those actually found in the observed image. > If a satisfactory match occurs, announce the identity of the unknown; otherwise, announce failure, ee542 Chapter 26 Recognizing Objects Figure 26.5 Three obelisk images. The one on the left has been rotated 30° ‘around the x axis relative to 7 the standard intial standing 7 position, pitching it forward; the second has been rotated around the y axis; and the third has been rotated around the 2 axis. Figure 26.6 Three unknown ‘bjacts are compared to co oo templates made from obelisk | \ Images using the points marked \ by black circles. The unknown ‘on the left matches the obelisk \\ template. The unknowns resembling a jukebox and a j sofa do nat match. ‘nus, you need three images, like those in figure 26.5, to have an obelisk model that is good enough to recognize obelisks with unrestricted rota- tions and translations, With such a model, and knowledge of how four corresponding points in the model correspond to four points in each of the ‘object images shown in figure 26.6, you identify just one of those objects as an obelisk. The Template Approach Handles Objects with Parts So far, you have learned that the x coordinate value of any point is given by a linear combination of the coordinate values in two or three model images, Now you learn that the x coordinate value is given by a linear combination of the coordinate values in several model images, even if an object has parts that move relative to one another,‘The Template Approach Handles Objects with Parts 543 Figure 26.7 An object with two parts, C, and C2, each bout the y axis. ceones, | ty | So as to keep the algebra as uncluttered as possible, the explanation is focused on the special case of rotation about the y axis, and the example is the one shown in figure 26.7. Note that each part is, by itself, one rigid object. Accordingly, the ‘x coordinate value of a point in an observed image, 21, is determined by fwo model images and a particular a, 9 pair specialized to one part of the object, as indicated by elaborate a and 8 subscripts: Bg = ACitoth + BC to By ‘The C; in the subscripts indicates that the a and @ values are for part 15 the J, subscript indicate that the a and ( values transform , and Jz values into I, values. Similarly, 27, is given by a different a, 9 pair if the other part is in- volved: Caloth, + Beate ‘Amazingly, if you have enough images, you do not need to know to which part a point belongs, for there is a set of four coefficients—a, 8, 5,7 such that the z coordinate value is determined by four model images, four co- ‘efficients, and the following equation, no matter to which part the point belongs: bhp = t1, + Btn + Oty + EH ‘To see why, you have to go through a bit of algebra, but in spite of the necessary subscript clutter, there is only one mathematical insight involved: ‘You can solve 1 independent linear equations in 1 variables.544 Chapter 26 Recognizing Objects Strategically, you need to convince yourself that the four-coefficient ‘equation for z,, the one that requires no knowledge of which part is in- volved, does the same thing as the two-coefficient equation for 21,, the one that does require knowledge of which part is involved. Said another way, ‘you need to be sure that there is a set of four coefficients, a, 9,6,7, such that the following is true if 27, is a coordinate value of a point on part 1: aan, + Ban, + O21, + 78H = AC, 19th + Bo loth Alternatively, the following is true if 2), is a coordinate value of a point on part 2: an, + O21, + 821, + 12H = Acytoth + Beato Focus for now on the case for which 2,, is the z coordinate of a point that belongs to part 1. Because you assume you are dealing with just one part, you know that two model images suffice to determine the 2), coordinate value of any point in any image. Accordingly, 11, and 1), can be determined by 2, and 7, along with an a, pair suited to the part and the images produced, as indicated by the subscripts: By ACh + BoA Bh ROG nTH + Boh Evidently, 27,, given that the point is on part 1, must be determined by the following after substitution for 2), and zy: Bio = O21, + B21, + Hac, 4 th + Benth) + Wac.uth + BOWTh)- Rearranging terms yields the following: Hy = (+ Bac, +0, )2n + (B+ 88e.15 + Bests) But you know that 21, = a¢, 252% + 9,152. 80 now you ean equate the two expressions for 2/,, yielding the following: Mo foth + Bertoth = (0+ 8G 1, + AC 1) + (B+ 68.15 + Bon en For this equation to hold, the coefficients of 21, and 21, must be the same, producing two equations in the four coefficients, a, 8,7 Act =A-+ 6A + IAC Le + 68.15 + Bet Bete = Going through exactly the same reasoning, but assuming that x belongs to part 2, produces two more equations in the four coeficients OcyI5 =0-+ B00, + 78Cst, Beato =B + BBcxts + VBeat Now you have four equations in four unknowns, thus fully constraining a, 8, 8, and 7. The only a, ,6,7 combination that works, no matter what, is the combination preseribed by those four equations, Of course, none of this computation would do any good if you had to use the solutions to determine a, 8, 6,7, for then you would have to know all the particular a, 8 pairs appropriate to the individual parts and images.mma - cS Figure 26.8 images, lof two unidentified automobiles. Images courtesy of Ronen Bast —<—< Fortunately, however, you can use the same idea that proved invaluable before: Given that you know that an appropriate set of coefficients exists, ‘you can create a different set of equations, with easily obtained constants, by looking at four distinct points: Pty =0P1, + BEM, + BEI + EP Ls pat + Bapyty + OtP1s + VAP atay pst, + Bary, + BER + YEP: Palo BPalo =OLP rh + BtP sty + bP ety + VEPAL ‘The Template Approach Handles Complicated Curved Objects ‘To get a fecling for the power of the template approach, consider the two toy-automobile images shown in figure 26.8. ‘To initiate identification, you have to reduce both to line drawings, as in figure 26.9 ‘Suppose that each automobile is known to be either an old-model Volk- swagen or an old-model SAAB. To determine which itis, you need to match the drawings to constructed-to-order templates. Remarkably, the templates can be made straightforwardly, even though the objects have curved sur- faces. All you need to do is to increase the number of images that constitute ‘a model. instead of the two model images needed for rotation about a ver- tical axis, you need three. Accordingly, you can form a Volkswagen model by taking three pictures and rendering those pictures as drawings. You can form a SAAB mode! the same way. Both are shown in figure 26.10.546 Chapter 26 Recognizing Objects Figure 26.9 Drawings of two unidentified automobiles. Drawings courtesy of Ronen Basti NOs Q ke © ba" ® ge) Figure 26.10 Models consist of throe drawings, Above is a ‘Volkswagen model; below is a SAAB model. Drawings ‘courtesy of Ronen Basti At the top of figure 26.11, the unidentified automobile on the left in figure 26.9 is shown together with a template manufactured for the drawing from Volkswagen images. As shown, the ft is just about perfect. At the bottom of figure 26.11, the unidentified automobile on the right in figure 26.9 is shown together with a template manufactured for the drawing from Volkswagen images. The fit is terrible, indicating that the drawing is not a drawing of a Volkswagen. Had the template been made from the SAAB model images, however, the fit would have been just about perfect.nts Need to Be Matched 547 Figure 26.11 Above is a drawing of a Volkswagen, a template manufactured from Volkswagen images, and the two images superimposed. Below is a drawing of an SAAB, a template manufactured ‘rom Volkswagen images, and the ‘wo superimposed. Drawings courtesy of Ronen Basi ESTABLISHING POINT CORRESPONDENCE, In this section, you learn how it is possible to determine how the points in ‘one image correspond to the points in another, a necessary prerequisite to template construction, ‘Tracking Enables Model Points to Be Kept in Correspondence Actually, it is relatively easy to create three images of an object, with known point correspondences, to serve as a model. All you need to do is to move the object slowly, taking many intermediate snapshots between each pair of images that is to be in the model. That way, the difference between adjacent snapshots is so small, corresponding points are always nearest neighbors, and you can track points from one model image to another through the intermediate snapshots, as suggested in figure 26.12. Only Sets of Points Need to Be Matched When you are confronted with an unknown object, there ean be no such thing as intermediate snapshots lying between the unknown's image and ‘one of the model images. Consequently, matching the points is much harder.548 Chapter 26 Recognizing Objects Figure 26.12 Moving an ‘object slowly makes it possible to track points from one model image to another through intermediate snapshots, Corresponding points are always nearest neighbors in adjacent snapshots, even though they are not necessarily nearest neighbors in the model images. Here five obelisk images are shown, with agjacent pairs rotated by 10°. —_—_—_—_—_——— ‘Accordingly, it is important to know that it is enough, in the general case, to establish that sets of points correspond, without knowing exactly how the points in the sets match up individually. ‘To see why, consider the one-axis-rotation special case again and recall that, for any point, P,, the following equation holds: Pte = AFP + OEP Accordingly, the equation must hold for points P, and Pa: Ply = OP, 1 + B7P lay Pato = OPH + BzPaty ‘Adding these equations produces the following: a(tp,4 + Pn) + B(tP.n + TPan)- Repeating for two other points, Ps and P,, provides a second equation in the two unknowns, a and (3 (2p ,19 + Talo (2 ate + 2Pato) = Wz Pat + Put) + BCP ste + FPote)- Note that, wherever zp,15 appears, it is added to zp47o, and vice versa. Similarly, wherever zpyzy appears, it is added to zp,s9, and vice versa ‘Accordingly, there is no harm in confusing 2p,1, and £p,/9, and there is no harm in confusing 2,1, and p.zp- By adding up the 7 coordinate values of the points in the sets, you eliminate the need to sort out exactly howHeuristics Help You to Match Unknown Points to Model Points 549 the points in the sets correspond. It is enough to know that the points in ‘one set are among the points in the corresponding set. Thus, for the one-axis-rotation special case, you do not need to find two corresponding points in two images. You need only to find two corre sponding sets of points in two images. ‘The argument generalizes easily. For arbitrary rotation, translation, and scaling, you do not need to find four corresponding points in three images. You need only to find four corresponding sets of points in three images. Heuristics Help You to Match Unknown Points to Model Points Once you know that it is enough to find corresponding sets of points, you can use a few heuristics to help you find those corresponding sets. If an object has a natural top and bottom, for example, the points near the top and bottom in any image are likely to form corresponding sets. Consider the model images and unknown shown in figure 26.13, As before, the 30° and 60° images constitute the model to be checked against the unknown. Earlier, you saw that you can use points P, and Ps to find and for the first unknown, using the following equations 2.83 = a(-2.73) + (273), 0= 0(0.73) + 3(-0.73) Any other pair of points would do just as well, of course. Instead of using Py and P, the points along the top, you could use any two of P, Ph, and Pr the points along the bottom, which produce the following equations: 2.88 = a(2.73) + 6(2.73), 0 = a(-0.73) + (0.73), 2.83 = o( -2.73) + 8(-2.73) Note that sums of equations are also equations. This, you can add together the equations for the top points to get @ new equation. Then, you can add together the equations for the bottom points. Thus, you have two more equations in a and 3: (-2.83 +0) = a(-2.73 +.0.78) + 3(-2.73 ~ 0.73) (2.88 +0 ~ 2.83) = a(2.73 — 0.73 - 2.73) + (2.73 -+-0.73 ~ 2.73) Naturally, these new, composed equations have the same solution as do the original equations involving Py and P;—namely, a — 0.518315 and 8 = 0.518315, Thus, you can use corresponding sets of points to produce equations in a and 4, instead of corresponding points. Within the cor. responding sets, you do not need to know exactly which point. goes with ‘hich point. Still, even finding corresponding sets may be hard, For one thing, the general case requires four sets of corresponding points, not just two. Also,550 Chapter 26 Recognizing Objects Figure 26.13 itis sufficient [ to find sets of corresponding points; itis not necessary to know exactly how the points rc within the sets correspond. you cannot always expect objects to have a natural standing posture that ‘enables you to identify top and bottom sets. SUMMARY um The traditional approach to object identification involves image de- scription, followed by surface description, followed by volume descrip tion, followed by matching with library models. a Amazingly, you can construct 2 two-dimensional identification tem- plate using the two-dimensional image of the object to be identified, plus a few stored two-dimensional image descriptions. Identification becomes a matter of template matching, a You construct two-dimensional templates by using a few corresponding, points to establish position-prediction coefficients fa For pure rotation of a polyhedron around one axis, two corresponding points in two images are sufficient to establish position-predietion coel- Reients for an unknown object in a given image. For general polybedron rotation and translation, you need four points in three images. When fully generalized, the template approach handles objects with parts and objects with curved surfaces. a Touse the template approach, you need to be able to identify corre, sponding features in image sets. Fortunately, you need only to find Corresponding sets of points, rather than corresponding points. Some- times, you can track points as they move, thus maintaining correspon dence, rather than establishing correspondence.Background 551 BACKGROUND dentification procedures in which a template is generated and matched to an unknown are called alignment methods. ‘The seminal alignment ideas described in this chapter were developed by Shimon Ullman and Ronen Basti (1980)Describing Images In this chapter, you learn more about computer vision through dis- cussions of two problems that are better understood than are most prob- lems. The first of these problems, the binocular stereo problem, is to find the distance from the viewer to surfaces using two slightly different view- points, The second problem, the shape-from-shading problem, is to deter- mine surface-direction at each point in an image by exploiting the way surfaces in the image are shaded. Once you have finished this chapter, you will know that image under- standing, like other problems in artificial intelligence, requires the right representation and a thorough understanding of the constraints brought out by that representation. COMPUTING EDGE DISTANCE In this section, you learn about a procedure that computes depth from image pairs. First, however, you learn how it is possible to isolate edges in images, Averaged and Differenced Images Highlight Edges At the edge between two flat faces, brightness should change sharply from cone value to another, as shown in figure 27.1(a). In practice, however, the steplike change generally is corrupted, as in figure 27.1(b), making it hard to determine just where the edge is. One reason is that image input devices do 553