← Computer Vision for EveryoneToolsInVisionLearning Center
Cameras and Geometry · Lesson 3

Calibration and Lens Distortion

Straight building edges sometimes curve near the edge of a photograph.

Watch the lesson

Calibration and Lens Distortion explained visually

1:40

Straight building edges sometimes curve near the edge of a photograph. English captions are optional and start off. The complete transcript follows the written lesson.

Lesson overview

What you will learn

Straight building edges sometimes curve near the edge of a photograph.

  1. Separate camera properties from pose
  2. Gather varied observations
  3. Check calibration quality
  4. A worked example
01

Separate camera properties from pose

Straight building edges sometimes curve near the edge of a photograph. Lens distortion can cause that effect, and it matters when image coordinates support measurements. Camera calibration estimates parameters that connect the camera model to observed pixels. Intrinsic parameters describe properties such as focal lengths and principal point; extrinsic parameters describe the camera's pose relative to a chosen world frame.

02

Gather varied observations

A common calibration procedure observes a target with known geometry from several orientations and positions. Variety is important. Repeating nearly the same view provides less useful geometric information than covering different parts of the image with different tilts. The target dimensions must be measured correctly, and detected target points must correspond to the intended physical locations.

03

Check calibration quality

Reprojection error compares observed image points with points predicted by the estimated model. A low error is useful evidence, but it is not the only check. Inspect coverage across the image, stability on held-out views, and whether the model fits the camera. Recalibration may be needed if focus, zoom, resolution, or mounting conditions change. Save the calibration together with its camera settings and date so that it is not accidentally applied to unrelated images.

04

A worked example

Suppose a known target point is observed at pixel one hundred, eighty, while the calibrated model predicts one hundred and three, eighty-four. Its Euclidean reprojection error is five pixels, because the horizontal and vertical errors are three and four pixels. Report aggregate errors as well as problematic individual views.

Worked example

Suppose a known target point is observed at pixel 100, 80, while the calibrated model predicts 103, 84. Its Euclidean reprojection error is five pixels, because the horizontal and vertical errors are three and four pixels. Report aggregate errors as well as problematic individual views.

Knowledge check

Quick check: test your understanding

Try it yourself: Why might a calibration made at one zoom setting be unsuitable after changing the zoom?

Check the reasoning

Zoom can change the effective focal length and other imaging properties, so the old intrinsic parameters may no longer describe the camera.

Does a low fitting error prove perfect real-world measurements?

No. Target errors, limited view coverage, model mismatch, and measurement conditions can still matter.

How would you solve the practice case?

Zoom can change the effective focal length and other imaging properties, so the old intrinsic parameters may no longer describe the camera.

What does the worked example show?

Suppose a known target point is observed at pixel 100, 80, while the calibrated model predicts 103, 84. Its Euclidean reprojection error is five pixels, because the horizontal and vertical errors are three and four pixels. Report aggregate errors as well as problematic individual views.

Further reading

Programming Computer Vision with Python — Jan Erik Solem.

Original ToolsInVision teaching examples. Editorial approach · Suggest a correction

Accessible referenceLesson 3 transcript239 words · Video transcript · Matches the published narration and captionsOpen transcript

Straight building edges sometimes curve near the edge of a photograph. Lens distortion can cause that effect, and it matters when image coordinates support measurements. Camera calibration estimates parameters that connect the camera model to observed pixels. Intrinsic parameters describe properties such as focal lengths and principal point; extrinsic parameters describe the camera's pose relative to a chosen world frame.

A common calibration procedure observes a target with known geometry from several orientations and positions. Variety is important. Repeating nearly the same view provides less useful geometric information than covering different parts of the image with different tilts. The target dimensions must be measured correctly, and detected target points must correspond to the intended physical locations.

Reprojection error compares observed image points with points predicted by the estimated model. A low error is useful evidence, but it is not the only check. Inspect coverage across the image, stability on held-out views, and whether the model fits the camera. Recalibration may be needed if focus, zoom, resolution, or mounting conditions change. Save the calibration together with its camera settings and date so that it is not accidentally applied to unrelated images.

Suppose a known target point is observed at pixel one hundred, eighty, while the calibrated model predicts one hundred and three, eighty-four. Its Euclidean reprojection error is five pixels, because the horizontal and vertical errors are three and four pixels. Report aggregate errors as well as problematic individual views.