camera intrinsics calibration produces wild out-of-range principalPoint

Hi -
A student and I are performing calibration with estimateCameraParameters and checkerboard patterns. The error in reconstruction is low, but the principal Point returned is outside the range of the pixel array of the camera. For one of our cameras, it is negative when we fit with EstimateSkew=true (which causes an error when we try to create a camera object). But even if we set EstimateTangentialDistortion=false,EstimateSkew=false the principal point is out of range. The detected grid locations seem fine (they are on the image).
Any suggestions?
The calibration grid is sometimes a little blurry because it is small and the lens doesn't have a large depth of field (so sometimes the edges are just a bit blurry).
Thanks
Steve

3 Comments

We would need more information to reproduce and investigate this issue that you are facing.
Could you provide your calibration images and the version of MATLAB you are using?
I am here a while later with a probably similar error. I work with a small calibration pattern as you do (square size 3.75mm). The new version of Matlab (2025a) pop an error that claims patterns may be too similar across images. By doing debugging over matlab functions (modifying matlab functions to avoid sanity check and obtain the camera parameter object), I found out that the principal points is very off from the center, and occasionally negative - which indeed gives an error when, e.g., calling params.Intrinsics (see attached matlab output).
I still did not find a way to fix this. Did you manage to fix this issue somehow?
The value of 'principalPoint' is invalid. Expected principalPoint to be positive.
Error in
r = parseInputsSimulation(defaultParams,varargin{:});
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error in
r = parseInputs(varargin{:});
^^^^^^^^^^^^^^^^^^^^^^^^
Error in
this = this@vision.internal.cameraIntrinsicsImpl(varargin{:});
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error in
intrinsics = cameraIntrinsics(this.FocalLength, ...
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error in
K = params.Intrinsics.K;
^^^^^^^^^^^^^^^^^^^
Hi Stefano - Sorry, I don't have any updates here. Good luck! Best, Steve

Sign in to comment.

Answers (1)

You haven't provided data with which to repeat the calibration, so one can only guess. But if reconstruction error is low, the principal point is probably correct. It might mean you have a weird camera, but there is no fundamental requirement that the principal point lie within the pixel array boundaries.

Categories

Find more on MATLAB Support Package for USB Webcams in Help Center and File Exchange

Products

Release

R2022a

Asked:

on 19 Jan 2023

Edited:

on 16 Dec 2025

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!