Next: Object detection
Up: Correspondence Analysis
Previous: Correspondence Analysis
Search for corresponding lines
After the line lists for both images are generated, the correspondence problem needs to be solved. In contrast to an intensitybased correspondence analysis, there is no need to have a maximum disparity limit because all the lines are compared and thus all possible disparities are taken into consideration. But a constraint, that a line which is nearer than another is more likely to be chosen than a line which is more far away, has to be inserted. This constraint is needed, because if there are two objects mapped with approximately the same ycoordinate and approximately the same line properties, e.g. the same length, attitude and midpoint, as it is if two robots are next to each other, the left border of the robot could be matched with the left border of the other robot. Figure 3.12 depicts this situation.

To avoid matching of two opposite lines, the gradient direction is taken into consideration. Figure 3.12 shows the gradient direction for the left edge image (depicted as red arrows in the electronic version of this thesis at the top and bottom). To measure the similarity between two lines, the weighted sum of the difference between the attitude , the direction , the length and the difference in the ycoordinate between the start and end point of the line is computed. Let denote a line inside the right image, then the rating of a line can be formulated as
(3.15) 
where ,
, and
are weights, that define the importance of the line property. The currently implemented method uses
as .
A line corresponds to a line , if
 the rating is smaller than the best rating achieved, thus (
) must hold.  the xcoordinate of the compare point in the left image is greater than the xcoordinate of the compare point in the right image
 the ycoordinate of the intersection between the horizontal line which has its origin in the left compare point and the line in the right image lies inside this line.
 the rating is below a given threshold
 the calculated disparity between the two lines is smaller than the maximum disparity allowed
 the difference of the gradient direction
is below a given threshold
During the search for corresponding lines, every line inside the left image is compared with every line inside the right image. The lines with the best rating are considered as corresponding lines. If two lines fulfill the constraints mentioned above, the lines are removed from the list of possible candidates. To avoid false matches, the rating has to be smaller than a given threshold. If two corresponding lines with disparity have been found, a horizontal line of length is inserted in the left image. It has its origin in the midpoint of the left line and if the right line would be inserted into the left image, the compare point would be the end point of the line.
Next: Object detection
Up: Correspondence Analysis