mlpack  1.0.12
Public Member Functions | Private Attributes | List of all members
mlpack::metric::IPMetric< KernelType > Class Template Reference

Public Member Functions

 IPMetric ()
 Create the IPMetric without an instantiated kernel. More...
 
 IPMetric (KernelType &kernel)
 Create the IPMetric with an instantiated kernel. More...
 
 ~IPMetric ()
 Destroy the IPMetric object. More...
 
template<typename Vec1Type , typename Vec2Type >
double Evaluate (const Vec1Type &a, const Vec2Type &b)
 Evaluate the metric. More...
 
const KernelType & Kernel () const
 Get the kernel. More...
 
KernelType & Kernel ()
 Modify the kernel. More...
 
std::string ToString () const
 Returns a string representation of this object. More...
 

Private Attributes

KernelType & kernel
 The reference to the kernel that is being used. More...
 
KernelType * localKernel
 The locally stored kernel, if it is necessary. More...
 

Detailed Description

template<typename KernelType>
class mlpack::metric::IPMetric< KernelType >

Definition at line 22 of file ip_metric.hpp.

Constructor & Destructor Documentation

template<typename KernelType>
mlpack::metric::IPMetric< KernelType >::IPMetric ( )

Create the IPMetric without an instantiated kernel.

template<typename KernelType>
mlpack::metric::IPMetric< KernelType >::IPMetric ( KernelType &  kernel)

Create the IPMetric with an instantiated kernel.

template<typename KernelType>
mlpack::metric::IPMetric< KernelType >::~IPMetric ( )

Destroy the IPMetric object.

Member Function Documentation

template<typename KernelType>
template<typename Vec1Type , typename Vec2Type >
double mlpack::metric::IPMetric< KernelType >::Evaluate ( const Vec1Type &  a,
const Vec2Type &  b 
)

Evaluate the metric.

template<typename KernelType>
const KernelType& mlpack::metric::IPMetric< KernelType >::Kernel ( ) const
inline

Get the kernel.

Definition at line 41 of file ip_metric.hpp.

References mlpack::metric::IPMetric< KernelType >::kernel.

template<typename KernelType>
KernelType& mlpack::metric::IPMetric< KernelType >::Kernel ( )
inline

Modify the kernel.

Definition at line 43 of file ip_metric.hpp.

References mlpack::metric::IPMetric< KernelType >::kernel.

template<typename KernelType>
std::string mlpack::metric::IPMetric< KernelType >::ToString ( ) const

Returns a string representation of this object.

Member Data Documentation

template<typename KernelType>
KernelType& mlpack::metric::IPMetric< KernelType >::kernel
private

The reference to the kernel that is being used.

Definition at line 52 of file ip_metric.hpp.

Referenced by mlpack::metric::IPMetric< KernelType >::Kernel().

template<typename KernelType>
KernelType* mlpack::metric::IPMetric< KernelType >::localKernel
private

The locally stored kernel, if it is necessary.

Definition at line 50 of file ip_metric.hpp.


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