Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching...
Transcript of Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching...
![Page 1: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/1.jpg)
Panorama Stitchingand Augmented Reality
![Page 2: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/2.jpg)
Local feature matching withlarge datasets
� Examples:
� Identify all panoramas and objects in an image set
� Identify all products in a supermarket
� Identify any location for robot localization or augmented reality
![Page 3: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/3.jpg)
Matching in large unordered datasets
![Page 4: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/4.jpg)
Matching in large unordered datasets
![Page 5: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/5.jpg)
Nearest-neighbor matching
� Solve following problem for all feature vectors, x:
� Nearest-neighbour matching is the major computational bottleneck� Linear search performs dn2 operations for n features
and d dimensions� No exact methods are faster than linear search for d>10� Approximate methods can be much faster, but at the
cost of missing some correct matches. Failure rate gets worse for large datasets.
![Page 6: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/6.jpg)
47
6
5
1
3
2
9
8
10
11
l5
l1 l9
l6
l3
l10 l7
l4
l8
l2
l1
l8
1
l2 l3
l4 l5 l7 l6
l9l10
3
2 5 4 11
9 10
8
6 7
Slide credit: Anna Atramentov
K-d tree construction
Simple 2D example
![Page 7: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/7.jpg)
47
6
5
1
3
2
9
8
10
11
l5
l1 l9
l6
l3
l10 l7
l4
l8
l2
l1
l8
1
l2 l3
l4 l5 l7 l6
l9l10
3
2 5 4 11
9 10
8
6 7
q
K-d tree query
Slide credit: Anna Atramentov
![Page 8: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/8.jpg)
Approximate k-d tree matching
Key idea:� Search k-d tree bins in
order of distance from query
� Requires use of a priority queue
![Page 9: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/9.jpg)
Fraction of nearest neighbors found
� 100,000 uniform points in 12 dimensions.
Results:� Speedup by
several orders of magnitude over linear search
![Page 10: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/10.jpg)
Panorama stitching (with Matthew Brown)
![Page 11: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/11.jpg)
Panorama stitching (with Matthew Brown)
![Page 12: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/12.jpg)
Bundle Adjustment
� New images initialised with rotation, focal length of best matching image
![Page 13: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/13.jpg)
Bundle Adjustment
� New images initialised with rotation, focal length of best matching image
![Page 14: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/14.jpg)
Multi-band Blending
� Burt & Adelson 1983� Blend frequency bands over range ∝ λ
![Page 15: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/15.jpg)
Low frequency (λ > 2 pixels)
High frequency (λ < 2 pixels)
2-band Blending
![Page 16: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/16.jpg)
Multi-band Blending
• Linear blending • Multi-band blending
![Page 17: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/17.jpg)
Automatic Straightening
![Page 18: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/18.jpg)
Automatic Straightening
• Heuristic: user does not twist camera relative to horizon
• Up-vector perpendicular to plane of camera x vectors
![Page 19: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/19.jpg)
Automatic Straightening
![Page 20: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/20.jpg)
Gain Compensation
• No gain compensation
![Page 21: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/21.jpg)
Gain Compensation
• Gain compensation
– Single gain parameter gi for each image
![Page 22: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/22.jpg)
� Free working demo available: Autostitch� Commercial products: Serif, Kolor, others coming
� Show in Java applet: Browser demo
Panoramas from handheld consumer cameras
![Page 23: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/23.jpg)
Autostitch usage in www.flickr.com
� Over 20,000 panoramas posted by users of free Autostitch demo
![Page 24: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/24.jpg)
Public images from Flickr
Surprise: Many users wantborders to be visible
![Page 25: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/25.jpg)
27
Applications:
– Film production (already in use)
– Heads-up display for cars
– Tourism
– Medicine, architecture, training
What is needed:
– Recognition of scene
– Accurate sub-pixel 3-D pose
– Real-time, low latency
Augmented Reality
![Page 26: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/26.jpg)
Augmented Reality(David Lowe & Iryna Gordon)
� Solve for 3D structure from multiple images
� Recognize scenes and insert 3D objects
Shows one of 20 images taken with handheld camera
![Page 27: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/27.jpg)
29
System overview
![Page 28: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/28.jpg)
30
Bundle adjustment: an example
20 input images
0 iterations: error = 62.5 pixels10 iterations: error = 4.2 pixels20 iterations: error = 1.7 pixels50 iterations: error = 0.2 pixels
![Page 29: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/29.jpg)
31
Incremental model construction
• Problems:– computation time increases with the number of unknown parameters– trouble converging if the cameras are too far apart (> 90 degrees)
• Solutions:– select a subset of about 4 images to construct an initial model– incrementally update the model by resectioning and triangulation– images processed in order determined by the spanning tree
![Page 30: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/30.jpg)
3D Structure and Virtual Object Placement
� Solve for cameras and 3D points:� Uses bundle adjustment (solution for camera
parameters and 3D point locations)� Initialize all cameras at the same location and points at
the same depths� Solve depth-reversal ambiguity by trying both options
� Insert object into scene:
Set location in one image, move along epipolar in other, adjust orientation
![Page 31: Panorama Stitching and Augmented Realitylowe/425/slides/11-PanoramasAR.pdf · Panorama Stitching and Augmented Reality. Local feature matching with large datasets Examples: Identify](https://reader033.fdocuments.in/reader033/viewer/2022043001/5f79bf1442a45f6ef54cac97/html5/thumbnails/31.jpg)
Augmentation Example
The virtual object is rendered with OpenGL, using