10

If I have a known camera pose(Rotation + Position), and Intrinsics(distortion coefficients and camera matrix), and 2 cameras pointing at the same scene from slightly different angles.

Is there a way to use bundle adjustment to refine the camera pose? Preferably in some already existing API or function that doesent require too much mathematical knowledge to use.

Henrik Kjus Alstad
  • 674
  • 2
  • 9
  • 24

4 Answers4

6

You should use PBA (Multicore Bundle Adjustment) from Changchang Wu. It is really a nice library and it is written in C++. Furthermore, it features multi core computations and even GPU computation with a speedup of about 20 times.

It is clearly structured and easy to use.

So, instead of using SBA from Lourakis or using SSBA from Christopher Zach you should use PBA.

who9vy
  • 1,091
  • 9
  • 19
  • PBA is well-optimized and very fast, but supports less features that SSBA (fx/fy for instance). Which one to choose depends on the problem you're working on. – simon Jun 08 '15 at 18:52
3

You may want to check out SSBA at http://www.inf.ethz.ch/personal/chzach/opensource.html but it will still require some mathematical insight to be able to use it properly.

mgttlinger
  • 1,435
  • 2
  • 21
  • 35
dvhamme
  • 1,442
  • 9
  • 10
  • 1
    Indeed it has disappeared, you can still get the code for SSBA 3.0 from a subdir of this repo: https://github.com/royshil/SfM-Toy-Library/tree/master/3rdparty – dvhamme May 21 '14 at 13:12
3

You could try the implementation right inside OpenCV. It's in the contrib module. But I couldn't yet get it to work properly.. :/ article about it

Teris
  • 600
  • 1
  • 7
  • 24
  • 1
    It's limited to panoramic images only as of the time of this writing so if you do some translations for example the results are terrible. – rbaleksandar Jun 05 '14 at 15:11
  • 2
    I'd like to oppose the common conception of panoramic images being equal to assuming a rotational camera motion only. Just because the camera frames are projected onto a sphere does not mean they have to be captured this way. I think it's a flaw in the current OpenCV implementation that HomographyBasedEstimator and BundleAdjusterReproj as well as BundleAdjusterRay all assume a rotational motion model. I wish there were alternative methods solving the more generic problem when the motion model is affine. – Eduard Feicho Jul 23 '14 at 16:39
2

Try the Ceres solver. An example implementation is available here. Again, you will need an understanding of the mathematical principles of bundle adjustment. But that is unavoidable.

MM.
  • 4,224
  • 5
  • 37
  • 74