1 / 76

Caracteristicas de Imagens II

Caracteristicas de Imagens II. Fitting. Etapas. Borda=cadeia de pixels. Borda=tem um modelo. p Borda. Finding Connected Components. Fitting. Finding Connected Components (Sequential Algorithm 4-connectivity). Scan the binary image left to right top to bottom

denna
Télécharger la présentation

Caracteristicas de Imagens II

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Caracteristicas de Imagens II Fitting

  2. Etapas Borda=cadeia de pixels Borda=tem um modelo pBorda Finding Connected Components Fitting

  3. Finding Connected Components (Sequential Algorithm 4-connectivity) • Scan the binary image left to right top to bottom • If an unlabelled pixel has a value of 1, assign a new label to it according to the following rules: • Determine equivalence classes of labels. • In the second pass, assign the same label to all elements in an equivalence class. (Set L=M)

  4. Rules for 8-connectivity (Set L=M)

  5. Least Squares Fit

  6. Local maximum and local minimum • Horizontal tangent plane • Parallel to xy-plane • Relative extrema Alfer Demir

  7. Condição de máximo ou mínimo

  8. Ajuste de linha por LSF

  9. Ajuste de linha por LSF EXCEL LINEST(known_y's,known_x's,const,stats)

  10. y x y Line fitting can be max. likelihood - but choice of model is important x

  11. Distância euclidiana y di x

  12. Minimização baseada na distância euclidiana y Minimize E, sugeito a: x

  13. Minimizando com respeito a “c”

  14. Substituindo “c” de volta em E

  15. Novo problema: Minimize forma quadrática sugeito a: S é simétrica e positiva definida.

  16. Mínimo de formas quadráticas de matrizes simétricas positivas definidas

  17. Autovetores e autovalores de matrizes simétricas positivas definidas

  18. x' y' Minimização como um problema de autovalores y p x mínimo

  19. Minimização baseada na distância euclidiana

  20. Maximum Likelihood Maximize the Log likelihood function L Given constraint

  21. Fitting as a Probabilistic Inference Problem • Generative model • The measurements are generated by a line with additive Gaussian noise • The likelihood function given by • Maximum likelihood

  22. Multiplicadores de Lagrange sugeito a: Minimize Minimize  Minimize

  23. Maximo e mínimo sugeito a restrições ...

  24. Multiplicador de Lagrange ...

  25. Outliers

  26. comportamento desejado

  27. Who came from which line? • Assume we know how many lines there are - but which lines are they? • easy, if we know who came from which line • Strategies • Incremental line fitting • K-means

  28. Fitting Curves

  29. Fitting Curves – cont.

  30. Distâncias algébrica e euclidiana y x

  31. Hough Transform • There are three problems in model fitting • Given the points that belong to a line, what is the line? • Which points belong to which line? • How many lines are there? • Hough transform is a technique for these problems • The basic idea is to record all the models on which each point lies and then look for models that get many votes

  32. Hough Transform – cont. • Straight line case • Consider a single isolated edge point (xi, yi) • There are an infinite number of lines that could pass through the points • Each of these lines can be characterized by some particular equation

  33. Hough Transform – cont. y c m x

  34. Hough Transform – cont. c c m m ponto de maior contribuição

  35. Hough Transform – cont.

  36. Hough Transform – cont. • Hough transform algorithm 1. Find all of the desired feature points in the image 2. For each feature point For each possibility i in the accumulator that passes through the feature point Increment that position in the accumulator 3. Find local maxima in the accumulator 4. If desired, map each maximum in the accumulator back to image space

  37. y      0 x Hough Transform – cont. m e c  [- +]

  38. Hough Transform – cont. y x

  39. Hough Transform – cont. y x

  40. Transformada de Hough

  41. Transformada de Hough

  42. Hough Transform – cont. • Circles • Hough transform can also be used for circles

  43. Hough Transform – cont. Here the radius is fixed

  44. Hough Transform – cont. A 3-dimensional parameter space for circles in general

  45. Hough Transform – cont. • More complicated shapes • As you can see, the Hough transform can be used to find shapes with arbitrary complexity as long as we can describe the shape with some fixed number of parameters • The number of parameters required indicates the dimensionality of the accumulator

  46. Generalized Hough Transform • Some shapes may not be easily expressed using a small set of parameters • In this case, we explicitly list all the points on the shape • This variation of Hough transform is known as generalized Hough transform

  47. Construct an array representing q, d For each point, render the curve (q, d) into this array, adding one at each cell Difficulties how big should the cells be? (too big, and we cannot distinguish between quite different lines; too small, and noise causes lines to be missed) How many lines? count the peaks in the Hough array Who belongs to which line? tag the votes Hardly ever satisfactory in practice, because problems with noise and cell size defeat it Mechanics of the Hough transform

  48. Curve Fitting by Hough Transform • Let y=f (x,a) be the chosen parameterization of a target curve. • Discretize the intervals of variation of a1,… akand let s1,… skbe the number of the discretized intervals. • Let A(s1,… sk) be an array of integer counters and initialize all its elements to zero. • For each pixel E(i,j) such that E(i,j)=1, increment all counters on the curve defined by y=f (x,a) in A. • Find all local maxima above certain threshold.

More Related