Git Product home page Git Product logo

cudapcl's Introduction

This gpu-enhanced library implements edge-preserving smoothing of depth frames from standard rgb-d sensors as well as surface normal extraction at a frame rate of 100Hz.

Depth before and after smoothing

Raw depth image vs. guided filter smoothed image on the right. Note that similar to a bilateral filter the guided filter performs edge preserving filtering as can be observed at the sharp discontinuities of the windows.

smoothed surface normals

Extracting surface normals using gradients of the depth image and a cross-product operation yields smoothed surface normals.

Dependencies

This code depends on the following other libraries and was tested under Ubuntu 14.04.

  • pcl 1.7 (and vtk 5.8)
  • Opencv 2 (2.3.1)
  • Eigen3 (3.0.5)
  • cuda 5.5 or 6.5
  • Boost (1.54)

The GPU kernels were tested on a Nvidia Quadro K2000M with compute capability 3.0.

Install

This package uses the pods build system. Used widely at CSAIL MIT the build system makes it easy to break up software projects into small packages that can be checked out and compiled automatically (see below).

  • Linux:

    Install Eigen3, Boost, OpenCV, and PCL

    sudo apt-get install libeigen3-dev libboost-dev libopencv-dev libpcl-1.7-all-dev
    

    Install the appropriate CUDA version matching with your nvidia drivers. On our machines we use nvidia-340-dev with libcuda1-340 cuda-6-5 cuda-toolkit-6-5

    Clone this repository and compile the code:

    git clone [email protected]:jstraub/rtDDPvMF; cd rtDDPvMF;
    make checkout; make configure; make -j6; make install;
    

    Note that this will checkout several other necessary repositories. To update all repositories run

    make update; make configure; make -j6; make install;
    

Getting Started

Plug in your Kinect and run the following from the cudaPcl folder:

 ./build/bin/openniSmoothNormals 

Library

libcudaPcl.so collects all the cuda code into one shared library. The rest of the code is in the form of header files.

Executables

  • openniSmoothNormals: grab RGB-D frames from an openni device, smooth the depth image using a fast GPU enhanced guided filter and extract surface normals.
  Allowed options:
    -h [ --help ]         produce help message
    -f [ --f_d ] arg      focal length of depth camera
    -e [ --eps ] arg      sqrt of the epsilon parameter of the guided filter
    -b [ --B ] arg        guided filter windows size (size will be (2B+1)x(2B+1))
    -c [ --compress ]     compress the computed normals
  • openniSmoothDepth: grab RGB-D frames from an openni device, smooth the depth image using a fast GPU enhanced guided filter and display it.
  Allowed options:
    -h [ --help ]         produce help message
    -e [ --eps ] arg      sqrt of the epsilon parameter of the guided filter
    -b [ --B ] arg        guided filter windows size (size will be (2B+1)x(2B+1))
  • pclNormals: extracts normals from a general (not necessarily aligned) point-cloud and outputs the point-cloud with normals.
  Allowed options:
    -h [ --help ]         produce help message
    -i [ --input ] arg    path to input
    -o [ --output ] arg   path to output
    -s [ --scale ] arg    scale for normal extraction search radius
  • pclBenchmark: display RGBXYZ point-cloud (press 'r' to reset the viewpoint)
  • pclGrabber: grab XYZ point-cloud; press 's' to save point-cloud to "./test_pcd.pcd"

cudapcl's People

Contributors

jstraub avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.