Main MRPT website > C++ reference for MRPT 1.5.7
Macros | Typedefs | Functions
KmUtils.h File Reference
#include <mrpt/config.h>
#include <memory.h>
#include <cstdlib>
Include dependency graph for KmUtils.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define ENABLE_KMEANS_ASSERTS
 
#define KM_ASSERT(expression)   (void)((expression) != 0? 0 : __KMeansAssertionFailure(__FILE__, __LINE__, #expression))
 

Typedefs

typedef double Scalar
 

Functions

ScalarPointAllocate (int d)
 
void PointFree (Scalar *p)
 
void PointCopy (Scalar *p1, const Scalar *p2, int d)
 
void PointAdd (Scalar *p1, const Scalar *p2, int d)
 
void PointScale (Scalar *p, Scalar scale, int d)
 
Scalar PointDistSq (const Scalar *p1, const Scalar *p2, int d)
 
int __KMeansAssertionFailure (const char *file, int line, const char *expression)
 
int GetRandom (int n)
 

Macro Definition Documentation

#define ENABLE_KMEANS_ASSERTS

Definition at line 81 of file KmUtils.h.

#define KM_ASSERT (   expression)    (void)((expression) != 0? 0 : __KMeansAssertionFailure(__FILE__, __LINE__, #expression))

Typedef Documentation

typedef double Scalar

Definition at line 41 of file KmUtils.h.

Function Documentation

int __KMeansAssertionFailure ( const char *  file,
int  line,
const char *  expression 
)

Definition at line 17 of file KmUtils.cpp.

int GetRandom ( int  n)
inline

Definition at line 96 of file KmUtils.h.

Referenced by RunKMeans(), and KmTree::SeedKMeansPlusPlus().

void PointAdd ( Scalar p1,
const Scalar p2,
int  d 
)
inline

Definition at line 60 of file KmUtils.h.

Referenced by KmTree::BuildNodes(), and KmTree::DoKMeansStepAtNode().

Scalar* PointAllocate ( int  d)
inline

Definition at line 47 of file KmUtils.h.

Referenced by KmTree::BuildNodes(), KmTree::DoKMeansStep(), and KmTree::KmTree().

void PointCopy ( Scalar p1,
const Scalar p2,
int  d 
)
inline

Definition at line 55 of file KmUtils.h.

References mrpt::system::os::memcpy().

Referenced by KmTree::BuildNodes(), KmTree::DoKMeansStep(), and KmTree::KmTree().

Scalar PointDistSq ( const Scalar p1,
const Scalar p2,
int  d 
)
inline
void PointFree ( Scalar p)
inline

Definition at line 51 of file KmUtils.h.

Referenced by KmTree::BuildNodes(), KmTree::DoKMeansStep(), and KmTree::KmTree().

void PointScale ( Scalar p,
Scalar  scale,
int  d 
)
inline

Definition at line 65 of file KmUtils.h.

Referenced by KmTree::BuildNodes(), and KmTree::DoKMeansStep().




Page generated by Doxygen 1.8.11 for MRPT 1.5.7 Git: 2190203 Tue May 15 02:01:15 2018 +0200 at miƩ may 16 12:40:16 CEST 2018