Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Incorrect stereo camera calibration

Hi,

I'm trying to calibrate a stereo camera setup using OpenCV's standard calibrateCamera() and stereoCalibrate() functions. The cameras are mounted in a smartphone, approximately 35 mm apart from each other and they face the same direction.

The problem is that the stereo reconstruction using the results of the calibration gives huge distortions of the reconstructed scene. I think that this may be caused by wrong extrinsic parameters (relative rotation and translation of the cameras). Especially the translation look suspicious to me. As far as I understand, the length of the translation vector should be comparable to the distance between the cameras. However, the length of the T vector resulting from my calibration varies between 16.7 and 23.4 mm, depending on which of the following approaches I use:

  1. Checkerboard calibration pattern, square size 19x19 mm, 12x10 corners: a. Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions found in the intrinsic calibration as ultimate (CV_CALIB_FIX_INTRINSIC) b. Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions from intrinsic calibration as the initial values for optimization (CV_CALIB_USE_INTRINSIC_GUESS)

  2. Asymmetric circle grid, 9x3 circles, grid size 30.2 x 30.2 mm - the same two options a and b, as in point 1.

  3. One-step calibration using stereoCalibrate() only.

Have you got any experience with this problem? The detailed results of the calibration are attached in the PDF here. I also attach the original images I use, should anybody want to check the calibration themselves.

Incorrect stereo camera calibration

Hi,

I'm trying to calibrate a stereo camera setup using OpenCV's standard calibrateCamera() and stereoCalibrate() functions. The cameras are mounted in a smartphone, approximately 35 mm apart from each other and they face the same direction.

The problem is that the stereo reconstruction using the results of the calibration gives huge distortions of the reconstructed scene. I think that this may be caused by wrong extrinsic parameters (relative rotation and translation of the cameras). Especially the translation look suspicious to me. As far as I understand, the length of the translation vector should be comparable to the distance between the cameras. However, the length of the T vector resulting from my calibration varies between 16.7 and 23.4 mm, depending on which of the following approaches I use:

  1. Checkerboard calibration pattern, square size 19x19 mm, 12x10 corners: a. Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions found in the intrinsic calibration as ultimate (CV_CALIB_FIX_INTRINSIC) b. Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions from intrinsic calibration as the initial values for optimization (CV_CALIB_USE_INTRINSIC_GUESS)

  2. Asymmetric circle grid, 9x3 circles, grid size 30.2 x 30.2 mm - the same two options a and b, as in point 1.

  3. One-step calibration using stereoCalibrate() only.

Have you got any experience with this problem? The detailed results of the calibration are attached in the PDF here. I also attach the original images I use, should anybody someone want to check the calibration themselves.

Incorrect stereo camera calibration

Hi,

I'm trying to calibrate a stereo camera setup using OpenCV's standard calibrateCamera() and stereoCalibrate() functions. The cameras are mounted in a smartphone, approximately 35 mm apart from each other and they face the same direction.

The problem is that the stereo reconstruction using the results of the calibration gives huge distortions of the reconstructed scene. I think that this may be caused by wrong extrinsic parameters (relative rotation and translation of the cameras). Especially the translation look suspicious to me. As far as I understand, the length of the translation vector should be comparable to the distance between the cameras. However, the length of the T vector resulting from my calibration varies between 16.7 and 23.4 mm, depending on which of the following approaches I use:

  1. 1) Checkerboard calibration pattern, square size 19x19 mm, 12x10 corners: a.

    a) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions found in the intrinsic calibration as ultimate (CV_CALIB_FIX_INTRINSIC) b. )

    b) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions from intrinsic calibration as the initial values for optimization (CV_CALIB_USE_INTRINSIC_GUESS)

  2. 2) Asymmetric circle grid, 9x3 circles, grid size 30.2 x 30.2 mm - the same two options a and b, as in point 1.

  3. 3) One-step calibration using stereoCalibrate() only.

Have you got any experience with this problem? The detailed results of the calibration are attached in the PDF here. I also attach the original images I use, should someone want to check the calibration themselves.

Incorrect stereo camera calibration

Hi,

I'm trying to calibrate a stereo camera setup using OpenCV's standard calibrateCamera() and stereoCalibrate() functions. The cameras are mounted in a smartphone, approximately 35 mm apart from each other and they face the same direction.

The problem is that the stereo reconstruction using the results of the calibration gives huge distortions of the reconstructed scene. I think that this may be caused by wrong extrinsic parameters (relative rotation and translation of the cameras). Especially the translation look suspicious to me. As far as I understand, the length of the translation vector should be comparable to the distance between the cameras. However, the length of the T vector resulting from my calibration varies between 16.7 and 23.4 mm, depending on which of the following approaches I use:

1) Checkerboard calibration pattern, square size 19x19 mm, 12x10 corners:

a) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions found in the intrinsic calibration as ultimate (CV_CALIB_FIX_INTRINSIC)

b) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions from intrinsic calibration as the initial values for optimization (CV_CALIB_USE_INTRINSIC_GUESS)

2) Asymmetric circle grid, 9x3 circles, grid size 30.2 x 30.2 mm - the same two options a and b, as in point 1.

3) One-step calibration using stereoCalibrate() only.

Have you got any experience with this problem? The detailed results of the calibration are attached in the PDF here. I also attach the original images I use, should someone want to check the calibration themselves.

Update:

Matthieu, thank you for your response.

Yes, I am pretty sure, that the corners on the checkerboard are correctly detected, because I do the detection semi-manually, using Bouguet's Camera Calibration Toolbox for Matlab (afterwards I import the extracted corner positions to my OpenCV calibration program). The corners are detected with sub-pixel accuracy.

I repeated the whole calibration with a new checkerboard pattern, using 85 images of it. I also did the best I can to get rid of the blur. The results are not much better. The relative camera translation vector, which is a sanity check parameter for me, is now [-23.41713024477083; 0.05333133785688135; -7.846262984094929]. And the reconstruction is still distorted. As previously, I enclose the detailed results and the images.

Is the distortion model of the calibration procedure incompatible with my camera setup? Or is it maybe the small base length, that makes the optimization algorithm get stuck on some local minimum? What do you think?

PS. By the way, the results with the Camera Calibration Toolbox for Matlab are no better.

Incorrect stereo camera calibration

Hi,

I'm trying to calibrate a stereo camera setup using OpenCV's standard calibrateCamera() and stereoCalibrate() functions. The cameras are mounted in a smartphone, approximately 35 mm apart from each other and they face the same direction.

The problem is that the stereo reconstruction using the results of the calibration gives huge distortions of the reconstructed scene. I think that this may be caused by wrong extrinsic parameters (relative rotation and translation of the cameras). Especially the translation look suspicious to me. As far as I understand, the length of the translation vector should be comparable to the distance between the cameras. However, the length of the T vector resulting from my calibration varies between 16.7 and 23.4 mm, depending on which of the following approaches I use:

1) Checkerboard calibration pattern, square size 19x19 mm, 12x10 corners:

a) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions found in the intrinsic calibration as ultimate (CV_CALIB_FIX_INTRINSIC)

b) Independent intrinsic calibration of the cameras with calibrateCamera(), then stereo calibration with stereoCalibrate() using the cameras' matrices and distortions from intrinsic calibration as the initial values for optimization (CV_CALIB_USE_INTRINSIC_GUESS)

2) Asymmetric circle grid, 9x3 circles, grid size 30.2 x 30.2 mm - the same two options a and b, as in point 1.

3) One-step calibration using stereoCalibrate() only.

Have you got any experience with this problem? The detailed results of the calibration are attached in the PDF here. I also attach the original images I use, should someone want to check the calibration themselves.

Update:Update 2014-06-30:

Matthieu, thank you for your response.

Yes, I am pretty sure, that the corners on the checkerboard are correctly detected, because I do the detection semi-manually, using Bouguet's Camera Calibration Toolbox for Matlab (afterwards I import the extracted corner positions to my OpenCV calibration program). The corners are detected with sub-pixel accuracy.

I repeated the whole calibration with a new checkerboard pattern, using 85 images of it. I also did the best I can to get rid of the blur. The results are not much better. The relative camera translation vector, which is a sanity check parameter for me, is now [-23.41713024477083; 0.05333133785688135; -7.846262984094929]. And the reconstruction is still distorted. As previously, I enclose the detailed results and the images.

Is the distortion model of the calibration procedure incompatible with my camera setup? Or is it maybe the small base length, that makes the optimization algorithm get stuck on some local minimum? What do you think?

PS. By the way, the results with the Camera Calibration Toolbox for Matlab are no better.