Perspective Warps and Planar Maps
A photographed document looks like a trapezoid, but its page is approximately flat.
Perspective Warps and Planar Maps explained visually
A photographed document looks like a trapezoid, but its page is approximately flat. English captions are optional and start off. The complete transcript follows the written lesson.
What you will learn
A photographed document looks like a trapezoid, but its page is approximately flat.
Map one plane to another
A photographed document looks like a trapezoid, but its page is approximately flat. A perspective warp can map that plane into a more readable rectangular view. The mathematical mapping is called a homography. It connects corresponding points on a plane between views, subject to the assumptions of the camera geometry.
Estimate reliable correspondences
Estimating a homography requires enough reliable point correspondences in a suitable configuration. Four non-collinear correspondences are the minimum for the usual unconstrained planar mapping, but more observations can improve robustness. Incorrect matches can distort the result badly. Check the mapping on points that were not used to fit it, and inspect how image interpolation affects the output.
Know what a plane excludes
A ground-plane mapping is useful for a parking lot, but an elevated point on a vehicle is not on that plane. Mapping the top of the vehicle as if it touched the ground creates a position error. Use a point that reasonably represents ground contact and document the approximation. Also remember that a perspective warp changes pixel density across the result. It can normalize geometry without creating detail that the original image did not resolve.
A worked example
If a car's bounding box extends from its roof to the road, the bottom-center point may approximate its ground contact better than the box center. That is a modeling choice, not a guarantee: occlusion and box errors can still move the estimated contact point.
Worked example
If a car's bounding box extends from its roof to the road, the bottom-center point may approximate its ground contact better than the box center. That is a modeling choice, not a guarantee: occlusion and box errors can still move the estimated contact point.
Quick check: test your understanding
Try it yourself: Why can a bird-eye transformation align road markings but distort a tall pole?
Check the reasoning
The road markings lie close to the mapped plane, while points along the pole rise above it and violate the planar assumption.
Can any four matched points provide a stable homography?
No. Degenerate arrangements, such as collinear points, and inaccurate matches can prevent a reliable estimate.
How would you solve the practice case?
The road markings lie close to the mapped plane, while points along the pole rise above it and violate the planar assumption.
What does the worked example show?
If a car's bounding box extends from its roof to the road, the bottom-center point may approximate its ground contact better than the box center. That is a modeling choice, not a guarantee: occlusion and box errors can still move the estimated contact point.
Further reading
Programming Computer Vision with Python — Jan Erik Solem.
Original ToolsInVision teaching examples. Editorial approach · Suggest a correction
Accessible referenceLesson 4 transcript226 words · Video transcript · Matches the published narration and captionsOpen transcript
A photographed document looks like a trapezoid, but its page is approximately flat. A perspective warp can map that plane into a more readable rectangular view. The mathematical mapping is called a homography. It connects corresponding points on a plane between views, subject to the assumptions of the camera geometry.
Estimating a homography requires enough reliable point correspondences in a suitable configuration. Four non-collinear correspondences are the minimum for the usual unconstrained planar mapping, but more observations can improve robustness. Incorrect matches can distort the result badly. Check the mapping on points that were not used to fit it, and inspect how image interpolation affects the output.
A ground-plane mapping is useful for a parking lot, but an elevated point on a vehicle is not on that plane. Mapping the top of the vehicle as if it touched the ground creates a position error. Use a point that reasonably represents ground contact and document the approximation. Also remember that a perspective warp changes pixel density across the result. It can normalize geometry without creating detail that the original image did not resolve.
If a car's bounding box extends from its roof to the road, the bottom-center point may approximate its ground contact better than the box center. That is a modeling choice, not a guarantee: occlusion and box errors can still move the estimated contact point.