fbpx
Wikipedia

Randomized Hough transform

Hough transforms are techniques for object detection, a critical step in many implementations of computer vision, or data mining from images. Specifically, the Randomized Hough transform is a probabilistic variant to the classical Hough transform, and is commonly used to detect curves (straight line, circle, ellipse, etc.)[1] The basic idea of Hough transform (HT) is to implement a voting procedure for all potential curves in the image, and at the termination of the algorithm, curves that do exist in the image will have relatively high voting scores. Randomized Hough transform (RHT) is different from HT in that it tries to avoid conducting the computationally expensive voting process for every nonzero pixel in the image by taking advantage of the geometric properties of analytical curves, and thus improve the time efficiency and reduce the storage requirement of the original algorithm.

Motivation Edit

Although Hough transform (HT) has been widely used in curve detection, it has two major drawbacks:[2] First, for each nonzero pixel in the image, the parameters for the existing curve and redundant ones are both accumulated during the voting procedure. Second, the accumulator array (or Hough space) is predefined in a heuristic way. The more accuracy needed, the higher parameter resolution should be defined. These two needs usually result in a large storage requirement and low speed for real applications. Therefore, RHT was brought up to tackle this problem.

Implementation Edit

In comparison with HT, RHT takes advantage of the fact that some analytical curves can be fully determined by a certain number of points on the curve. For example, a straight line can be determined by two points, and an ellipse (or a circle) can be determined by three points. The case of ellipse detection can be used to illustrate the basic idea of RHT. The whole process generally consists of three steps:

  1. Fit ellipses with randomly selected points.
  2. Update the accumulator array and corresponding scores.
  3. Output the ellipses with scores higher than some predefined threshold.

Ellipse fitting Edit

One general equation for defining ellipses is:  

with restriction:  

However, an ellipse can be fully determined if one knows three points on it and the tangents in these points.

RHT starts by randomly selecting three points on the ellipse. Let them be  ,   and  . The first step is to find the tangents of these three points. They can be found by fitting a straight line using least squares technique for a small window of neighboring pixels.

The next step is to find the intersection points of the tangent lines. This can be easily done by solving the line equations found in the previous step. Then let the intersection points be   and T , the midpoints of line segments   and   be   and  . Then the center of the ellipse will lie in the intersection of   and  . Again, the coordinates of the intersected point can be determined by solving line equations and the detailed process is skipped here for conciseness.

Let the coordinates of ellipse center found in previous step be  . Then the center can be translated to the origin with   and   so that the ellipse equation can be simplified to:

 

Now we can solve for the rest of ellipse parameters:  ,   and   by substituting the coordinates of  ,   and   into the equation above.

Accumulating Edit

With the ellipse parameters determined from previous stage, the accumulator array can be updated correspondingly. Different from classical Hough transform, RHT does not keep "grid of buckets" as the accumulator array. Rather, it first calculates the similarities between the newly detected ellipse and the ones already stored in accumulator array. Different metrics can be used to calculate the similarity. As long as the similarity exceeds some predefined threshold, replace the one in the accumulator with the average of both ellipses and add 1 to its score. Otherwise, initialize this ellipse to an empty position in the accumulator and assign a score of 1.

Termination Edit

Once the score of one candidate ellipse exceeds the threshold, it is determined as existing in the image (in other words, this ellipse is detected), and should be removed from the image and accumulator array so that the algorithm can detect other potential ellipses faster. The algorithm terminates when the number of iterations reaches a maximum limit or all the ellipses have been detected.

Pseudo code for RHT:[3]

while (we find ellipses AND not reached the maximum epoch) { for (a fixed number of iterations) { Find a potential ellipse. if (the ellipse is similar to an ellipse in the accumulator) then Replace the one in the accumulator with the average of two ellipses and add 1 to the score; else Insert the ellipse into an empty position in the accumulator with a score of 1; } Select the ellipse with the best score and save it in a best ellipse table; Eliminate the pixels of the best ellipse from the image; Empty the accumulator; } 

References Edit

  1. ^ D.H. Ballard, "Generalizing the Hough Transform to Detect Arbitrary Shapes", Pattern Recognition, Vol.13, No.2, p.111-122, 1981
  2. ^ L. Xu, E. Oja, and P. Kultanan, "A new curve detection method: Randomized Hough transform (RHT)", Pattern Recog. Lett. 11, 1990, 331-338.
  3. ^ S. Inverso, “Ellipse Detection Using Randomized Hough Transform”, www.saminverso.com/res/vision/EllipseDetectionOld.pdf, May 20, 2002

randomized, hough, transform, hough, transforms, techniques, object, detection, critical, step, many, implementations, computer, vision, data, mining, from, images, specifically, probabilistic, variant, classical, hough, transform, commonly, used, detect, curv. Hough transforms are techniques for object detection a critical step in many implementations of computer vision or data mining from images Specifically the Randomized Hough transform is a probabilistic variant to the classical Hough transform and is commonly used to detect curves straight line circle ellipse etc 1 The basic idea of Hough transform HT is to implement a voting procedure for all potential curves in the image and at the termination of the algorithm curves that do exist in the image will have relatively high voting scores Randomized Hough transform RHT is different from HT in that it tries to avoid conducting the computationally expensive voting process for every nonzero pixel in the image by taking advantage of the geometric properties of analytical curves and thus improve the time efficiency and reduce the storage requirement of the original algorithm Contents 1 Motivation 2 Implementation 2 1 Ellipse fitting 2 2 Accumulating 2 3 Termination 3 ReferencesMotivation EditAlthough Hough transform HT has been widely used in curve detection it has two major drawbacks 2 First for each nonzero pixel in the image the parameters for the existing curve and redundant ones are both accumulated during the voting procedure Second the accumulator array or Hough space is predefined in a heuristic way The more accuracy needed the higher parameter resolution should be defined These two needs usually result in a large storage requirement and low speed for real applications Therefore RHT was brought up to tackle this problem Implementation EditIn comparison with HT RHT takes advantage of the fact that some analytical curves can be fully determined by a certain number of points on the curve For example a straight line can be determined by two points and an ellipse or a circle can be determined by three points The case of ellipse detection can be used to illustrate the basic idea of RHT The whole process generally consists of three steps Fit ellipses with randomly selected points Update the accumulator array and corresponding scores Output the ellipses with scores higher than some predefined threshold Ellipse fitting Edit One general equation for defining ellipses is a x p 2 2 b x p y q c y q 2 1 displaystyle a x p 2 2b x p y q c y q 2 1 with restriction a c b 2 gt 0 displaystyle ac b 2 gt 0 However an ellipse can be fully determined if one knows three points on it and the tangents in these points RHT starts by randomly selecting three points on the ellipse Let them be X 1 displaystyle X 1 X 2 displaystyle X 2 and X 3 displaystyle X 3 The first step is to find the tangents of these three points They can be found by fitting a straight line using least squares technique for a small window of neighboring pixels The next step is to find the intersection points of the tangent lines This can be easily done by solving the line equations found in the previous step Then let the intersection points be T 12 displaystyle T 12 and TT 23 displaystyle T 23 the midpoints of line segments X 1 X 2 displaystyle X 1 X 2 and X 2 X 3 displaystyle X 2 X 3 be M 12 displaystyle M 12 and M 23 displaystyle M 23 Then the center of the ellipse will lie in the intersection of T 12 M 12 displaystyle T 12 M 12 and T 23 M 23 displaystyle T 23 M 23 Again the coordinates of the intersected point can be determined by solving line equations and the detailed process is skipped here for conciseness Let the coordinates of ellipse center found in previous step be x 0 y 0 displaystyle x 0 y 0 Then the center can be translated to the origin with x x x 0 displaystyle x x x 0 and y y y 0 displaystyle y y y 0 so that the ellipse equation can be simplified to a x 2 2 b x y c y 2 1 displaystyle ax 2 2bx y cy 2 1 Now we can solve for the rest of ellipse parameters a displaystyle a b displaystyle b and c displaystyle c by substituting the coordinates of X 1 displaystyle X 1 X 2 displaystyle X 2 and X 3 displaystyle X 3 into the equation above Accumulating Edit With the ellipse parameters determined from previous stage the accumulator array can be updated correspondingly Different from classical Hough transform RHT does not keep grid of buckets as the accumulator array Rather it first calculates the similarities between the newly detected ellipse and the ones already stored in accumulator array Different metrics can be used to calculate the similarity As long as the similarity exceeds some predefined threshold replace the one in the accumulator with the average of both ellipses and add 1 to its score Otherwise initialize this ellipse to an empty position in the accumulator and assign a score of 1 Termination Edit Once the score of one candidate ellipse exceeds the threshold it is determined as existing in the image in other words this ellipse is detected and should be removed from the image and accumulator array so that the algorithm can detect other potential ellipses faster The algorithm terminates when the number of iterations reaches a maximum limit or all the ellipses have been detected Pseudo code for RHT 3 while we find ellipses AND not reached the maximum epoch for a fixed number of iterations Find a potential ellipse if the ellipse is similar to an ellipse in the accumulator then Replace the one in the accumulator with the average of two ellipses and add 1 to the score else Insert the ellipse into an empty position in the accumulator with a score of 1 Select the ellipse with the best score and save it in a best ellipse table Eliminate the pixels of the best ellipse from the image Empty the accumulator References Edit D H Ballard Generalizing the Hough Transform to Detect Arbitrary Shapes Pattern Recognition Vol 13 No 2 p 111 122 1981 L Xu E Oja and P Kultanan A new curve detection method Randomized Hough transform RHT Pattern Recog Lett 11 1990 331 338 S Inverso Ellipse Detection Using Randomized Hough Transform www saminverso com res vision EllipseDetectionOld pdf May 20 2002 Retrieved from https en wikipedia org w index php title Randomized Hough transform amp oldid 1118868926, wikipedia, wiki, book, books, library,

article

, read, download, free, free download, mp3, video, mp4, 3gp, jpg, jpeg, gif, png, picture, music, song, movie, book, game, games.