• Stars
    star
    127
  • Rank 282,790 (Top 6 %)
  • Language
    Python
  • License
    MIT License
  • Created about 3 years ago
  • Updated 8 months ago

Reviews

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

Repository Details

Real-time Neural Representation Fusion for Robust Volumetric Mapping

NeuralBlox: Real-Time Neural Representation Fusion for Robust Volumetric Mapping

This repository contains NeuralBlox, our framework for volumetric mapping in latent neural representation space.

teaser

Table of Contents

Paper

If you find our code or paper useful, please consider citing us:

  • Stefan Lionar*, Lukas Schmid*, Cesar Cadena, Roland Siegwart, and Andrei Cramariuc. "NeuralBlox: Real-Time Neural Representation Fusion for Robust Volumetric Mapping", International Conference on 3D Vision (3DV), pp. 1279-1289, 2021. (* equal contribution) [ IEEE | ArXiv | Supplementary ]
    @inproceedings{lionar2021neuralblox,
     title = {NeuralBlox: Real-Time Neural Representation Fusion for Robust Volumetric Mapping},
     author={Stefan Lionar, Lukas Schmid, Cesar Cadena, Roland Siegwart, Andrei Cramariuc},
     booktitle={2021 International Conference on 3D Vision (3DV)}, 
     year={2021},
     pages={1279-1289},
     doi={10.1109/3DV53792.2021.00135}}
    }

Installation

conda env create -f environment.yaml
conda activate neuralblox
pip install torch-scatter==2.0.4 -f https://pytorch-geometric.com/whl/torch-1.4.0+cu101.html

Note: Make sure torch-scatter and PyTorch have the same cuda toolkit version. If PyTorch has a different cuda toolkit version, run:

conda install pytorch==1.4.0 cudatoolkit=10.1 -c pytorch

Next, compile the extension modules. You can do this via

python setup.py build_ext --inplace

Optional: For a noticeably faster inference on CPU-only settings, upgrade PyTorch and PyTorch Scatter to a newer version:

pip install torch==1.7.1+cu101 torchvision==0.8.2+cu101 -f https://download.pytorch.org/whl/torch_stable.html
pip install --upgrade --no-deps --force-reinstall torch-scatter==2.0.5 -f https://pytorch-geometric.com/whl/torch-1.7.1+cu101.html

Demo

To generate meshes using our pretrained models and evaluation dataset, you can select several configurations below and run it.

python generate_sequential.py configs/fusion/pretrained/redwood_0.5voxel_demo.yaml
python generate_sequential.py configs/fusion/pretrained/redwood_1voxel_demo.yaml
python generate_sequential.py configs/fusion/pretrained/redwood_1voxel_demo_cpu.yaml --no_cuda
  • The mesh will be generated to out_mesh/mesh folder.
  • To add noise, change the values under test.scene.noise in the config files.

Training backbone encoder and decoder

The backbone encoder and decoder mainly follow Convolutional Occupancy Networks (https://github.com/autonomousvision/convolutional_occupancy_networks) with some modifications adapted for our use case. Our pretrained model is provided in this repository.

Dataset

ShapeNet

The proprocessed ShapeNet dataset is from Occupancy Networks (https://github.com/autonomousvision/occupancy_networks). You can download it (73.4 GB) by running:

bash scripts/download_shapenet_pc.sh

After that, you should have the dataset in data/ShapeNet folder.

Training

To train the backbone network from scratch, run

python train_backbone.py configs/pointcloud/shapenet_grid24_pe.yaml

Latent code fusion

The pretrained fusion network is also provided in this repository.

Training dataset

To train from scratch, you can download our preprocessed Redwood Indoor RGBD Scan dataset by running:

bash scripts/download_redwood_preprocessed.sh

We align the gravity direction to be the same as ShapeNet ([0,1,0]) and convert the RGBD scans following ShapeNet format.

More information about the dataset is provided here: http://redwood-data.org/indoor_lidar_rgbd/.

Training

To train the fusion network from scratch, run

python train_fusion.py configs/fusion/train_fusion_redwood.yaml

Adjust the path to the encoder-decoder model in training.backbone_file of the .yaml file if necessary.

Generation

python generate_sequential.py CONFIG.yaml

If you are interested in generating the meshes from other dataset, e.g., ScanNet:

  • Structure the dataset following the format in demo/redwood_apartment_13k.
  • Adjust path, data_preprocessed_interval and intrinsics in the config file.
  • If necessary, align the dataset to have the same gravity direction as ShapeNet by adjusting align in the config file.

For example,

# ScanNet scene ID 0
python generate_sequential.py configs/fusion/pretrained/scannet_000.yaml

# ScanNet scene ID 24
python generate_sequential.py configs/fusion/pretrained/scannet_024.yaml

To use your own models, replace test.model_file (encoder-decoder) and test.merging_model_file (fusion network) in the config file to the path of your models.

Evaluation

You can evaluate the predicted meshes with respect to a ground truth mesh by following the steps below:

  1. Install CloudCompare
sudo apt install cloudcompare
  1. Copy a ground truth mesh (no RGB information expected) to evaluation/mesh_gt
  2. Copy prediction meshes to evaluation/mesh_pred
  3. If the prediction mesh does not contain RGB information, such as the output from our method, run:
python evaluate.py

Else, if it contains RGB information, such as the output from Voxblox, run:

python evaluate.py --color_mesh

We provide the trimmed mesh used for the ground truth of our quantitative evaluation. It can be downloaded here.

Lastly, to evaluate prediction meshes with respect to the trimmed mesh as ground truth, run:

python evaluate.py --demo

Or for colored mesh (e.g. from Voxblox):

python evaluate.py --demo --color_mesh

evaluation.csv will be generated to evaluation directory.

Acknowledgement

Some parts of the code are inherited from the official repository of Convolutional Occupancy Networks (https://github.com/autonomousvision/convolutional_occupancy_networks).

More Repositories

1

kalibr

The Kalibr visual-inertial calibration toolbox
C++
4,357
star
2

maplab

A Modular and Multi-Modal Mapping Framework
C++
2,610
star
3

voxblox

A library for flexible voxel-based mapping, mainly focusing on truncated and Euclidean signed distance fields.
C++
1,336
star
4

rotors_simulator

RotorS is a UAV gazebo simulator
C++
1,245
star
5

okvis

OKVIS: Open Keyframe-based Visual-Inertial SLAM.
C++
1,158
star
6

rovio

C++
1,126
star
7

segmap

A map representation based on 3D segments
C++
1,070
star
8

ethzasl_msf

MSF - Modular framework for multi sensor fusion based on an Extended Kalman Filter (EKF)
C++
985
star
9

lidar_align

A simple method for finding the extrinsic calibration between a 3D lidar and a 6-dof pose sensor
C++
836
star
10

hfnet

From Coarse to Fine: Robust Hierarchical Localization at Large Scale with HF-Net (https://arxiv.org/abs/1812.03506)
Python
739
star
11

mav_active_3d_planning

Modular framework for online informative path planning.
C++
564
star
12

mav_trajectory_generation

Polynomial trajectory generation and optimization, especially for rotary-wing MAVs.
C++
548
star
13

polygon_coverage_planning

Coverage planning in general polygons with holes.
C++
528
star
14

aerial_mapper

Real-time Dense Point Cloud, Digital Surface Map (DSM) and (Ortho-)Mosaic Generation for UAVs
C++
524
star
15

voxgraph

Voxblox-based Pose graph optimization
C++
513
star
16

robust_point_cloud_registration

Robust Point Cloud Registration Using Iterative Probabilistic Data Associations ("Robust ICP")
C++
513
star
17

mav_voxblox_planning

MAV planning tools using voxblox as the map representation.
Makefile
463
star
18

hand_eye_calibration

Python tools to perform time-synchronization and hand-eye calibration.
Python
439
star
19

dynablox

Real-time detection of diverse dynamic objects in complex environments.
C++
436
star
20

voxblox-plusplus

A volumetric object-level semantic mapping framework.
C++
409
star
21

mav_control_rw

Control strategies for rotary wing Micro Aerial Vehicles using ROS
C
350
star
22

ethzasl_sensor_fusion

time delay single and multi sensor fusion framework based on an EKF
C++
327
star
23

nbvplanner

A real-time capable exploration and inspection path planner (next best view planning)
C++
295
star
24

panoptic_mapping

A flexible submap-based framework towards spatio-temporally consistent volumetric mapping and scene understanding.
C++
275
star
25

ethzasl_icp_mapping

3D mapping tools for robotic applications
C++
268
star
26

okvis_ros

OKVIS: Open Keyframe-based Visual-Inertial SLAM (ROS Version)
C++
256
star
27

versavis

An Open Versatile Multi-Camera Visual-Inertial Sensor Suite
C++
256
star
28

kitti_to_rosbag

Dataset tools for working with the KITTI dataset raw data ( http://www.cvlibs.net/datasets/kitti/raw_data.php ) and converting it to a ROS bag. Also allows a library for direct access to poses, velodyne scans, and images.
C++
248
star
29

laser_slam

This package provides an end-to-end system to laser-based graph SLAM using laser point clouds.
C++
248
star
30

geodetic_utils

Simple library for converting coordinates to/from several geodetic frames (lat/lon, ECEF, ENU, NED, etc.)
C++
247
star
31

COIN-LIO

🪙 COIN-LIO: Complementary Intensity-Augmented LiDAR Inertial Odometry (ICRA 2024)
C++
245
star
32

image_undistort

A compact package for undistorting images directly from kalibr calibration files. Can also perform dense stereo estimation
C++
245
star
33

ethzasl_ptam

Modified version of Parallel Tracking and Mapping (PTAM)
C++
235
star
34

wavemap

Fast, efficient and accurate multi-resolution, multi-sensor 3D occupancy mapping
C++
226
star
35

cblox

Voxblox-based submapping
C++
207
star
36

aslam_cv2

C++
196
star
37

glocal_exploration

Efficient local and global exploration on submap collections with changing past pose estimates.
C++
186
star
38

volumetric_mapping

A repository for 3D volumetric (occupancy) maps, providing a generic interface for disparity map and pointcloud insertion, and support for custom sensor error models.
C++
186
star
39

vgn

Real-time 6 DOF grasp detection in clutter.
Python
181
star
40

hierarchical_loc

Deep image retrieval for efficient 6-DoF localization
Python
172
star
41

orb_slam_2_ros

ROS interface for ORBSLAM2!!
C++
171
star
42

mav_dji_ros_interface

Interface of DJI autopilot based on its OSDK (3.2)
C++
156
star
43

lidar_undistortion

Catkin package that provides lidar motion undistortion based on an external 6DoF pose estimation input.
C++
145
star
44

programming_guidelines

This repository contains style-guides, discussions, eclipse/emacs auto-formatter for commonly used programming languages
Emacs Lisp
139
star
45

tsdf-plusplus

TSDF++: A Multi-Object Formulation for Dynamic Object Tracking and Reconstruction
C++
135
star
46

odom_predictor

Integrates an IMU to predict future odometry readings
C++
134
star
47

depth_segmentation

A collection of segmentation methods working on depth images
C++
133
star
48

grid_map_geo

Geolocalization for grid map using GDAL.
C++
129
star
49

StructuralInspectionPlanner

ASL Structural Inspection Planner
C++
108
star
50

phaser

A robust pointcloud registration pipeline based on correlation.
C++
106
star
51

eth_supermegabot

Instructions for ETH center for robotics summer school 2019.
Python
102
star
52

terrain-navigation

Repository for Safe Low Altitude Navigation in steep terrain for fixed-wing Aerial Vehicles
C++
98
star
53

waypoint_navigator

Stand-alone waypoint navigator
C++
96
star
54

ethzasl_xsens_driver

Driver for xsens IMUs
Python
96
star
55

mav_tools_public

General launch files, parameters and wiki entries on our systems and related issues
95
star
56

data-driven-dynamics

Data Driven Dynamics Modeling for Aerial Vehicles
Python
94
star
57

reinmav-gym

Reinforcement Learning framework for MAVs using the OpenAI Gym environment
Python
93
star
58

cuckoo_time_translator

algorithms for synchronizing clocks
C++
88
star
59

minkindr

A minimal library for transformations, following the kindr interface. Uses active quaternions of rotation in Hamilton notation.
C++
88
star
60

unreal_airsim

Simulation interface to Unreal Engine 4 based on the AirSim plugin.
C++
87
star
61

waverider

RMPs on multi-resolution occupancy maps for efficient reactive collision avoidance
87
star
62

ethz_piksi_ros

ROS drivers for the Piksi RTK GPS module
C++
85
star
63

sl_sensor

SL Sensor: An open-source, real-time and ROS-based structured light sensor for high accuracy construction robotic applications
C++
84
star
64

voxblox_ground_truth

Create ground truth voxblox maps from Gazebo worlds or .ply files
C++
83
star
65

vicon_bridge

This is a driver providing data from VICON motion capture systems. It is based on the vicon_mocap package from the starmac stacks. Additionally, it can handle multiple subjects / segments and allows to calibrate an origin of the vehicle(s) as this is somehow tedious with the VICON Tracker.
C++
80
star
66

ros-system-monitor

System monitoring tools for ROS.
Python
80
star
67

navrep

Python
73
star
68

curves

A library of curves for estimation.
C++
72
star
69

schweizer_messer

Programming tools for robotics.
C++
65
star
70

time_autosync

Automatically syncs a camera to a rigidly attached IMUs time frame
C++
63
star
71

unreal_cv_ros

Unreal CV ROS Perception Simulator
Python
62
star
72

ai_for_robotics

Programming Exercises Accompanying the Lecture "Artificial Intelligence for Robotics"
Python
60
star
73

lcd

Line Clustering and Description for Place Recognition
C++
59
star
74

trajectory_toolkit

Python tool for analyzing and evaluating trajectory data
Python
59
star
75

dataset_tools

Loader for the generic ASL dataset formats.
MATLAB
58
star
76

rl-navigation

OpenEdge ABL
57
star
77

asl-student-templates

Templates and overview information for student projects at ASL
PostScript
56
star
78

libseekthermal

Driver library for Seek Thermal imaging devices
C++
55
star
79

reactive_avoidance

Reactive obstacle avoidance using raytracing or lidars
C++
52
star
80

plotty

matplotlib-cpp with Eigen interfaces.
C++
52
star
81

forest_gen

Generates randomized Poisson forests to use for UAV collision avoidance evaluations.
Python
49
star
82

3d_vsg

3D Variable Scene Graphs for long-term semantic scene change prediction.
Python
49
star
83

sampling_based_control

Jupyter Notebook
47
star
84

mav_comm

This repository contains message and service definitions used for mavs. All future message definitions go in here, existing ones in other stacks should be moved here where possible.
C++
46
star
85

tmplanner

Terrain monitoring planner
C++
45
star
86

3d3l

Deep Learned Keypoint Detection and Description for 3D LiDARs
Python
44
star
87

fgsp

Jupyter Notebook
44
star
88

autolabel

A project for computing high-quality ground truth training examples for RGB-D data.
Python
43
star
89

mav_gtsam_estimator

A GTSAM based state estimation framework.
C++
43
star
90

visensor_node

Visual inertial SLAM sensor ROS node.
C++
43
star
91

Learn-to-Calibrate

We utilize deep reinforcement learning to obtain favorable trajectories for visual-inertial system calibration.
C++
43
star
92

cvae_exploration_planning

Learning informed sampling distributions and information gains for efficient exploration planning.
Python
42
star
93

active_grasp

Closed-loop next-best view planning for grasp detection in clutter.
Python
41
star
94

two_state_information_filter

C++
41
star
95

ssc_exploration

Incremental 3D Scene Completion for Safe and Efficient Exploration Mapping and Planning
41
star
96

maplab_rovio

Hard-fork of ROVIO to integrate localization.
C++
40
star
97

rtklibros

rtklib with ros interfacing and adapted feedback from external Kalman filter
C
40
star
98

libvisensor

Low level hardware driver for the visual inertial SLAM sensor.
C++
39
star
99

3dsnet

3DSNet: Unsupervised Shape-to-shape 3D Style Transfer
C++
39
star
100

mav_system_identification

Matlab scripts to perform system identification for muti-rotor systems
MATLAB
38
star