We utilize deep reinforcement learning to obtain favorable trajectories for visual-inertial system calibration.

Overview

Unified Data Collection for Visual-Inertial Calibration via Deep Reinforcement Learning

Update: The lastest code will be updated in this branch. Please switch to CORL2020 branch if you are looking for the Model-based Heuristic Deep RL approach.

Developed by Le Chen and Yunke Ao from Autonomous Systems Lab (ASL) at ETH Zurich.

1 Introduction

In this work we presents a novel formulation to learn a motion policy to be executed on a robot arm for automatic data collection for calibrating intrinsics and extrinsics jointly. Our approach models the calibration process compactly using model-free deep reinforcement learning to derive a policy that guides the motions of a robotic arm holding the sensor to efficiently collect measurements that can be used for both camera intrinsic calibration and camera-IMU extrinsic calibration. Given the current pose and collected measurements, the learned policy generates the subsequent transformation that optimizes sensor calibration accuracy. The evaluations in simulation and on a real robotic system show that our learned policy generates favorable motion trajectories and collects enough measurements efficiently that yield the desired intrinsics and extrinsics with short path lengths. In simulation we are able to perform calibrations $10\times$ faster than hand-crafted policies, which transfers to a real-world speed up of $3\times$ over a human expert.

2 Usage

Our code is tested on Ubuntu 18.04 LTS (Bionic Beaver) and ROS Melodic Morenia with GPU GTX 1660 Ti and CUDA 11.2.

2.1 Build Instructions

  • Install required dependencies:
sudo apt-get install build-essential software-properties-common
sudo apt-get install bc curl ca-certificates fakeroot gnupg2 libssl-dev lsb-release libelf-dev bison flex
sudo apt-get install ros-melodic-moveit, ros-melodic-moveit-visual-tools, ros-melodic-cmake-modules
sudo apt-get install ros-melodic-libfranka ros-melodic-franka-ros, ros-melodic-joint-trajectory-controller
sudo apt-get install ros-melodic-vision-opencv ros-melodic-image-transport-plugins
sudo apt-get install python-setuptools python-rosinstall ipython libeigen3-dev libboost-all-dev doxygen
sudo apt-get install libopencv-dev libgtk-3-dev python-catkin-tools
sudo apt-get install python-matplotlib python-scipy python-git python-pip ipython
sudo apt-get install libtbb-dev libblas-dev liblapack-dev libv4l-dev, libpoco-dev

pip install opencv-python
pip install opencv-contrib-python
pip install --upgrade tensorflow
pip install python-igraph --upgrade
pip install pyyaml
pip install rospkg
pip install matplotlib
pip install pandas
pip install pytorch
pip install wandb
pip install PyKDL
pip install gym
  • Clone the repository and catkin build:
cd ~/catkin_ws
git clone https://github.com/clthegoat/Learn-to-Calibrate.git
cd Learn-to-Calibrate
git checkout master
cd ../
mv Learn-to-Calibrate src
catkin build
source ~/catkin_ws/devel/setup.bash

2.2 Configuration

  • Please change the file saving directory in franka_cal_sim_single/config/config.yaml before training or testing!

2.3 Running the code

2.3.1 Training:

  • In terminal 1:
source ~/catkin_ws/devel/setup.bash
roslaunch franka_cal_sim_single cam_imu_ext_che.launch
  • In terminal 2:
source ~/catkin_ws/devel/setup.bash
cd src/franka_cal_sim/python/algorithms
python RL_algo_sac_int_ext.py

2.3.2 Testing:

  • In terminal 1:
source ~/catkin_ws/devel/setup.bash
roslaunch franka_cal_sim_single cam_imu_ext_che.launch
  • In terminal 2:
source ~/catkin_ws/devel/setup.bash
cd src/franka_cal_sim/python/test_policies/
python RL_algo_sac_ext_int_test.py

3 Citing

Please cite the following paper when using our code for your research:

@article{chen2020learning,
  title={Learning Trajectories for Visual-Inertial System Calibration via Model-based Heuristic Deep Reinforcement Learning},
  author={Chen, Le and Ao, Yunke and Tschopp, Florian and Cramariuc, Andrei and Breyer, Michel and Chung, Jen Jen and Siegwart, Roland and Cadena, Cesar},
  journal={arXiv preprint arXiv:2011.02574},
  year={2020}
}

4 Code reference:

Our code is based on the following repositories:

Owner
ETHZ ASL
ETHZ ASL
Code for CVPR2021 paper 'Where and What? Examining Interpretable Disentangled Representations'.

PS-SC GAN This repository contains the main code for training a PS-SC GAN (a GAN implemented with the Perceptual Simplicity and Spatial Constriction c

Xinqi/Steven Zhu 40 Dec 16, 2022
Revisiting Contrastive Methods for Unsupervised Learning of Visual Representations. [2021]

Revisiting Contrastive Methods for Unsupervised Learning of Visual Representations This repo contains the Pytorch implementation of our paper: Revisit

Wouter Van Gansbeke 80 Nov 20, 2022
Simple API for UCI Machine Learning Dataset Repository (search, download, analyze)

A simple API for working with University of California, Irvine (UCI) Machine Learning (ML) repository Table of Contents Introduction About Page of the

Tirthajyoti Sarkar 223 Dec 05, 2022
Autonomous Driving on Curvy Roads without Reliance on Frenet Frame: A Cartesian-based Trajectory Planning Method

C++/ROS Source Codes for "Autonomous Driving on Curvy Roads without Reliance on Frenet Frame: A Cartesian-based Trajectory Planning Method" published in IEEE Trans. Intelligent Transportation Systems

Bai Li 88 Dec 23, 2022
[NeurIPS'21] "AugMax: Adversarial Composition of Random Augmentations for Robust Training" by Haotao Wang, Chaowei Xiao, Jean Kossaifi, Zhiding Yu, Animashree Anandkumar, and Zhangyang Wang.

AugMax: Adversarial Composition of Random Augmentations for Robust Training Haotao Wang, Chaowei Xiao, Jean Kossaifi, Zhiding Yu, Anima Anandkumar, an

VITA 112 Nov 07, 2022
Motion and Shape Capture from Sparse Markers

MoSh++ This repository contains the official chumpy implementation of mocap body solver used for AMASS: AMASS: Archive of Motion Capture as Surface Sh

Nima Ghorbani 135 Dec 23, 2022
Apply a perspective transformation to a raster image inside Inkscape (no need to use an external software such as GIMP or Krita).

Raster Perspective Apply a perspective transformation to bitmap image using the selected path as envelope, without the need to use an external softwar

s.ouchene 19 Dec 22, 2022
Provably Rare Gem Miner.

Provably Rare Gem Miner just another random project by yoyoismee.eth useful link main site market contract useful thing you should know read contract

34 Nov 22, 2022
StarGAN v2-Tensorflow - Simple Tensorflow implementation of StarGAN v2

Official Tensorflow implementation Open ! - Clova AI StarGAN v2 — Un-official TensorFlow Implementation [Paper] [Pytorch] : Diverse Image Synthesis f

Junho Kim 110 Jul 02, 2022
PoseViz – Multi-person, multi-camera 3D human pose visualization tool built using Mayavi.

PoseViz – 3D Human Pose Visualizer Multi-person, multi-camera 3D human pose visualization tool built using Mayavi. As used in MeTRAbs visualizations.

István Sárándi 79 Dec 30, 2022
An inofficial PyTorch implementation of PREDATOR based on KPConv.

PREDATOR: Registration of 3D Point Clouds with Low Overlap An inofficial PyTorch implementation of PREDATOR based on KPConv. The code has been tested

ZhuLifa 14 Aug 03, 2022
Code samples for my book "Neural Networks and Deep Learning"

Code samples for "Neural Networks and Deep Learning" This repository contains code samples for my book on "Neural Networks and Deep Learning". The cod

Michael Nielsen 13.9k Dec 26, 2022
A curated list of neural rendering resources.

Awesome-of-Neural-Rendering A curated list of neural rendering and related resources. Please feel free to pull requests or open an issue to add papers

Zhiwei ZHANG 43 Dec 09, 2022
Experiments and examples converting Transformers to ONNX

Experiments and examples converting Transformers to ONNX This repository containes experiments and examples on converting different Transformers to ON

Philipp Schmid 4 Dec 24, 2022
Machine Learning Framework for Operating Systems - Brings ML to Linux kernel

KML: A Machine Learning Framework for Operating Systems & Storage Systems Storage systems and their OS components are designed to accommodate a wide v

File systems and Storage Lab (FSL) 186 Nov 24, 2022
Based on Stockfish neural network(similar to LcZero)

MarcoEngine Marco Engine - interesnaya neyronnaya shakhmatnaya set', kotoraya ispol'zuyet metod samoobucheniya(dostizheniye khoroshoy igy putem proboy

Marcus Kemaul 4 Mar 12, 2022
iNAS: Integral NAS for Device-Aware Salient Object Detection

iNAS: Integral NAS for Device-Aware Salient Object Detection Introduction Integral search design (jointly consider backbone/head structures, design/de

顾宇超 77 Dec 02, 2022
Fader Networks: Manipulating Images by Sliding Attributes - NIPS 2017

FaderNetworks PyTorch implementation of Fader Networks (NIPS 2017). Fader Networks can generate different realistic versions of images by modifying at

Facebook Research 753 Dec 23, 2022
These are the materials for the paper "Few-Shot Out-of-Domain Transfer Learning of Natural Language Explanations"

Few-shot-NLEs These are the materials for the paper "Few-Shot Out-of-Domain Transfer Learning of Natural Language Explanations". You can find the smal

Yordan Yordanov 0 Oct 21, 2022
TextureGAN in Pytorch

TextureGAN This code is our PyTorch implementation of TextureGAN [Project] [Arxiv] TextureGAN is a generative adversarial network conditioned on sketc

Patsorn 147 Dec 14, 2022