feature detection
play

Feature Detection ] Logistics Write the use of free late days - PowerPoint PPT Presentation

Feature Detection ] Logistics Write the use of free late days right below the title. We only grade the latest submission. Regrading requests are allowed 2 weeks after the grade release. Wednesday lecture from 9:50am 10:40am


  1. Feature Detection ]

  2. Logistics • Write the use of free late days right below the title. • We only grade the latest submission. • Regrading requests are allowed 2 weeks after the grade release. • Wednesday lecture from 9:50am – 10:40am this week. • Office hours

  3. Overview of today’s lecture classical approach before ConvNets • Why you want to find features. • Harris corner detector. • Multi-scale detection. • Multi-scale blob detection.

  4. Planar object instance recognition Database of planar objects Instance recognition

  5. 3D object recognition Database of 3D objects 3D objects recognition

  6. Recognition under occlusion

  7. Location Recognition

  8. Robot Localization

  9. Image matching

  10. NASA Mars Rover images Where are the corresponding points?

  11. Challenges: Invariance Find features that are invariant to transformations • geometric invariance: translation, rotation, scale • photometric invariance: brightness, exposure, …

  12. Two Problems for Features Feature detection

  13. Two Problems for Features Feature detection Feature descriptor

  14. Two Problems for Features Feature detection Feature descriptor

  15. How do you solve feature detection & matching in CNN

  16. How do you solve feature detection & matching in CNN Yes CNN No CNN CNN No CNN Yes CNN Yes No CNN

  17. What makes a good feature? Zoom-in demo

  18. Want uniqueness Look for unusual image regions • Lead to unambiguous matches in other images How to define “unusual”?

  19. Local measures of uniqueness Consider a small window of pixels • Where are features good and bad? Slide adapted from Darya Frolova, Denis Simakov, Weizmann Institute.

  20. Local measures of uniqueness Consider a small window of pixels • Where are features good and bad? Slide adapted from Darya Frolova, Denis Simakov, Weizmann Institute.

  21. Feature detection Uniqueness = How does it change when shifted by a small amount ? “corner”: “flat” region: “edge”: significant change in no change in all no change along the all directions directions edge direction Slide adapted from Darya Frolova, Denis Simakov, Weizmann Institute.

  22. Feature detection Define E(u,v) = amount of change when you shift the window by (u,v) E(u,v) is small E(u,v) is small E(u,v) is small for no shifts for all shifts for some shifts We want to be ______

  23. Feature detection: the math Consider shifting the window W by (u,v) • how do the pixels in W change? • compare each pixel before and after by Sum of the Squared Differences (SSD) W • this defines an SSD “error” E(u,v) :

  24. Small motion assumption Taylor Series expansion of I: If the motion (u,v) is small, then first order approx is good Plugging this into the formula on the previous slide…

  25. Feature detection: the math Consider shifting the window W by (u,v) • how do the pixels in W change? • compare each pixel before and after by summing up the squared differences W • this defines an “error” of E(u,v):

  26. Feature detection: the math This can be rewritten:

  27. Feature detection: the math This can be rewritten: Which [u v] maximizes E(u,v)? Which [u v] minimizes E(u,v)?

  28. Feature detection: the math This can be rewritten: Which [u v] maximizes E(u,v)? Which [u v] minimizes E(u,v)?

  29. Feature detection: the math This can be rewritten: x - x + x + Eigenvector with the largest eigen value? x - Eigenvector with the smallest eigen value?

  30. Quick eigenvalue/eigenvector review The eigenvectors of a matrix A are the vectors x that satisfy: The scalar λ is the eigenvalue corresponding to x • The eigenvalues are found by solving: • In our case, A = H is a 2x2 matrix, so we have • The solution:

  31. Feature detection Local measure of feature uniqueness • E(u,v) = amount of change when you shift the window by (u,v) E(u,v) is small E(u,v) is small E(u,v) is small for no shifts for all shifts for some shifts We want to be large =

  32. Eigenvalues of H ? ?

  33. Eigenvalues of H

  34. Feature detection summary Here’s what you do • Compute the gradient at each point in the image • Create the H matrix from the entries in the gradient • Compute the eigenvalues. • Find points with large response ( λ - > threshold) • Choose those points where λ - is a local maximum as features

  35. Feature detection summary Here’s what you do • Compute the gradient at each point in the image • Create the H matrix from the entries in the gradient • Compute the eigenvalues. • Find points with large response ( λ - > threshold) • Choose those points where λ - is a local maximum as features Called “non-local max suppression”

  36. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 Flat

  37. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat

  38. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 ?

  39. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 Edge

  40. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 Edge 2.5 3 1.36 ?

  41. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 Edge 2.5 3 1.36 Corner

  42. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 Edge 2.5 3 1.36 Corner 5 6 2.73 ?

  43. The Harris operator λ - is a variant of the “Harris operator” for feature detection f 0.03 0.02 0.012 Flat 3 0.02 0.02 Edge 2.5 3 1.36 Corner 5 6 2.73 Strong corner

  44. The Harris operator λ - is a variant of the “Harris operator” for feature detection • The trace is the sum of the diagonals, i.e., trace(H) = h 11 + h 22 • Very similar to λ - but less expensive (no square root) • Called the “Harris Corner Detector” or “Harris Operator” • Lots of other detectors, this is one of the most popular

  45. The Harris operator Harris operator

  46. Harris detector example

  47. f value (red high, blue low)

  48. Threshold (f > value)

  49. Find local maxima of f

  50. Harris features (in red)

  51. Harris corner response is invariant to rotation Ellipse rotates but its shape ( eigenvalues ) remains the same Corner response R is invariant to image rotation

  52. Harris corner response is invariant to intensity changes Partial invariance to affine intensity change • Only derivatives are used => invariance to intensity shift I → I + b • Intensity scale: I → a I R R threshold x (image coordinate) x (image coordinate)

  53. The Harris detector is not invariant to changes in …

  54. The Harris corner detector is not invariant to scale edge! corner!

  55. Multi-scale detection

  56. Scale invariant detection Suppose you’re looking for corners Key idea: find scale that gives local maximum of f • f is a local maximum in both position and scale

  57. Lindeberg et al, 1996 Lindeberg et al., 1996 Slide from Tinne Tuytelaars Slide from Tinne Tuytelaars

  58. References Basic reading: Szeliski textbook, Sections 4.1. •

Recommend


More recommend