SnapNet for Semantic3D dataset
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.

SnapNet: point cloud semantization using deep segmentation network

SnapNet products


Please acknowledge the authors and the following research paper:

"Unstructured point cloud semantic labeling using deep segmentation networks", A.Boulch and B. Le Saux and N. Audebert, Eurographics Workshop on 3D Object Retrieval 2017

Abstract and paper here.


This work is part of two projects:

  • INACHUS is European FP7 project that aims to achieve a significant time reduction related to Urban Search and Rescue (USaR) phase by providing wide-area situation awareness solutions for improved detection and localisation of the trapped victims assisted by simulation tools for predicting structural failures and a holistic decision support mechanism incorporating operational procedures and resources of relevant actors.
  • DeLTA is a research project hosted at ONERA, The French Aerospace Lab. Among its objectives are the development and the promotion of innovative machine learning based approaches for aerospace applications.


This code and weights are both released under a dual license, research and commercial. Basically the code is GPLv3 for open access (contact us for non open purposes) and the weights are released under Creative Commons BY-NC-SA (contact us for non open purposes). See the license.


The code is composed of two main parts: a C++ library and a python scripts. The C++ library permits to load the files at Semantic 3D format and compute the composite features as described in the paper.

The python scripts generates the views using the Pyqtgraph 3D viewer and predict the segmentation using TensorFlow.



Dependencies in the pointcloud_tools repository :

  • NanoFlann: nanoflann.hpp should be included in the include directory
  • Eigen: Eigen should also be included in the include directory Please note that for Eigen and Nanoflann new versions, you must check the corresponding website.


  • TensorFlow: it is the deep learning framework used in this implementation

  • TQDM, Scipy, Numpy ...

  • (Not necessary on last update) Kaffe: if you want to train a new model using the VGG16 weights, they need to be converted to format compatible with TensorFlow.

In our implementation we used the caffe weights avalaible here.


To generate the C++/Python library.

cd pointcloud_tools
python install --home="."

It will build the library.

Note: in the, we have filled the path with the standard path for PCL installation libraries and headers on Ubuntu 16.04.

Configuration file

The Configuration file is a json file containing the parameters and paths:




    "train_create_mesh" : true,
    "train_create_views" : true,
    "train_create_images" : true,

    "test_create_mesh" : true,
    "test_create_views" : true,
    "test_create_images" : true,

    "batch_size" : 24,
    "learning_rate" : 1e-4,
    "epoch_nbr" : 100,
    "label_nbr" : 10,
    "input_ch" : 3,

    "train_rgb" : true,
    "train_composite" : true,
    "train_fusion" : true,

    "saver_directory_rgb" : "path_to_rgb_model_directory",
    "saver_directory_composite" : "path_to_composite_model_directory",
    "saver_directory_fusion" : "path_to_fusion_model_directory",

It is used in the python scripts, to avoid code recopy.

Launching the python scripts

For the training and testing dataset, the point cloud decimation, views and images generation are called with:

python3 --config config.json

To train the models (rgb, composite and fusion) from scratch, run:

python3 --config config.json

The semantic predictions on images and back-projection on the decimated clouds can be called using:

python3 --config config.json

Finally to generate the files at the Semantic 3D format and assign a label to each point of the original point cloud, run;

python3 --config config.json

Pre-trained models

The pre-trained are available here.

What's next ?

We want to propose a Pytorch implementation.