Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

GTSAM: Georgia Tech Smoothing and Mapping Library

C++ API Docs

GTSAM manifold optimization workflow: build a factor graph, linearize and solve in tangent spaces, retract to manifolds, and iterate to convergence.

Important Note

The develop branch is officially in "Pre 4.3" mode. We envision several API-breaking changes as we switch to C++17 and away from boost.

In addition, features deprecated in 4.2 will be removed. Please use the stable 4.2 release if you need those features. However, most are easily converted and can be tracked down (in 4.2) by disabling the cmake flag GTSAM_ALLOW_DEPRECATED_SINCE_V42.

What is GTSAM?

GTSAM is a C++ library that implements smoothing and mapping (SAM) in robotics and vision, using Factor Graphs and Bayes Networks as the underlying computing paradigm rather than sparse matrices.

CI Status Platform Compiler
Python CI Ubuntu 22.04, MacOS 13-14, Windows gcc/clang,MSVC
vcpkg Latest Windows/Ubuntu/Mac -
Build Wheels for Develop See pypi files; no Windows -

On top of the C++ library, GTSAM includes wrappers for MATLAB & Python.

Documentation

Quickstart

In the root library folder execute:

#!bash
mkdir build
cd build
cmake ..
make check  # optional, runs all unit tests
make install

Prerequisites:

  • A modern compiler:
    • Mac: at least xcode-14.2
    • Linux: at least clang-11 or gcc-9
    • Windows: at least msvc-14.2
  • CMake >= 3.16
    • Ubuntu: sudo apt-get install cmake

Optional Boost prerequisite:

Boost is now optional. Two cmake flags govern its behavior:

  • GTSAM_USE_BOOST_FEATURES = ON|OFF: some of our timers and concept checking in the tests still depend on boost.
  • GTSAM_ENABLE_BOOST_SERIALIZATION = ON|OFF: serialization of factor graphs, factors, etc still is done using boost

If one or both of these flags are ON, you need to install Boost >= 1.70 - Mac: brew install boost - Ubuntu: sudo apt-get install libboost-all-dev - Windows: We highly recommend using the vcpkg package manager. For other installation methods or troubleshooting, please see the guidance in the cmake/HandleBoost.cmake script.

Optional prerequisites - used automatically if findable by CMake:

GTSAM 4 Compatibility

GTSAM 4 introduces several new features, most notably Expressions and a Python toolbox. It also introduces traits, a C++ technique that allows optimizing with non-GTSAM types. That opens the door to retiring geometric types such as Point2 and Point3 to pure Eigen types, which we also do. A significant change which will not trigger a compile error is that zero-initializing of Point2 and Point3 is deprecated, so please be aware that this might render functions using their default constructor incorrect.

There is a flag GTSAM_ALLOW_DEPRECATED_SINCE_V43 for newly deprecated methods since the 4.3 release, which is on by default, allowing anyone to just pull version 4.3 and compile.

Wrappers

We provide support for MATLAB and Python wrappers for GTSAM. Please refer to the linked documents for more details.

Citation

If you are using GTSAM for academic work, please use the following citation:

@software{gtsam,
  author       = {Frank Dellaert and GTSAM Contributors},
  title        = {borglab/gtsam},
  month        = May,
  year         = 2022,
  publisher    = {Georgia Tech Borg Lab},
  version      = {4.2a8},
  doi          = {10.5281/zenodo.5794541},
  url          = {https://github.com/borglab/gtsam)}}
}

To cite the Factor Graphs for Robot Perception book, please use:

@book{factor_graphs_for_robot_perception,
    author={Frank Dellaert and Michael Kaess},
    year={2017},
    title={Factor Graphs for Robot Perception},
    publisher={Foundations and Trends in Robotics, Vol. 6},
    url={http://www.cs.cmu.edu/~kaess/pub/Dellaert17fnt.pdf}
}

If you are using the IMU preintegration scheme, please cite:

@book{imu_preintegration,
    author={Christian Forster and Luca Carlone and Frank Dellaert and Davide Scaramuzza},
    title={IMU preintegration on Manifold for Efficient Visual-Inertial Maximum-a-Posteriori Estimation},
    year={2015}
}

The Preintegrated IMU Factor

GTSAM includes a state of the art IMU handling scheme based on

  • Todd Lupton and Salah Sukkarieh, "Visual-Inertial-Aided Navigation for High-Dynamic Motion in Built Environments Without Initial Conditions", TRO, 28(1):61-76, 2012. [link]

Our implementation improves on this using integration on the manifold, as detailed in

  • Luca Carlone, Zsolt Kira, Chris Beall, Vadim Indelman, and Frank Dellaert, "Eliminating conditionally independent sets in factor graphs: a unifying perspective based on smart factors", Int. Conf. on Robotics and Automation (ICRA), 2014. [link]
  • Christian Forster, Luca Carlone, Frank Dellaert, and Davide Scaramuzza, "IMU Preintegration on Manifold for Efficient Visual-Inertial Maximum-a-Posteriori Estimation", Robotics: Science and Systems (RSS), 2015. [link]

If you are using the factor in academic work, please cite the publications above.

In GTSAM 4 a new and more efficient implementation, based on integrating on the NavState tangent space and detailed in this document, is enabled by default. To switch to the RSS 2015 version, set the flag GTSAM_TANGENT_PREINTEGRATION to OFF.

Additional Information

There is a GTSAM users Google group for general discussion.

Read about important GTSAM-Concepts here. A primer on GTSAM Expressions, which support (superfast) automatic differentiation, can be found on the GTSAM wiki on BitBucket.

See the INSTALL file for more detailed installation instructions. Our CI/CD process is detailed in workflows.md.

GTSAM is open source under the BSD license, see the LICENSE and LICENSE.BSD files.

Please see the examples/ directory and the USAGE file for examples on how to use GTSAM.

GTSAM was developed in the lab of Frank Dellaert at the Georgia Institute of Technology, with the help of many contributors over the years, see THANKS.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

gtsam_develop-4.3a2.dev202608161900-cp312-cp312-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl (32.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.27+ ARM64manylinux: glibc 2.28+ ARM64

gtsam_develop-4.3a2.dev202608161900-cp312-cp312-macosx_10_15_universal2.whl (46.0 MB view details)

Uploaded CPython 3.12macOS 10.15+ universal2 (ARM64, x86-64)

gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (33.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl (32.0 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ ARM64

gtsam_develop-4.3a2.dev202608161900-cp311-cp311-macosx_10_15_universal2.whl (45.8 MB view details)

Uploaded CPython 3.11macOS 10.15+ universal2 (ARM64, x86-64)

File details

Details for the file gtsam_develop-4.3a2.dev202608161900-cp312-cp312-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for gtsam_develop-4.3a2.dev202608161900-cp312-cp312-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 9ad10893043b2556551c25b65cc7a5fd192554104e13ff206db202bcd78fb2d8
MD5 e96d696986eba39a3ce46ce21b43ee97
BLAKE2b-256 a49b77a55920eca0dcd0f0fd053ac0668be2a8dc19a3bd75a48c9437c1ad82c6

See more details on using hashes here.

Provenance

The following attestation bundles were made for gtsam_develop-4.3a2.dev202608161900-cp312-cp312-manylinux_2_27_aarch64.manylinux_2_28_aarch64.whl:

Publisher: build-cibw.yml on borglab/gtsam

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gtsam_develop-4.3a2.dev202608161900-cp312-cp312-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for gtsam_develop-4.3a2.dev202608161900-cp312-cp312-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 9b408aeb8c4fdd51f52af44b764e14b283413fc06a423656f45c2f9bbf77ff80
MD5 3abdd42c83b0c6a03dffee24bb1b796f
BLAKE2b-256 ceab1ac1c8a8608f8f39f8bc388bd369c33783bc46920ba314d313d90aac4926

See more details on using hashes here.

Provenance

The following attestation bundles were made for gtsam_develop-4.3a2.dev202608161900-cp312-cp312-macosx_10_15_universal2.whl:

Publisher: build-cibw.yml on borglab/gtsam

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 2bef3167b3f23283b52b84bbb4579b19678871ca4d3e62b56024f798ae42827b
MD5 0add9ceb7d9345ccf73bc891c7756faa
BLAKE2b-256 65fc07db264331c9e8cfd265ab68ef8f01be49dcd5f1c731feca2651755915ad

See more details on using hashes here.

Provenance

The following attestation bundles were made for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: build-cibw.yml on borglab/gtsam

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl.

File metadata

File hashes

Hashes for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl
Algorithm Hash digest
SHA256 86433cdd841854d38ad1d0e66e7462a8f430a9c7e0cafa1a59bfde8bfac2484a
MD5 5d8b0ab276677967ced50b94a305a06c
BLAKE2b-256 6b178ad1acd9da12af00566d01ae18687f653be3608f34566112ad7911c98e04

See more details on using hashes here.

Provenance

The following attestation bundles were made for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-manylinux2014_aarch64.manylinux_2_17_aarch64.whl:

Publisher: build-cibw.yml on borglab/gtsam

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gtsam_develop-4.3a2.dev202608161900-cp311-cp311-macosx_10_15_universal2.whl.

File metadata

File hashes

Hashes for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-macosx_10_15_universal2.whl
Algorithm Hash digest
SHA256 fd2f07512a5309998d6a04d4ada4a8764413fcf3d8fed588c49651e6de5d3285
MD5 5956953d3676fb803f205d3102adf092
BLAKE2b-256 9fe7b085817559911e13f615b600542620d14fc2fa5f99b5a54c63060025615d

See more details on using hashes here.

Provenance

The following attestation bundles were made for gtsam_develop-4.3a2.dev202608161900-cp311-cp311-macosx_10_15_universal2.whl:

Publisher: build-cibw.yml on borglab/gtsam

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page