• Stars
    star
    136
  • Rank 267,670 (Top 6 %)
  • Language
    C++
  • License
    Other
  • Created over 10 years ago
  • Updated over 2 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A C++ implementation of a nonlinear 3D IMU fusion algorithm

Attitude Estimator

Author: Philipp Allgeuer

Version: 1.2.1

Date: 18/03/2022

General Overview

Attitude Estimator is a generic platform-independent C++ library that implements an IMU sensor fusion algorithm. Up to 3-axis gyroscope, accelerometer and magnetometer data can be processed into a full 3D quaternion orientation estimate, with the use of a nonlinear Passive Complementary Filter. The library is targeted at robotic applications, but is by no means limited to this. Features of the estimator include gyro bias estimation, transient quick learning, multiple estimation algorithms, tuneable estimator parameters, and near-global stability backed by theoretical analysis.

Great emphasis has been placed on having a very efficient, yet totally numerically and algorithmically robust implementation of the filter. The code size has also been kept to a minimum, and has been extremely well-commented. The programmatic interface has also been made as easy as possible. Please refer to the extensive documentation of the library for more information on its capabilities and usage caveats.

Attitude Estimator was developed as part of the NimbRo-OP project at the University of Bonn.

The library has been unofficially ported to Go, thanks to knei-knurow, and is available here.

Feature List

  • Small and highly efficient performance-oriented cross-platform C++ library
  • Implements fusion of IMU sensor data (3-axis gyroscope, 3-axis accelerometer, 3-axis magnetometer), forming a reliable 3D attitude (orientation) estimate in the form of a quaternion
  • Able to dynamically deal with missing or non-present sensor data, even if there is theoretically no longer enough information to reconstruct a full 3D attitude
  • Gyro bias estimation, tuneable algorithm parameters, interface to provide state/system priors if desired
  • Multiple fallback estimation algorithms to choose from, including the ZYX yaw method, fused yaw method, and absolute fused yaw method
  • Transient quick learning phase for fast initial settling of the attitude estimate
  • Guaranteed numerical and algorithmic stability, with much effort having gone into ensuring the complete robustness of the implementation
  • Independent code with no external dependencies other than certain maths functions of the C++ Standard Library
  • Documented using the Doxygen documentation generation tool, including a code sample and a discussion of all usage caveats
  • Extremely well-commented library source code detailing and discussing the implementation details
  • Tried and tested by the author in simulation and on various robotic platforms

Installation

This library is implemented as a collection of platform-independent C++ source files. To get started just clone the attitude_estimator repository.

There are three ways of using the library:

  1. Directly include the source files in your project, and build them with the rest of your project.

  2. Build a static library (e.g. *.a or *.lib) of the source code and link your project to it.

  3. Build a dynamic library (e.g. *.so or *.dll) of the source code and link your project to it.

Due to the small and efficient nature of the library, one of the first two options is recommended. Very minimal benefit is expected from building a dynamic library.

Note that as at release v1.2.1, the required (non-test) source files are simply attitude_estimator.h and attitude_estimator.cpp.

A sample makefile for building the static and dynamic libraries using gcc is included in the release. The makefile also demonstrates how the test_attitude_estimator unit test can be built. As mentioned in the makefile however, the Attitude Estimator could equivalently be built using any other compiler, such as for example MSVC.

Dependencies

The library does not require C++11, and has no external dependencies other than the C++ Standard Library, of which only cmath is required. More precisely, the only standard library functions that are required are abs, sqrt, asin and atan2.

Documentation

Doxygen Documentation

The first place to look for help and guidance when trying to use the Attitude Estimator is the Doxygen documentation. It can be generated by running a shell script in doc/generate_doc.sh. The generated documentation can then be found in:

doc/Attitude Estimator.html

Or equivalently:

doc/out/html/index.html

The Doxygen documentation provides a complete explanation of the entire library, including all caveats and details, and includes a code sample to make the task of integrating the library into user code as simple as possible. Complete documentation of all functions, classes and namespaces of the library is also included. As such, the Doxygen documentation is intended to be the primary help resource when working with the library.

Source Code

If anything is not adequately explained in the Doxygen documentation, or more details as to the inner workings of the library are required, the next place to look would be in the library source code. The code is extremely well-commented and should thus be fairly self-explanatory. A good starting point is attitude_estimator.h.

Where To Get More Help?

If neither the Doxygen documentation nor a look into the source code can resolve your issues for whatever reason, you can open a GitHub issue.

Bugs and Improvements

I welcome all feedback, suggestions and bug reports (by opening a GitHub issue). If you improve or fix anything about the library then I encourage you to let me know so that the library can be improved for everyone!

More Repositories

1

rviz_cinematographer

Easy to use tools to create and edit trajectories for the rviz camera.
C++
224
star
2

nimbro_network

ROS network stack: Topic/service transport over unreliable network connections
C++
137
star
3

TopiCo

Time-optimal Trajectory Generation and Control
C++
124
star
4

easy_pbr

Lightweight Physically-Based Renderer designed for ease of use and fast prototyping
C++
104
star
5

lidar_mars_registration

C++
96
star
6

opt_control

Time-optimal Trajectory Generation and Control
95
star
7

mrs_laser_map

Local Multiresolution Grids for Efficient 3D Laser Mapping and Localization
C++
79
star
8

stillleben

Physics-based Scene Synthesis for Deep Learning
C++
61
star
9

humanoid_op_ros

ROS-based software framework for the igus Humanoid Open Platform.
C++
55
star
10

lattice_net

Fast Point Cloud Segmentation Using Permutohedral Lattices
Cuda
47
star
11

pointcloud_evaluation_tool

C++
44
star
12

DirectionalTSDF

Directional TSDF for improved reconstruction of surfaces with different orientation
C++
39
star
13

SmartEdgeSensor3DHumanPose

Real-Time Multi-View 3D Human Pose Estimation using Semantic Feedback to Smart Edge Sensors
C++
34
star
14

TemporalBallDetection

Official implementation of the paper: Utilizing Temporal Information in Deep Convolutional Network for Efficient Soccer Ball Detection and Tracking
Python
34
star
15

rot_conv_lib

Library for working with 3D rotations in C++
C++
25
star
16

vp-suite

A general framework for video prediction in PyTorch.
Python
23
star
17

neural_mvs

Official implementation for the publication "NeuralMVS: Bridging Multi-View Stereo and Novel View Synthesis"
Jupyter Notebook
22
star
18

catch_ros

ROS wrapper for the Catch unit test framework
C++
22
star
19

primitive_fitter

Automatic Optimal Capsule and Box collision primitives generator and inertia approximator given a URDF or XACRO file
C++
21
star
20

ExtrCamCalib_PersonKeypoints

Marker-free Extrinsic Camera Calibration using Person Keypoint Detections
Python
19
star
21

OCVP-object-centric-video-prediction

Official implementation of: "Object-Centric Video Prediction via Decoupling of Object Dynamics and Interactions" by Villar-Corrales et al. ICIP 2023
Python
14
star
22

Local_Freq_Transformer_Net

Jupyter Notebook
14
star
23

MotionSegmentation

Jupyter Notebook
13
star
24

synpick

SynPick dataset generator
C++
12
star
25

object_detection_in_laser_range_data

ROS packages to detect objects in sparse laser range data
C++
12
star
26

matlab_octave_rotations_lib

Library for working with 3D rotations in Matlab/Octave
MATLAB
11
star
27

temporal_latticenet

This repository provides the official implementation for the publication "Abstract Flow for Temporal Semantic Segmentation on the Permutohedral Lattice"
Python
11
star
28

state_controller_library

A C++ framework that implements generalised finite state machines
C++
10
star
29

shape_registration

Library for Shape Registration suited for Transfer of Grasping Skills
C++
10
star
30

FreqNet

Jupyter Notebook
9
star
31

HumanoidRobotPoseEstimation

Python
9
star
32

MSPred

Official implementation of "Video Prediction at Multiple Spatio-Temporal Scales with Hierarchical Recurrent Networks." by Villar-Corrales et al.
Python
7
star
33

LocDepVideoPrediction

Location Dependency in Video Prediction
Jupyter Notebook
5
star
34

pose_graph_prediction

Python
5
star
35

sl-scenes

An easy-to-use extension framework for stillleben that generates realistic and visually diverse indoor scenes with physically interacting objects
Python
4
star
36

Intention-Aware-Video-Prediction

Python
4
star
37

vector_compression

Utilities for 3D and 4D (unit) vector compression
C++
4
star
38

keypoint_gait_generator

Matlab implementation of the Keypoint Gait Generator
MATLAB
3
star
39

Pred_Semantic

Semantic Prediction: Which One Should Come First, Recognition or Prediction?
Python
3
star
40

abstract_vin

Python
3
star
41

SmartEdgeSensor3DScenePerception

3D Semantic Scene Perception using Distributed Smart Edge Sensors
C++
3
star
42

behaviour_control_framework

A C++ framework that uses inhibition trees for behaviour control
C++
3
star
43

MeshHashingDTSDF

Implementation of our paper "Directional TSDF: Modeling Surface Orientation for Coherent Meshes"
Cuda
2
star
44

multi_hypothesis_tracking

ROS package providing generic libraries for Multi Hypothesis Tracking.
C++
2
star
45

JetsonTRTPerception

C++
2
star
46

multi_hypothesis_tracking_msgs

CMake
2
star
47

Roughness_Sensing

Audio-based Roughness Sensing and Tactile Feedback for Haptic Perception in Telepresence
Jupyter Notebook
1
star
48

hands-free_locomotion_controller

1
star
49

planning_abstraction_net

C++
1
star
50

ros_openni2_multicam

Custom OpenNI2 driver designed especially for multicamera setups
C++
1
star
51

vismotcoord

Focused Online Visual-Motor coordination for Baxter robot
C++
1
star
52

nimbro_fsm2

C++17 Finite State Machine Framework
C++
1
star