Object Detection 01 – Basic Hough Transformation JJCAO.

Slides:



Advertisements
Similar presentations
Object Recognition from Local Scale-Invariant Features David G. Lowe Presented by Ashley L. Kapron.
Advertisements

Fitting: The Hough transform. Voting schemes Let each feature vote for all the models that are compatible with it Hopefully the noise features will not.
Image Segmentation Image segmentation (segmentace obrazu) –division or separation of the image into segments (connected regions) of similar properties.
Hough Transform Reading Watt, An edge is not a line... How can we detect lines ?
Segmentation (2): edge detection
Edge Detection CSE P 576 Larry Zitnick
Fitting: The Hough transform
Lecture 5 Hough transform and RANSAC
1Ellen L. Walker Segmentation Separating “content” from background Separating image into parts corresponding to “real” objects Complete segmentation Each.
GENERALIZED HOUGH TRANSFORM. Recap on classical Hough Transform 1.In detecting lines – The parameters  and  were found out relative to the origin (0,0)
Object Recognition A wise robot sees as much as he ought, not as much as he can Search for objects that are important lamps outlets wall corners doors.
Edge Detection Today’s reading Forsyth, chapters 8, 15.1
Fitting a Model to Data Reading: 15.1,
CS 376b Introduction to Computer Vision 04 / 15 / 2008 Instructor: Michael Eckmann.
Edge Detection Today’s readings Cipolla and Gee –supplemental: Forsyth, chapter 9Forsyth Watt, From Sandlot ScienceSandlot Science.
Fitting: The Hough transform
Edge Detection.
Robust estimation Problem: we want to determine the displacement (u,v) between pairs of images. We are given 100 points with a correlation score computed.
כמה מהתעשייה? מבנה הקורס השתנה Computer vision.
Computer Vision Spring ,-685 Instructor: S. Narasimhan Wean Hall 5409 T-R 10:30am – 11:50am.
October 8, 2013Computer Vision Lecture 11: The Hough Transform 1 Fitting Curve Models to Edges Most contours can be well described by combining several.
Computer Vision - Fitting and Alignment
Hough Transform on the GPU Presented by Javier Garcia November 29, 2010.
Computer Vision More Image Features Hyunki Hong School of Integrative Engineering.
Segmentation Course web page: vision.cis.udel.edu/~cv May 7, 2003  Lecture 31.
Fitting: The Hough transform. Voting schemes Let each feature vote for all the models that are compatible with it Hopefully the noise features will not.
Fitting & Matching Lecture 4 – Prof. Bregler Slides from: S. Lazebnik, S. Seitz, M. Pollefeys, A. Effros.
HOUGH TRANSFORM Presentation by Sumit Tandon
HOUGH TRANSFORM & Line Fitting Introduction  HT performed after Edge Detection  It is a technique to isolate the curves of a given shape / shapes.
Hough Transform : A preliminary study Indranil Das HEP Devn., SINP.
Fitting : Voting and the Hough Transform Monday, Feb 14 Prof. Kristen Grauman UT-Austin.
Object Detection 01 – Advance Hough Transformation JJCAO.
CS 1699: Intro to Computer Vision Matching and Fitting Prof. Adriana Kovashka University of Pittsburgh September 29, 2015.
Generalized Hough Transform
Edges. Edge detection schemes can be grouped in three classes: –Gradient operators: Robert, Sobel, Prewitt, and Laplacian (3x3 and 5x5 masks) –Surface.
CSSE463: Image Recognition Day 25 This week This week Today: Finding lines and circles using the Hough transform (Sonka 6.26) Today: Finding lines and.
Mestrado em Ciência de Computadores Mestrado Integrado em Engenharia de Redes e Sistemas Informáticos VC 14/15 – TP8 Segmentation Miguel Tavares Coimbra.
Lecture 08 Detecting Shape Using Hough Transform Lecture 08 Detecting Shape Using Hough Transform Mata kuliah: T Computer Vision Tahun: 2010.
CS654: Digital Image Analysis Lecture 25: Hough Transform Slide credits: Guillermo Sapiro, Mubarak Shah, Derek Hoiem.
Fitting: The Hough transform
Edge Detection and Geometric Primitive Extraction Jinxiang Chai.
EECS 274 Computer Vision Model Fitting. Fitting Choose a parametric object/some objects to represent a set of points Three main questions: –what object.
Fitting Thursday, Sept 24 Kristen Grauman UT-Austin.
Computer Vision - Fitting and Alignment (Slides borrowed from various presentations)
Hough Transform Procedure to find a shape in an image Shape can be described in parametric form Shapes in image correspond to a family of parametric solutions.
October 16, 2014Computer Vision Lecture 12: Image Segmentation II 1 Hough Transform The Hough transform is a very general technique for feature detection.
Image Segmentation Image segmentation (segmentace obrazu)
Digital Image Processing Lecture 17: Segmentation: Canny Edge Detector & Hough Transform Prof. Charlene Tsai.
Hough Transform. Introduction The Hough Transform is a general technique for extracting geometrical primitives from e.g. edge data Performed after Edge.
Detecting Image Features: Corner. Corners Given an image, denote the image gradient. C is symmetric with two positive eigenvalues. The eigenvalues give.
Hough Transform CS 691 E Spring Outline Hough transform Homography Reading: FP Chapter 15.1 (text) Some slides from Lazebnik.
Object Recognition. Segmentation –Roughly speaking, segmentation is to partition the images into meaningful parts that are relatively homogenous in certain.
1 Hough Transform. 2 A Technique to Isolate Features of a Particular Shape within an Image The classical Hough transform is most commonly used for the.
CSSE463: Image Recognition Day 26
Fitting: Voting and the Hough Transform
Miguel Tavares Coimbra
Line Fitting James Hayes.
Detection of discontinuity using
Fitting: The Hough transform
Exercise Class 11: Robust Tecuniques RANSAC, Hough Transform
Fitting: Voting and the Hough Transform (part 2)
Fitting Curve Models to Edges
CSSE463: Image Recognition Day 26
CSSE463: Image Recognition Day 26
Hough Transform.
Morphological Operators
CSSE463: Image Recognition Day 27
CSSE463: Image Recognition Day 26
CSSE463: Image Recognition Day 26
Introduction to Artificial Intelligence Lecture 22: Computer Vision II
Presentation transcript:

Object Detection 01 – Basic Hough Transformation JJCAO

What do you see?

“Puzzle” solved from a new view

Different view, different domain ? ! The same problem, phenomenon or data set, when viewed from a different angle, or in a new domain, may better reveal its underlying structure to facilitate the solution

Line and curve detection Find lines, curves, or parts of lines or curves in an input image. Such an image might be the output of a edge detector Hough Transform: Elegant method for direct object recognition – Edges need not be connected – Complete object need not be visible – Key Idea: Edges VOTE for the possible model 10 Detect partially occluded lines

Hough transforms oObject detection → peaks identification in Hough images oHough59: P.V.C. Hough, A method for faster analysis of bubble chamber photographs, International Conference on High Energy Accelerators and Instrumentation, 1959, cited times: 33 oUSE OF THE HOUGH TRASFORMTION TO DETECT LINES and Curves in Pictures_duda_CommunAcm71, cited times: 2623 oGENERALIZING THE HOUGH TRANSFORM TO DETECT ARBITRARY SHAPES_Ballard_pr81, cited times: 2476 oA survey of the hough transform_Illingworth_CVGIP88, cited times: 1339

Beyond lines!!! Hough transform is a method for estimating the parameters of a shape from its boundary points The idea can be generalized to estimate “parameters” of arbitrary shapes – Ballard 1981 – Other primitives – Lowe, ICCV 1999 – Object detection – Leibe, Schiele BMVC 2003 – Object class detection – CVPR 2009: Maji& Malik, Gall& Lempitsky, Gu et al. … – CVPR 2010: Bari, Lemp & Kohli 12

HT for Lines: representation 1 straight line in image space: y = mx+ b, is plotted for each pair of values (x, y). What is the characteristic of the line? – Not x or y – But its slope m and intercept b A line in the image corresponds to a point in Hough space 13 Image spaceHough parameter space Source: S. Seitz

Parameter space representation What does a point (x 0, y 0 ) in the image space map to in the Hough space? Image spaceHough parameter space

Parameter space representation What does a point (x 0, y 0 ) in the image space map to in the Hough space? – Answer: the solutions of b = –x 0 m + y 0 – This is a line in Hough space Image spaceHough parameter space

Parameter space representation Where is the line that contains both (x 0, y 0 ) and (x 1, y 1 )? Image spaceHough parameter space (x 0, y 0 ) (x 1, y 1 ) b = –x 1 m + y 1

Parameter space representation Where is the line that contains both (x 0, y 0 ) and (x 1, y 1 )? – It is the intersection of the lines b = –x 0 m + y 0 and b = –x 1 m + y 1 Image spaceHough parameter space (x 0, y 0 ) (x 1, y 1 ) b = –x 1 m + y 1

HT for Lines: representation 1 18 Parameter space (b,m) b=y-mx Image space y=mx+b (x,y) Parameter Space

Line Detection by Hough Transform Parameter Space Algorithm: Quantize Parameter Space Create Accumulator Array Set For each image edge increment: If lies on the line: Find local maxima in

HT for Lines: representation 2 20

HT for Lines 21 Parameter space (b,m) Image space y=mx+b (x,y)

HT for Lines - Computation How to find the intersection point? 22

Algorithm HOUGH_LINES 23 Is any pixels a voter?

Several lines

HT lines: local max & threshold 25 Image space votes Horizontal axis is θ, vertical is rho.

Dealing with noise Try to get rid of irrelevant features – Take only edge points with significant gradient magnitude Choose a good grid / discretization – Too coarse: large votes obtained when too many different lines correspond to a single bucket – Too fine: miss lines because some points that are not exactly collinear cast votes for different buckets Increment neighboring bins  smoothing in accumulator array

27 HT for lines: noisy example

A more complicated image

HT lines: Problem of parameter ranges 29 Vertical flip P n

HT lines: Parameter ranges 30

HT lines: Parameter ranges 31

Real World Example Original Edge Detection Found Lines Parameter Space Could we extract better edges?

Algorithm HOUGH_line (weight) 33 Is any pixels a voter? Gradient(i,j)

Hough_Grd Recall: when we detect an edge point, we also know its gradient direction But this means that the line is uniquely determined! Modified Hough transform: For each edge point (x,y) θ = gradient orientation at (x,y) ρ = x cos θ + y sin θ A(θ, ρ) = A(θ, ρ) + 1 end Θ=[0-360] so there is a conversion

EE Computer Vision 35 Computational Load

Mechanics of the Hough transform Difficulties – how big should the cells be? (too big, and we merge quite different lines; too small, and noise causes lines to be missed) How many lines? – Count the peaks in the Hough array – Treat adjacent peaks as a single peak Which points belong to each line? – Search for points close to the line – Solve again for line and iterate

HT for high dimensional Parameter Curves 37

Parameters for analytic curves Analytic FormParametersEquation Line , xcos+ysin= Circle x 0, y 0,  (x-x o ) 2 +(y-y 0 ) 2 =r 2 Parabola x 0, y 0, (y-y 0 ) 2 =4(x-x o ) Ellipse x 0, y 0, a, b, (x-x o ) 2 /a 2 +(y-y 0 ) 2 /b 2 =1

Summary Feature extraction technique in cv Purpose of it is to find imperfect (partially occluded, noisy) instances of objects within a certain class of shapes By a voting procedure: – Discretize parameter space into bins – For each feature point in the image, put a vote in every bin in the parameter space that could have generated this point – Find bins that have the most votes Since each point is handled independently, parallel implementations are possible It becomes difficult when the dimension of the parameter space is large 39

HT for Circles: Search with fixed R Equation of Circle:

Multiple Circles with known R Multiple circles with the same radius can be found with the same technique. The centerpoints are represented as red cells in the parameter space drawing. Overlap of circles can cause spurious centers to also be found, such as at the blue cell. Spurious circles can be removed by matching to circles in the original image. 41

HT for Circles: Search with unknown R Equation of Circle: If radius is not known: 3D Hough Space! Use Accumulator array What is the surface in the hough space?

Hough transform for circles x y (x,y) x y r image spaceHough parameter space

44

Generalized Hough transform We want to find a shape defined by its boundary points and a reference point D. Ballard, Generalizing the Hough Transform to Detect Arbitrary Shapes, Pattern Recognition 13(2), 1981, pp a

Generalized Hough transform We want to find a shape defined by its boundary points and a reference point For every boundary point p, we can store the displacement vector r = a – p as indexed by gradient orientation θ D. Ballard, Generalizing the Hough Transform to Detect Arbitrary Shapes, Pattern Recognition 13(2), 1981, pp (x c,y c ) θiθi riririri PiPiPiPi iiii x c = x i + r i cos(  i ) y c = y i + r i sin(  i )

Generalizing the H.T. (x c,y c ) PiPiPiPi iiii riririri iiii x c = x i + r i cos(  i ) y c = y i + r i sin(  i ) Suppose, there were m different gradient orientations: (m <= n) Suppose, there were m different gradient orientations: (m <= n) 112 mm112 mm... (r 1 1,  1 1 ),(r 1 2,  1 2 ),…,(r 1 n1,  1 n1 ) (r 2 1,  2 1 ),(r 2 2,  1 2 ),…,(r 2 n2,  1 n2 )... (r m 1,  m 1 ),(r m 2,  m 2 ),…,(r m nm,  m nm ) jjjj rjrjrjrj jjjj R-table

Example model shape

Example displacement vectors for model points

Example range of voting locations for test point

Example range of voting locations for test point

Example votes for points with θ =

Example displacement vectors for model points

Example range of voting locations for test point

votes for points with θ = Example

Generalized Hough Transform Find Object Center given edges Create Accumulator Array Initialize: For each edge point For each entry in table, compute: Increment Accumulator: Find Local Maxima in Assumption: translation is the only transformation here, i.e., orientation and scale are fixed

Voting schemes Let each feature vote for all the models that are compatible with it Hopefully the noise features will not vote consistently for any single model Missing data doesn’t matter as long as there are enough features remaining to agree on a good model

Applications 59

Measuring local gradient saliency Gradient => Gradient saliency 60 GradientShop: A Gradient-Domain Optimization Framework for Image and Video Filtering_tog09

Speed up – Kernel Based HT 61 Real-time line detection through an improved Hough transform voting scheme_pr08, cited times: 72

More A new curve detection method: Randomized Hough transform (RHT)_prl90, cited times: 555 An improved Hough transform voting scheme utilizing surround suppression_prl_09 An Improved Hough Transform Neighborhood Map for Straight Line Segments_tip10 A probabilistic Hough transform_pr91 Progressive Probabilistic hough transform_98 62