All Projects → gadomski → Cpd

gadomski / Cpd

Licence: gpl-2.0
C++ implementation of the Coherent Point Drift point set registration algorithm.

Projects that are alternatives of or similar to Cpd

Open3d
Open3D: A Modern Library for 3D Data Processing
Stars: ✭ 5,860 (+2153.85%)
Mutual labels:  pointcloud, registration
SpinNet
[CVPR 2021] SpinNet: Learning a General Surface Descriptor for 3D Point Cloud Registration
Stars: ✭ 181 (-30.38%)
Mutual labels:  registration, pointcloud
D3feat
[TensorFlow] Implementation of CVPR'20 oral paper - D3Feat: Joint Learning of Dense Detection and Description of 3D Local Features https://arxiv.org/abs/2003.03164
Stars: ✭ 143 (-45%)
Mutual labels:  pointcloud, registration
D3Feat.pytorch
[PyTorch] Official Implementation of CVPR'20 oral paper - D3Feat: Joint Learning of Dense Detection and Description of 3D Local Features https://arxiv.org/abs/2003.03164
Stars: ✭ 99 (-61.92%)
Mutual labels:  registration, pointcloud
Deepglobalregistration
[CVPR 2020 Oral] A differentiable framework for 3D registration
Stars: ✭ 222 (-14.62%)
Mutual labels:  pointcloud, registration
CovGT-3DRegistration-matlab
A 3D Scene Registration Method via Covariance Descriptors and an Evolutionary Stable Strategy Game Theory Solver
Stars: ✭ 20 (-92.31%)
Mutual labels:  registration, pointcloud
oxd
Client software to secure apps with OAuth 2.0, OpenID Connect, and UMA
Stars: ✭ 40 (-84.62%)
Mutual labels:  registration
Handy3DScanner
Repository for Handy 3D Scanner
Stars: ✭ 54 (-79.23%)
Mutual labels:  pointcloud
geotrellis-pointcloud
GeoTrellis PointCloud library to work with any pointcloud data on Spark
Stars: ✭ 21 (-91.92%)
Mutual labels:  pointcloud
connect
SUSEConnect Client
Stars: ✭ 13 (-95%)
Mutual labels:  registration
Kratos
Next-gen identity server (think Auth0, Okta, Firebase) with Ory-hardened authentication, MFA, FIDO2, profile management, identity schemas, social sign in, registration, account recovery, and IoT auth. Golang, headless, API-only - without templating or theming headaches.
Stars: ✭ 4,684 (+1701.54%)
Mutual labels:  registration
matrix-register-bot
Bot that offers two step registrations to a matrix-synapse server
Stars: ✭ 25 (-90.38%)
Mutual labels:  registration
login-signup-form
A login and signup form using HTML, PHP, and MySQL. This form allows users to register and login. All information is stored in a MySQL database. After successful login the user is redirected to their dashboard. Project Website:
Stars: ✭ 40 (-84.62%)
Mutual labels:  registration
DICOMautomaton
A multipurpose tool for medical physics.
Stars: ✭ 35 (-86.54%)
Mutual labels:  registration
MVP Benchmark
MVP Benchmark for Multi-View Partial Point Cloud Completion and Registration
Stars: ✭ 74 (-71.54%)
Mutual labels:  pointcloud
is-04
AMWA IS-04 NMOS Discovery and Registration Specification (Stable)
Stars: ✭ 35 (-86.54%)
Mutual labels:  registration
mitsuba-visualize
Visualizes meshes, pointclouds and video flythroughs in publication quality
Stars: ✭ 67 (-74.23%)
Mutual labels:  pointcloud
mp2p icp
Multi primitive-to-primitive (MP2P) ICP algorithms in C++
Stars: ✭ 84 (-67.69%)
Mutual labels:  registration
astroalign
A tool to align astronomical images based on asterism matching
Stars: ✭ 102 (-60.77%)
Mutual labels:  registration
reactjs-login-register-crud
ReactJS CRUD Application, ReactJS FileUpload, ReactJS Sample application, ReactJS Boilerplate, ReactJS Login, ReactJS FileUpload, ReactJS Register
Stars: ✭ 47 (-81.92%)
Mutual labels:  registration

cpd

Coherent Point Drift (CPD) is a point-set registration algorithm, originally developed by Andriy Myronenko et al. This is a C++ library that runs CPD.

CPD can be compared to Iterative Closest Point, another point-set registration algorithm that is widely used. While ICP minimizes point-to-point distances, CPD uses a Gaussian Mixture Model to minimize the error between a point and all other points. If you're thinking that this is very computationally intensive, you're right — both the CPD algorithm and the underlying error calculations take a lot of time, which is why we've created fgt to speed up those Gauss transforms. We hope this library provides a freer and more performant alternative to the original reference Matlab implementation.

This library supports three variants of CPD:

  • rigid: Uses a rigid transformation (i.e. rotation and translation, with an optional scaling) to align the two datasets.
  • affine: Uses an affine transformation, with a translation, to align the two datasets.
  • nonrigid: Uses a two-parameter non-rigid transformation function to align the two datasets.

Andriy's reference implementation comes with one other type of registration, nonrigid_lowrank, which is not implemented in the latest version of this library (yet) (see History for information on how to find and use a previous version of this library that has nonrigid_lowrank).

This code lives on Github. It has some Doxygen documentation and is tested by Travis.

Usage

Basic, default usage can be accomplished via some namespace-level methods:

#include <cpd/rigid.hpp>

int main(int argc, char** argv) {
    cpd::Matrix fixed = load_points_from_somewhere();
    cpd::Matrix moving = load_points_from_somewhere();
    cpd::RigidResult result = cpd::rigid(fixed, moving);
    return 0;
}

Configuration is possible via Rigid, Nonrigid, and Affine:

#include <cpd/rigid.hpp>

int main(int argc, char** argv) {
    cpd::Matrix fixed = load_points_from_somewhere();
    cpd::Matrix moving = load_points_from_somewhere();
    cpd::Rigid rigid;
    rigid.correspondence(true).outliers(0.2);
    cpd::RigidResult result = rigid.run(fixed, moving);
    return 0;
}

If cpd is built with the jsoncpp component (see examples/ for a demonstration of the CMake configuration), the results of the cpd run can be converted to json:

#include <iostream>
#include <cpd/jsoncpp.hpp>
#include <cpd/rigid.hpp>

int main(int argc, char** argv) {
    cpd::Matrix fixed = load_points_from_somewhere();
    cpd::Matrix moving = load_points_from_somewhere();
    cpd::RigidResult result = cpd::rigid(fixed, moving);
    std::cout << cpd::to_json(result) << std::endl;
    return 0;
}

See the code and the documentation to discover all possible options, transformation methods, and probability calculation methods.

Examples

See examples/ in this code repository for some basic usage examples, including examples of how to set up a downstream CMake project that depends on cpd.

Installation

cpd depends on and CMake and Eigen at build time only — no runtime dependencies. For additional speed, it can also built with fgt. For json output of results, it can be built with jsoncpp.

On OSX

If you're on a Mac, use homebrew and my tap to install:

brew tap gadomski/gadomski
brew install cpd

From source

Use the usual CMake build incantation:

mkdir build
cd build
cmake ..
make

If you're using a home-built version of jsoncpp, make sure you set the following options when building and installing jsoncpp (this allows cpd to find jsoncpp):

  • JSONCPP_WITH_CMAKE_PACKAGE=ON
  • BUILD_SHARED_LIBS=ON

Using downstream

cpd provides CMake export targets that you can import and use in your own project:

find_package(Cpd REQUIRED)
add_library(my-great-library
    the_code.cpp
    )
target_link_libraries(my-great-library
    PUBLIC
    Cpd::Library-C++
    )

The Cpd::Library-C++ target includes all the interface settings you need, so you shouldn't need any other calls to get set up.

If you'd like to enable json support, use the jsoncpp component:

find_package(Cpd COMPONENTS jsoncpp REQUIRED)
add_library(my-great-library the_code.cpp)
target_link_libraries(my-great-library PUBLIC Cpd::Library-C++ Cpd::Jsoncpp)

OpenMP

Both fgt and Eigen support OpenMP for some operations. As of yet, the interaction between the two is untested, so our official recommendation is to only use OpenMP with one of the projects, not both. If you do some work with OpenMP we'd love to hear how it goes.

Contributing

Github issues and pull requests, per usual.

History

The v0.1 and v0.2 lineages of cpd used armadillo for linear arithmetic instead of Eigen. Armadillo is a bit smoother for doing advanced eigenvalue decompositions and other operations, which made it a bit easier at first to directly port the Matlab reference implementation. For a couple of reasons, we decided to switch to Eigen for v0.3.

First, the Armadillo project had the bad habit of removing old versions from their download site, making it hard to maintain working code as their codebase developed. Second, many downstream applications use Eigen themselves, making Eigen a lower-friction choice for those users.

As of this writing, the Eigen implementation is less feature-full than the old Armadillo implementation, particularly with respect to the nonrigid_lowrank version. If you require some of that old functionality, use the v0.2 branch. If you need armadillo-5.x, which is required for the old cpd but is no longer available from the armadillo website, you can use my mirror. Thanks for your understanding during this switch.

Publications

This library has been used in the following publications:

  • Gadomski, P.J. (December 2016). Measuring Glacier Surface Velocities With LiDAR: A Comparison of Three-Dimensional Change Detection Methods. Master's thesis, University of Houston, Geosensing Systems Engineering and Sciences.

License

This library is GPL2, copyright 2017 Peter J. Gadomski. See LICENSE.txt for the full license text.

This work is directly inspired by Andriy Myronenko's reference implementation, and we owe him many thanks.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].