Public Types | Public Member Functions
rtflann::GroupWiseCenterChooser< Distance > Class Template Reference

#include <center_chooser.h>

Inheritance diagram for rtflann::GroupWiseCenterChooser< Distance >:
Inheritance graph
[legend]

List of all members.

Public Types

typedef Distance::ResultType DistanceType
typedef Distance::ElementType ElementType

Public Member Functions

 GroupWiseCenterChooser (const Distance &distance, const std::vector< ElementType * > &points)
void operator() (int k, int *indices, int indices_length, int *centers, int &centers_length)

Detailed Description

template<typename Distance>
class rtflann::GroupWiseCenterChooser< Distance >

Chooses the initial centers in a way inspired by Gonzales (by Pierre-Emmanuel Viel): select the first point of the list as a candidate, then parse the points list. If another point is further than current candidate from the other centers, test if it is a good center of a local aggregation. If it is, replace current candidate by this point. And so on...

Used with KMeansIndex that computes centers coordinates by averaging positions of clusters points, this doesn't make a real difference with previous methods. But used with HierarchicalClusteringIndex class that pick centers among existing points instead of computing the barycenters, there is a real improvement.

Definition at line 307 of file center_chooser.h.


Member Typedef Documentation

template<typename Distance>
typedef Distance::ResultType rtflann::GroupWiseCenterChooser< Distance >::DistanceType

Reimplemented from rtflann::CenterChooser< Distance >.

Definition at line 311 of file center_chooser.h.

template<typename Distance>
typedef Distance::ElementType rtflann::GroupWiseCenterChooser< Distance >::ElementType

Reimplemented from rtflann::CenterChooser< Distance >.

Definition at line 310 of file center_chooser.h.


Constructor & Destructor Documentation

template<typename Distance>
rtflann::GroupWiseCenterChooser< Distance >::GroupWiseCenterChooser ( const Distance &  distance,
const std::vector< ElementType * > &  points 
) [inline]

Definition at line 317 of file center_chooser.h.


Member Function Documentation

template<typename Distance>
void rtflann::GroupWiseCenterChooser< Distance >::operator() ( int  k,
int *  indices,
int  indices_length,
int *  centers,
int &  centers_length 
) [inline, virtual]

Chooses cluster centers

Parameters:
knumber of centers to choose
indicesindices of points to choose the centers from
indices_lengthlength of indices
centersindices of chosen centers
centers_lengthlength of centers array

Implements rtflann::CenterChooser< Distance >.

Definition at line 320 of file center_chooser.h.


The documentation for this class was generated from the following file:


rtabmap
Author(s): Mathieu Labbe
autogenerated on Thu Jun 6 2019 21:59:42