Skip to content

Repository files navigation

Initialization-Free Bundle Adjustment Revisited: A Controlled Experimental Study

Welcome to the official page of the paper Initialization-Free Bundle Adjustment Revisited: A Controlled Experimental Study.

This repository contains the code used for our experiments on initialization-free bundle adjustment with Object-Space Error (OSE) formulations with the Variable Projection (VarPro) algorithm, followed by projective refinement and metric upgrade.

The implementation builds on RootBA and the PoVar solver introduced in:

@inproceedings{weber2024power,
  title={Power variable projection for initialization-free large-scale bundle adjustment},
  author={Weber, Simon and Hong, Je Hyeong and Cremers, Daniel},
  booktitle={European conference on computer vision},
  pages={111--126},
  year={2024},
  organization={Springer}
}

Build

Install the RootBA dependencies, then build the external libraries and the main project:

./scripts/build-external.sh
./scripts/build-rootba-povar.sh Release

The resulting binaries are written to ./bin/.

Supported Paper Configurations

The paper experiments use the following OSE formulations:

Problem type Formulation
METRIC_UPGRADE pOSE
METRIC_UPGRADE_ROSE rOSE
METRIC_UPGRADE_RPOSE RpOSE
METRIC_UPGRADE_EXPOSE expOSE
METRIC_UPGRADE_POSE_ROT pOSE+rot

introduced in the following papers, respectively:

@inproceedings{zach2018pose,
  title={pOSE: Pseudo object space error for initialization-free bundle adjustment},
  author={Zach, Christopher and Hong, Je Hyeong},
  booktitle={2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  pages={1876--1885},
  year={2018},
  organization={IEEE}
}
@inproceedings{iglesias2021radial,
  title={Radial distortion invariant factorization for structure from motion},
  author={Iglesias, Jos{\'e} Pedro and Olsson, Carl},
  booktitle={2021 IEEE/CVF International Conference on Computer Vision (ICCV)},
  pages={5886--5895},
  year={2021},
  organization={IEEE}
}
@inproceedings{iglesias2023expose,
  title={expose: Accurate initialization-free projective factorization using exponential regularization},
  author={Iglesias, Jos{\'e} Pedro and Nilsson, Amanda and Olsson, Carl},
  booktitle={2023 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR)},
  pages={8959--8968},
  year={2023},
  organization={IEEE}
}
@article{olsson2025towards,
  title={Towards initialization-free calibrated bundle adjustment},
  author={Olsson, Carl and Nilsson, Amanda},
  journal={arXiv preprint arXiv:2506.23808},
  year={2025}
}

For pOSE+rot, the relative rotations can be chosen with:

Option Meaning
--pose-rot-relative-rotation-source GROUNDTRUTH Use relative rotations induced by the loaded reference poses.
--pose-rot-relative-rotation-source ESTIMATED Estimate pairwise relative rotations from shared calibrated observations; degenerate pairs fall back to the reference pose.

The main solvers kept for the paper are:

Option Meaning
--solver-type-step-1 POWER_VARPROJ Power-series VarPro solver for the OSE stage.
--solver-type-step-1 CHOLESKY Direct Cholesky solve for the reduced camera system.
--solver-type-step-2 RIPOBA Projective/homogeneous refinement stage.

Main Options

Typical experiments vary only the following options:

Option Values used in the paper
--problem-type One of the supported formulations above.
--pose-randomization NORMAL, UNIFORM, or UNIT_CIRCLE.
--minimal-obs Minimum landmark visibility threshold, e.g. 3, 6, or 10.
--varpro_residual-robust-norm NONE or CAUCHY for the Stage 1 OSE/VarPro residuals.
--varpro_residual-cauchy-parameter Cauchy scale; the paper defaults to 1.0.
--max-num-iterations-step-1 Number of OSE optimization iterations.
--max-num-iterations-step-2 Number of refinement iterations.
--power-sc-iterations Power-series order used by PoVar.
--alpha Weight of the formulation-specific regularization terms.
--colmap-normalize-observations Normalize COLMAP observations before Stage 1.
--denormalize-stage-2 Convert observations back before projective refinement.

For the controlled COLMAP-style datasets, the common command shape is:

./bin/bal \
  --power-sc-iterations 20 \
  --num-threads 8 \
  --input /path/to/data/sets/set1 \
  --solver-type-step-1 POWER_VARPROJ \
  --solver-type-step-2 RIPOBA \
  --max-num-iterations-step-1 50 \
  --max-num-iterations-step-2 50 \
  --alpha 0.05 \
  --problem-type METRIC_UPGRADE_EXPOSE \
  --minimal-obs 3 \
  --pose-randomization UNIT_CIRCLE \
  --varpro_residual-robust-norm CAUCHY \
  --colmap-normalize-observations \
  --denormalize-stage-2

GUI

bal_gui is a visualization and debugging tool for the same paper pipeline:

./bin/bal_gui \
  --power-sc-iterations 20 \
  --num-threads 8 \
  --input /path/to/data/sets/set1 \
  --solver-type-step-1 POWER_VARPROJ \
  --solver-type-step-2 RIPOBA \
  --max-num-iterations-step-1 50 \
  --max-num-iterations-step-2 50 \
  --alpha 0.05 \
  --problem-type METRIC_UPGRADE \
  --minimal-obs 3 \
  --colmap-normalize-observations \
  --denormalize-stage-2

The GUI is meant to reproduce one batch configuration interactively. The important point is that the command-line options set the same defaults as bal, while the buttons execute the pipeline one step at a time.

To reproduce a batch result in the GUI:

  1. Launch bal_gui with the same options used in the batch run: --problem-type, --minimal-obs, --pose-randomization, --varpro_residual-robust-norm, --alpha, --colmap-normalize-observations, and --denormalize-stage-2.
  2. In Model Selection, check the formulation to test: pOSE, rOSE, RpOSE, expOSE, or pOSE+rot.
  3. In Initialization, check the same initialization used in the batch: Normal, Uniform, or Unit circle.
  4. In Parameters for OSE, check the Stage 1 robust loss: Stage1 Robust None for the non-robust runs, or Stage1 Robust Cauchy for the Cauchy runs.
  5. For pOSE+rot, select the relative-rotation source: Ground truth for the main pOSE+rot configuration, or Estimated for the estimated-relative-rotation variant. Changing this reloads the dataset, so do it before solving.
  6. Press Randomization. This applies the same randomization passes used by the batch executable.
  7. Press Solve Stage 1. This runs the selected OSE/VarPro formulation.
  8. Press Solve Stage 2. This creates the homogeneous landmarks when needed and runs the projective reprojection refinement.
  9. Choose the metric-upgrade mode in Parameters for metric upgrade, then press Metric Upgrade.
  10. Use save_bal to export the reconstruction currently displayed in the GUI.

The metric-upgrade selector exposes the two paper paths:

GUI mode Meaning
Linear Linear metric upgrade.
Second-order Nonlinear refinement initialized from the linear upgrade.

Our implementation of the metric upgrade stage is based on the following paper, whose official implementation is not public:

@article{pollefeys1999self,
title={Self-calibration and metric reconstruction inspite of varying and unknown intrinsic camera parameters},
author={Pollefeys, Marc and Koch, Reinhard and Gool, Luc Van},
journal={International journal of computer vision},
volume={32},
number={1},
pages={7--25},
year={1999},
publisher={Springer}
}

For pOSE+rot, the GUI exposes both ground-truth and estimated relative rotations. Changing this source reloads the dataset before preparing the pOSE+rot camera pairs, matching the command-line executable.

Batch Experiments

The main paper sweep is configured from:

cp examples/batch/rootba_batch_config.toml ../rootba_experiments/
./scripts/generate-batch-configs.py ../rootba_experiments/
./scripts/run-all-in.sh ../rootba_experiments/01_tutorial/

The default batch configuration includes the five supported formulations, the three initialization distributions, non-robust and Cauchy Stage 1 losses, and both pOSE+rot relative-rotation sources.

After the runs finish, generate the tables with:

cp examples/batch/experiments-tutorial.toml ../rootba_experiments/
./scripts/generate-tables.py --config ../rootba_experiments/experiments-tutorial.toml --open
python ./python/rootba/tex_to_pandas.py \
  ../rootba_experiments/tables/experiments-tutorial-export/pose_auc_rot_{5,10,20}deg.tex

The exported metrics include rotation AUC, translation-direction AUC, landmark metrics, and values before metric upgrade, after linear metric upgrade, and after the selected linear/refined metric upgrade when available.

Datasets

The controlled datasets can be prepared with:

./data/get_colder_examples.sh
mkdir -p ../rootba_data/colder
cp -r data/sets/* ../rootba_data/colder

BAL datasets can also be used as input. For BAL visualizations, use an appropriate visibility threshold such as --minimal-obs 10 when the problem is large or very sparse.

Release Notes

This codebase is intended to support the paper experiments. Historical experimental variants may still exist in the repository history, but the public surface documented here is restricted to the formulations and options above.

Before publishing a release, avoid committing local generated artifacts such as generated_figures/, generated_tables/, debug_runs/, build directories, temporary BAL exports, and Python __pycache__/ files.

License

The code inherited from RootBA is licensed under the BSD 3-Clause License. Parts of the code are derived from Ceres Solver. See ACKNOWLEDGEMENTS for third-party acknowledgements.

Citation

If you find our work useful in your research, please consider citing:

@article{weber2026initialization,
  title={Initialization-Free Bundle Adjustment Revisited: A Controlled Experimental Study},
  author={Weber, Simon and de Mayo, Mateo and Hong, Je Hyeong and Olsson, Carl and Cremers, Daniel and Clark, Ronald},
  journal={arXiv preprint arXiv:2608.18028},
  year={2026}
}

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages