deblais
Exact optimal transport between point clouds
Loading...
Searching...
No Matches
deblais, C++ API reference

Exact optimal transport between weighted point clouds for the squared Euclidean cost. Header only, C++17, OpenMP.

std::vector<double> x = ..., y = ...; // n points of dimension 2 each
deblais::Plan plan = deblais::solve(2, x, y);
plan.cost; // squared Wasserstein-2 distance
plan.source[k], plan.target[k], plan.mass[k]; // sparse optimal plan
Umbrella header of deblais: exact optimal transport between point clouds.
Plan solve(const Cloud &source, const Cloud &target, const Options &options=Options())
Solves the optimal transport problem between two weighted point clouds for the cost (Options::p,...
Definition solve.hpp:486
An optimal transport plan and its dual certificate.
Definition plan.hpp:66
std::vector< double > mass
Mass shipped along every arc, in the units of the source masses.
Definition plan.hpp:86
std::vector< std::int32_t > target
Index of the target point of every arc.
Definition plan.hpp:84
std::vector< std::int32_t > source
Index of the source point of every arc.
Definition plan.hpp:82
double cost
Transport cost .
Definition plan.hpp:77
Entry point Role
deblais::solve() Solves a problem and returns a deblais::Plan
deblais::Options Method, threads and tuning; the default is the automatic mode
deblais::recipe() What the automatic mode chooses for a given size
deblais::certify() Independent optimality check of a plan

This reference is generated from the comments of the headers. The guides (getting started, concepts, automatic mode, performance, Python API) are in the documentation.