1
votes

I want to reconstruct 3d scene using multi rgb cameras. The input data has no camera calibration information so I want to use bundle adjustment algorithm (Ceres-solver) to estimate the calibration information.

Now I have already obtained pair-wise matched feature points but I find that the algorithm in bundle adjustment algorithm (Ceres-solver) also need initial camera intrinsic and extrinsic matrix and 3d point coordinates as input. However, I do not have this information and I do not know how to generate an initial guess, either.

What should I do to generate the initial camera intrinsic and extrinsic matrix and 3d point coordinates?

Thanks very much!

1

1 Answers

2
votes

Initial parameters are important to help the algorithm in converging to right local minima, and therefore to obtain a good reconstruction. You have different options to find the intrinsics of your camera(s):

  • If you know the camera brand(s) used for taking the pictures you could try to find those intrinsics in a database. Important parameters for you are the CCD width and the focal length (mm). Try this one.
  • Check EXIF tags of your images. You can use tools like jhead or exiftool for that purpose.

You basically need the focal length in pixels and the lens distortion coefficients. To calculate the focal length in pixels you can use the next equation:

focal_pixels = res_x * (focal_mm / ccd_width_mm)

If in any case you can't find intrinsics parameters for your camera(s) you can use the following approximation as initial guess:

focal_pixels = 1.2 * res_x

Don't set the parameters as fixed, so focal length and distortion parameters will be optimized in the bundle adjustment step.

On the other hand, extrinsic parameters are the values of the R|T (roto-translation matrix) of every camera, calculated/optimized in the reconstruction and bundle adjustment step. Since scale is unknown in SfM scenarios, the first reconstructed pair of cameras (the ones with higher score in the cross-matching step) are generated from points projected on a random depth value (Z towards scene). You don't need any initial value for extrinsics or 3D point coordinates.