Orfeo Toolbox  4.0
Public Types | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
otb::SpectralAngleKernelFunctor Class Reference

Spectral Angle Kernel. More...

#include <otbSpectralAngleKernelFunctor.h>

+ Inheritance diagram for otb::SpectralAngleKernelFunctor:
+ Collaboration diagram for otb::SpectralAngleKernelFunctor:

Public Types

typedef MapType::const_iterator MapConstIterator
 
typedef MapType::iterator MapIterator
 
typedef std::map< std::string,
std::string > 
MapType
 
typedef SpectralAngleKernelFunctor Self
 
typedef GenericKernelFunctorBase Superclass
 

Public Member Functions

 SpectralAngleKernelFunctor ()
 
virtual ~SpectralAngleKernelFunctor ()
 
virtual svm_nodeadd (const svm_node *px, const svm_node *py) const
 
virtual GenericKernelFunctorBaseClone () const
 
virtual double derivative (const svm_node *, const svm_node *, const svm_parameter &, int, int, bool, double) const
 
virtual double dot (const svm_node *px, const svm_node *py) const
 
virtual const MapTypeGetMapParameters () const
 
virtual MapType GetMapParameters ()
 
virtual std::string GetName (void) const
 
template<class T >
GetValue (const char *option) const
 
virtual int load_parameters (FILE **pfile)
 
double operator() (const svm_node *x, const svm_node *y, const svm_parameter &param) const
 
virtual void print_parameters (void) const
 
virtual int save_parameters (FILE **pfile, const char *generic_kernel_parameters_keyword) const
 
virtual void SetMapParameters (const MapType &map)
 
virtual void SetName (std::string name)
 
template<class T >
void SetValue (const char *option, const T &value)
 
virtual svm_nodesub (const svm_node *px, const svm_node *py) const
 
void Update ()
 

Protected Member Functions

 SpectralAngleKernelFunctor (const Self &copy)
 
SpectralAngleKernelFunctoroperator= (const Self &copy)
 

Private Member Functions

double SAM (const svm_node *x, const svm_node *y) const
 

Private Attributes

double m_Coef
 

Detailed Description

Spectral Angle Kernel.

Performs an inverse multiquadric kernel evaluation that suits spectral data.

It is of kind:

$ frac{1}{\sqrt{ c_0 + \cos\textrm{SAM(x, y)} }} $ where $ \textrm{SAM(x, y)} $ is Spectral Angle Measure: $ \textrm{SAM}(x, y) = \cos^{-1}\left( \frac{x \cdot y}{\|x\| \|y\|} \right) $.

The only parameter $ c_0 $ is to be fixed by the

interface with keyword Coef (def 2.0).

Definition at line 45 of file otbSpectralAngleKernelFunctor.h.

Member Typedef Documentation

typedef MapType::const_iterator GenericKernelFunctorBase::MapConstIterator
inherited

Definition at line 25 of file svm.h.

typedef MapType::iterator GenericKernelFunctorBase::MapIterator
inherited

Definition at line 24 of file svm.h.

typedef std::map<std::string, std::string> GenericKernelFunctorBase::MapType
inherited

Definition at line 23 of file svm.h.

Definition at line 49 of file otbSpectralAngleKernelFunctor.h.

Definition at line 50 of file otbSpectralAngleKernelFunctor.h.

Constructor & Destructor Documentation

otb::SpectralAngleKernelFunctor::SpectralAngleKernelFunctor ( )

Definition at line 29 of file otbSpectralAngleKernelFunctor.cxx.

virtual otb::SpectralAngleKernelFunctor::~SpectralAngleKernelFunctor ( )
inlinevirtual

Definition at line 62 of file otbSpectralAngleKernelFunctor.h.

otb::SpectralAngleKernelFunctor::SpectralAngleKernelFunctor ( const Self copy)
inlineprotected

Definition at line 69 of file otbSpectralAngleKernelFunctor.h.

Member Function Documentation

virtual svm_node* GenericKernelFunctorBase::add ( const svm_node px,
const svm_node py 
) const
virtualinherited
virtual GenericKernelFunctorBase* otb::SpectralAngleKernelFunctor::Clone ( ) const
inlinevirtual

Reimplemented from GenericKernelFunctorBase.

Definition at line 53 of file otbSpectralAngleKernelFunctor.h.

virtual double GenericKernelFunctorBase::derivative ( const svm_node ,
const svm_node ,
const svm_parameter ,
int  ,
int  ,
bool  ,
double   
) const
virtualinherited
virtual double GenericKernelFunctorBase::dot ( const svm_node px,
const svm_node py 
) const
virtualinherited
virtual const MapType& GenericKernelFunctorBase::GetMapParameters ( ) const
virtualinherited
virtual MapType GenericKernelFunctorBase::GetMapParameters ( )
virtualinherited
virtual std::string GenericKernelFunctorBase::GetName ( void  ) const
virtualinherited
template<class T >
T GenericKernelFunctorBase::GetValue ( const char *  option) const
inlineinherited

Definition at line 59 of file svm.h.

References GenericKernelFunctorBase::m_MapParameters.

virtual int GenericKernelFunctorBase::load_parameters ( FILE **  pfile)
virtualinherited

Reimplemented in ComposedKernelFunctor.

double otb::SpectralAngleKernelFunctor::operator() ( const svm_node x,
const svm_node y,
const svm_parameter param 
) const
virtual

Reimplemented from GenericKernelFunctorBase.

Definition at line 46 of file otbSpectralAngleKernelFunctor.cxx.

SpectralAngleKernelFunctor& otb::SpectralAngleKernelFunctor::operator= ( const Self copy)
inlineprotected
virtual void GenericKernelFunctorBase::print_parameters ( void  ) const
virtualinherited

Reimplemented in ComposedKernelFunctor.

double otb::SpectralAngleKernelFunctor::SAM ( const svm_node x,
const svm_node y 
) const
private

Definition at line 58 of file otbSpectralAngleKernelFunctor.cxx.

virtual int GenericKernelFunctorBase::save_parameters ( FILE **  pfile,
const char *  generic_kernel_parameters_keyword 
) const
virtualinherited

Reimplemented in ComposedKernelFunctor.

virtual void GenericKernelFunctorBase::SetMapParameters ( const MapType map)
virtualinherited
virtual void GenericKernelFunctorBase::SetName ( std::string  name)
virtualinherited
template<class T >
void GenericKernelFunctorBase::SetValue ( const char *  option,
const T &  value 
)
inlineinherited

Definition at line 70 of file svm.h.

References GenericKernelFunctorBase::m_MapParameters.

virtual svm_node* GenericKernelFunctorBase::sub ( const svm_node px,
const svm_node py 
) const
virtualinherited
void otb::SpectralAngleKernelFunctor::Update ( void  )
virtual

Specific implementation of

to split m_MapParameters into specific variables to speed up kernel evaluations

Reimplemented from GenericKernelFunctorBase.

Definition at line 39 of file otbSpectralAngleKernelFunctor.cxx.

Referenced by operator=().

Member Data Documentation

double otb::SpectralAngleKernelFunctor::m_Coef
private

Definition at line 87 of file otbSpectralAngleKernelFunctor.h.


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

Generated at Sat Mar 8 2014 18:59:31 for Orfeo Toolbox with doxygen 1.8.3.1