Skip to content

Commit

Permalink
Merge branch 'master' into fix/export_poses
Browse files Browse the repository at this point in the history
  • Loading branch information
goldbattle committed Nov 24, 2022
2 parents a3576dd + ae12925 commit 55539b3
Show file tree
Hide file tree
Showing 171 changed files with 2,702 additions and 1,645 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/docker_1604_build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "ROS1 Ubuntu 16.04"

on:
push:
branches: [ master, dockerfile ]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Code Checkout
uses: actions/checkout@v2
- name: Create Workspace
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
cd $GITHUB_WORKSPACE/.. && mkdir src/ &&
mv $REPO/ src/ && mkdir $REPO/ && mv src/ $REPO/ && cd $REPO/
- name: Build Docker
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
docker build -t kalibr -f $GITHUB_WORKSPACE/src/$REPO/Dockerfile_ros1_16_04 .
23 changes: 23 additions & 0 deletions .github/workflows/docker_1804_build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "ROS1 Ubuntu 18.04"

on:
push:
branches: [ master, dockerfile ]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Code Checkout
uses: actions/checkout@v2
- name: Create Workspace
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
cd $GITHUB_WORKSPACE/.. && mkdir src/ &&
mv $REPO/ src/ && mkdir $REPO/ && mv src/ $REPO/ && cd $REPO/
- name: Build Docker
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
docker build -t kalibr -f $GITHUB_WORKSPACE/src/$REPO/Dockerfile_ros1_18_04 .
23 changes: 23 additions & 0 deletions .github/workflows/docker_2004_build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "ROS1 Ubuntu 20.04"

on:
push:
branches: [ master, dockerfile ]
pull_request:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Code Checkout
uses: actions/checkout@v2
- name: Create Workspace
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
cd $GITHUB_WORKSPACE/.. && mkdir src/ &&
mv $REPO/ src/ && mkdir $REPO/ && mv src/ $REPO/ && cd $REPO/
- name: Build Docker
run: |
export REPO=$(basename $GITHUB_REPOSITORY) &&
docker build -t kalibr -f $GITHUB_WORKSPACE/src/$REPO/Dockerfile_ros1_20_04 .
26 changes: 26 additions & 0 deletions .github/workflows/industrial_ci_action.yml.disable
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: CI

# This determines when this workflow is run
on: [push, pull_request] # on all pushes and PRs

jobs:
CI:
strategy:
matrix:
env:
- {ROS_DISTRO: melodic}
- {ROS_DISTRO: noetic}
env:
CCACHE_DIR: /github/home/.ccache # Enable ccache
NOT_TEST_BUILD: true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
# This step will fetch/store the directory used by ccache before/after the ci run
- uses: actions/cache@v2
with:
path: ${{ env.CCACHE_DIR }}
key: ccache-${{ matrix.env.ROS_DISTRO }}-${{ matrix.env.ROS_REPO }}
# Run industrial_ci
- uses: 'ros-industrial/industrial_ci@master'
env: ${{ matrix.env }}
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,9 @@ CMakeLists.txt.user

# MacOS Desktop Services Store
.DS_Store

# Jetbrains Clion
cmake-build-*
.idea
build
Build
56 changes: 56 additions & 0 deletions Dockerfile_ros1_16_04
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
FROM osrf/ros:kinetic-desktop-full


# Dependencies we use, catkin tools is very good build system
# https://github.com/ethz-asl/kalibr/wiki/installation
RUN apt-get update && DEBIAN_FRONTEND=noninteractive \
apt-get install -y \
git wget autoconf automake \
python2.7-dev python-pip python-scipy python-matplotlib \
ipython python-wxgtk3.0 python-tk python-igraph \
libeigen3-dev libboost-all-dev libsuitesparse-dev \
doxygen \
libopencv-dev \
libpoco-dev libtbb-dev libblas-dev liblapack-dev libv4l-dev \
python-catkin-tools


# Create the workspace and build kalibr in it
ENV WORKSPACE /catkin_ws

RUN mkdir -p $WORKSPACE/src && \
cd $WORKSPACE && \
catkin init && \
catkin config --extend /opt/ros/kinetic && \
catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release

ADD . $WORKSPACE/src/kalibr
# RUN cd $WORKSPACE/src &&\
# git clone https://github.com/ori-drs/kalibr.git

RUN cd $WORKSPACE &&\
catkin build -j$(nproc)


# When a user runs a command we will run this code before theirs
# This will allow for using the manual focal length if it fails to init
# https://github.com/ethz-asl/kalibr/pull/346
ENTRYPOINT export KALIBR_MANUAL_FOCAL_LENGTH_INIT=1 && \
# /bin/bash -c "source \"$WORKSPACE/devel/setup.bash\"" && \
cd $WORKSPACE && \
/bin/bash















50 changes: 50 additions & 0 deletions Dockerfile_ros1_18_04
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
FROM osrf/ros:melodic-desktop-full


# Dependencies we use, catkin tools is very good build system
# https://github.com/ethz-asl/kalibr/wiki/installation
RUN apt-get update && DEBIAN_FRONTEND=noninteractive \
apt-get install -y \
git wget autoconf automake nano \
python3-dev python-pip python-scipy python-matplotlib \
ipython python-wxgtk4.0 python-tk python-igraph \
libeigen3-dev libboost-all-dev libsuitesparse-dev \
doxygen \
libopencv-dev \
libpoco-dev libtbb-dev libblas-dev liblapack-dev libv4l-dev \
python-catkin-tools


# Create the workspace and build kalibr in it
ENV WORKSPACE /catkin_ws

RUN mkdir -p $WORKSPACE/src && \
cd $WORKSPACE && \
catkin init && \
catkin config --extend /opt/ros/melodic && \
catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release

ADD . $WORKSPACE/src/kalibr
# RUN cd $WORKSPACE/src &&\
# git clone https://github.com/ori-drs/kalibr.git

RUN cd $WORKSPACE &&\
catkin build -j$(nproc)


# When a user runs a command we will run this code before theirs
# This will allow for using the manual focal length if it fails to init
# https://github.com/ethz-asl/kalibr/pull/346
ENTRYPOINT export KALIBR_MANUAL_FOCAL_LENGTH_INIT=1 && \
# /bin/bash -c "source \"$WORKSPACE/devel/setup.bash\"" && \
cd $WORKSPACE && \
/bin/bash









46 changes: 46 additions & 0 deletions Dockerfile_ros1_20_04
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
FROM osrf/ros:noetic-desktop-full


# Dependencies we use, catkin tools is very good build system
# https://github.com/ethz-asl/kalibr/wiki/installation
RUN apt-get update && DEBIAN_FRONTEND=noninteractive \
apt-get install -y \
git wget autoconf automake nano \
python3-dev python3-pip python3-scipy python3-matplotlib \
ipython3 python3-wxgtk4.0 python3-tk python3-igraph \
libeigen3-dev libboost-all-dev libsuitesparse-dev \
doxygen \
libopencv-dev \
libpoco-dev libtbb-dev libblas-dev liblapack-dev libv4l-dev \
python3-catkin-tools python3-osrf-pycommon


# Create the workspace and build kalibr in it
ENV WORKSPACE /catkin_ws

RUN mkdir -p $WORKSPACE/src && \
cd $WORKSPACE && \
catkin init && \
catkin config --extend /opt/ros/noetic && \
catkin config --cmake-args -DCMAKE_BUILD_TYPE=Release

ADD . $WORKSPACE/src/kalibr
# RUN cd $WORKSPACE/src &&\
# git clone https://github.com/ori-drs/kalibr.git

RUN cd $WORKSPACE &&\
catkin build -j$(nproc)


# When a user runs a command we will run this code before theirs
# This will allow for using the manual focal length if it fails to init
# https://github.com/ethz-asl/kalibr/pull/346
ENTRYPOINT export KALIBR_MANUAL_FOCAL_LENGTH_INIT=1 && \
# /bin/bash -c "source \"$WORKSPACE/devel/setup.bash\"" && \
cd $WORKSPACE && \
/bin/bash





32 changes: 18 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,31 @@
![Kalibr](https://raw.githubusercontent.com/wiki/ethz-asl/kalibr/images/kalibr_small.png)

*Ubuntu 14.04+ROS indigo*: [![Build Status](https://jenkins.asl.ethz.ch/buildStatus/icon?job=kalibr_weekly/label=ubuntu-trusty)](https://jenkins.asl.ethz.ch/job/kalibr_weekly/label=ubuntu-trusty/) *Ubuntu 16.04+ROS kinetic*: [![Build Status](https://jenkins.asl.ethz.ch/buildStatus/icon?job=kalibr_weekly/label=ubuntu-trusty)](https://jenkins.asl.ethz.ch/job/kalibr_weekly/label=ubuntu-xenial/)
[![ROS1 Ubuntu 20.04](https://github.com/ethz-asl/kalibr/actions/workflows/docker_2004_build.yaml/badge.svg)](https://github.com/ethz-asl/kalibr/actions/workflows/docker_2004_build.yaml)
[![ROS1 Ubuntu 18.04](https://github.com/ethz-asl/kalibr/actions/workflows/docker_1804_build.yaml/badge.svg)](https://github.com/ethz-asl/kalibr/actions/workflows/docker_1804_build.yaml)
[![ROS1 Ubuntu 16.04](https://github.com/ethz-asl/kalibr/actions/workflows/docker_1604_build.yaml/badge.svg)](https://github.com/ethz-asl/kalibr/actions/workflows/docker_1604_build.yaml)

## Introduction
Kalibr is a toolbox that solves the following calibration problems:

1. **Multiple camera calibration**:
intrinsic and extrinsic calibration of a camera-systems with non-globally shared overlapping fields of view
1. **Visual-inertial calibration calibration (camera-IMU)**:
spatial and temporal calibration of an IMU w.r.t a camera-system
1. **Rolling Shutter Camera calibration**:
full intrinsic calibration (projection, distortion and shutter parameters) of rolling shutter cameras
1. **Multi-Camera Calibration**: Intrinsic and extrinsic calibration of a camera-systems with non-globally shared overlapping fields of view with support for a wide range of [camera models](https://github.com/ethz-asl/kalibr/wiki/supported-models).
1. **Visual-Inertial Calibration (CAM-IMU)**: Spatial and temporal calibration of an IMU w.r.t a camera-system along with IMU intrinsic parameters
1. **Multi-Inertial Calibration (IMU-IMU)**: Spatial and temporal calibration of an IMU w.r.t a base inertial sensor along with IMU intrinsic parameters (requires 1-aiding camera sensor).
1. **Rolling Shutter Camera Calibration**: Full intrinsic calibration (projection, distortion and shutter parameters) of rolling shutter cameras.

To install follow the [install wiki page](https://github.com/ethz-asl/kalibr/wiki/installation) instructions for which you can either use Docker or install from source in a ROS workspace.
Please find more information on the [wiki pages](https://github.com/ethz-asl/kalibr/wiki) of this repository.
For questions or comments, please open an issue on Github.

**Please find more information on the [wiki pages](https://github.com/ethz-asl/kalibr/wiki) of this repository.**

**For questions or comments, please open an issue on Github.**
## News / Events

## Tutorial: IMU-camera calibration
A video tutorial for the IMU-camera calibration can be found here:
* **May 3, 2022** - Support for Ubuntu 20.04 along with Docker scripts have been merged into master via PR [#515](https://github.com/ethz-asl/kalibr/pull/515). A large portion was upgrading to Python 3. A special thanks to all the contributors that made this possible. Additionally, contributed fixes for the different validation and visualization scripts have been merged.
* **Febuary 3, 2020** - Initial Ubuntu 18.04 support has been merged via PR [#241](https://github.com/ethz-asl/kalibr/pull/241). Additionally, support for inputting an initial guess for focal length can be provided from the cmd-line on failure to initialize them.
* **August 15, 2018** - Double sphere camera models have been contributed to the repository via PR [#210](https://github.com/ethz-asl/kalibr/pull/210). If you are interested you can refer to the [paper](https://arxiv.org/abs/1807.08957) for a nice overview of the models in the repository.
* **August 25, 2016** - Rolling shutter camera calibration support was added as a feature via PR [#65](https://github.com/ethz-asl/kalibr/pull/65). The [paper](https://www.cv-foundation.org/openaccess/content_cvpr_2013/papers/Oth_Rolling_Shutter_Camera_2013_CVPR_paper.pdf) provides details for those interested.
* **May 18, 2016** - Support for multiple IMU-to-IMU spacial and IMU intrinsic calibration was released.
* **June 18, 2014** - Initial public release of the repository.

[![alt text](https://user-images.githubusercontent.com/5337083/44033014-50208b8a-9f09-11e8-8e9a-d7d6d3c69d97.png)](https://m.youtube.com/watch?v=puNXsnrYWTY "imu cam calib")

(Credits: @indigomega)

## Authors
* Paul Furgale
Expand All @@ -32,6 +35,7 @@ A video tutorial for the IMU-camera calibration can be found here:
* Thomas Schneider ([email]([email protected]))
* Luc Oth


## References
The calibration approaches used in Kalibr are based on the following papers. Please cite the appropriate papers when using this toolbox or parts of it in an academic publication.

Expand Down
44 changes: 34 additions & 10 deletions Schweizer-Messer/numpy_eigen/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,23 +1,28 @@
cmake_minimum_required(VERSION 2.8.3)
cmake_minimum_required(VERSION 3.0.2)
project(numpy_eigen)

find_package(catkin REQUIRED COMPONENTS cmake_modules python_module)
include_directories(${catkin_INCLUDE_DIRS})
set(CMAKE_CXX_STANDARD 14)

find_package(catkin REQUIRED COMPONENTS python_module)
find_package(Boost REQUIRED COMPONENTS system)
find_package(Eigen REQUIRED)
find_package(Eigen3 REQUIRED)

catkin_python_setup()

add_definitions(${EIGEN_DEFINITIONS})
include_directories(include ${Eigen_INCLUDE_DIRS} ${catkin_INCLUDE_DIRS})
include_directories(include ${EIGEN3_INCLUDE_DIRS} ${catkin_INCLUDE_DIRS})
include_directories("${PROJECT_SOURCE_DIR}/include/numpy_eigen")

catkin_package(
INCLUDE_DIRS include ${catkin_INCLUDE_DIRS}
INCLUDE_DIRS include ${catkin_INCLUDE_DIRS}
LIBRARIES ${PROJECT_NAME}
DEPENDS
DEPENDS Boost
CFG_EXTRAS numpy_eigen-extras.cmake
)
add_definitions(-std=c++0x -D__STRICT_ANSI__)
add_definitions(-D__STRICT_ANSI__)

# ignore "error: return-statement with a value, in function returning ‘void’" in "__multiarray_api.h"
add_compile_options(-fpermissive)

include_directories(include ${Boost_INCLUDE_DIRS})

Expand Down Expand Up @@ -46,8 +51,27 @@ add_python_export_library(${PROJECT_NAME}_test
## Testing ##
#############
if(CATKIN_ENABLE_TESTING)

## Add nosetest based cpp test target.
catkin_add_nosetests(test/numpy_eigen_tests.py)

endif()

install(TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

##################
## Installation ##
##################

install(TARGETS ${PROJECT_NAME}
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION}
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION}
)

## Mark cpp header files for installation
install(DIRECTORY include/${PROJECT_NAME}/
DESTINATION ${CATKIN_PACKAGE_INCLUDE_DESTINATION}
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
find_package(Eigen3 REQUIRED)
include_directories(${EIGEN3_INCLUDE_DIRS})
Loading

0 comments on commit 55539b3

Please sign in to comment.