OTB  9.0.0
Orfeo Toolbox
Public Types | Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep > Class Template Reference

#include <otbHistogramOfOrientedGradientCovariantImageFunction.h>

+ Inheritance diagram for otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >:
+ Collaboration diagram for otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >:

Public Types

typedef itk::SmartPointer< const SelfConstPointer
 
typedef Superclass::ContinuousIndexType ContinuousIndexType
 
typedef TCoordRep CoordRepType
 
typedef Superclass::IndexType IndexType
 
typedef TInputImage InputImageType
 
typedef InputImageType::PixelType InputPixelType
 
typedef TOutputPrecision OutputPrecisionType
 
typedef Superclass::OutputType OutputType
 
typedef itk::SmartPointer< SelfPointer
 
typedef Superclass::PointType PointType
 
typedef HistogramOfOrientedGradientCovariantImageFunction Self
 
typedef itk::ImageFunction< TInputImage, std::vector< std::vector< TOutputPrecision > >, TCoordRep > Superclass
 

Public Member Functions

virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
OutputType EvaluateAtIndex (const IndexType &index) const override
 
virtual const char * GetNameOfClass () const
 

Static Public Member Functions

static Pointer New ()
 

Static Public Attributes

static const unsigned int ImageDimension = InputImageType::ImageDimension
 
unsigned int m_NeighborhoodRadius
 
unsigned int m_NumberOfOrientationBins
 
OutputType Evaluate (const PointType &point) const override
 
OutputType EvaluateAtContinuousIndex (const ContinuousIndexType &cindex) const override
 
virtual void SetNeighborhoodRadius (unsigned int _arg)
 
virtual const unsigned int & GetNeighborhoodRadius () const
 
virtual void SetNumberOfOrientationBins (unsigned int _arg)
 
virtual const unsigned int & GetNumberOfOrientationBins () const
 
 HistogramOfOrientedGradientCovariantImageFunction ()
 
 ~HistogramOfOrientedGradientCovariantImageFunction () override
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
 HistogramOfOrientedGradientCovariantImageFunction (const Self &)=delete
 
void operator= (const Self &)=delete
 

Detailed Description

template<class TInputImage, class TOutputPrecision = double, class TCoordRep = double>
class otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >

Calculate the centered HOG features.

This filter implements the centered histogram of gradient feature. It expects a gradient covariant image as input, such as the output of the itk::GradientImageFilter. Steps of the algorithm are as follows.

In order to make the C-HOG descriptor rotation-invariant, a principal gradient orientation is first looked for. Within the m_NeighborhoodRadius ($r$), an histogram of the local orientation is computed with m_NumberOfOrientationBins bins. Values cumulated in this histogram are the gradient magnitude weighted by a gaussian kernel of $\sigma = 0.5 * r$.

From this orientation histogram, the principal orientation is computed by looking for the maximum valued bin.

Once principal orientation is computed, gradient magnitude values weighted by the gaussian kernel are cumulated in five different histograms corresponding to five distinct spatial areas : the center area (radius of the center area is computed using $r_{c}=log_{2}(r)$), and the upper-left, upper-right, lower-left and lower-right radial areas. Orientation of these radial areas is shifted to match the principal orientation, and gradient orientations to determine histogram bins are also compensated with the principal orientation. Last, each histogram is normalized by its $L_2$ norm, ensuring that they all lie in the range $[0, 1]$.

This class is templated over the input image type, the output precision (e.g. float or double) and the coordinate representation type (e.g. float or double).

Definition at line 71 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

Member Typedef Documentation

◆ ConstPointer

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef itk::SmartPointer<const Self> otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::ConstPointer

◆ ContinuousIndexType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef Superclass::ContinuousIndexType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::ContinuousIndexType

◆ CoordRepType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef TCoordRep otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::CoordRepType

◆ IndexType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef Superclass::IndexType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::IndexType

◆ InputImageType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef TInputImage otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::InputImageType

InputImageType typedef support.

Definition at line 85 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ InputPixelType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef InputImageType::PixelType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::InputPixelType

◆ OutputPrecisionType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef TOutputPrecision otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::OutputPrecisionType

◆ OutputType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef Superclass::OutputType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::OutputType

◆ Pointer

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef itk::SmartPointer<Self> otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::Pointer

◆ PointType

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef Superclass::PointType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::PointType

◆ Self

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef HistogramOfOrientedGradientCovariantImageFunction otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::Self

Standard class typedefs.

Definition at line 76 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ Superclass

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
typedef itk::ImageFunction<TInputImage, std::vector<std::vector<TOutputPrecision> >, TCoordRep> otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::Superclass

Constructor & Destructor Documentation

◆ HistogramOfOrientedGradientCovariantImageFunction() [1/2]

template<class TInputImage , class TOutputPrecision , class TCoordRep >
otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::HistogramOfOrientedGradientCovariantImageFunction
protected

Constructor

Definition at line 36 of file otbHistogramOfOrientedGradientCovariantImageFunction.hxx.

◆ ~HistogramOfOrientedGradientCovariantImageFunction()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::~HistogramOfOrientedGradientCovariantImageFunction ( )
inlineoverrideprotected

Evaluate the function at non-integer positions

Definition at line 136 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ HistogramOfOrientedGradientCovariantImageFunction() [2/2]

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::HistogramOfOrientedGradientCovariantImageFunction ( const Self )
privatedelete

Evaluate the function at non-integer positions

Member Function Documentation

◆ CreateAnother()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual::itk::LightObject::Pointer otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::CreateAnother ( void  ) const

◆ Evaluate()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
OutputType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::Evaluate ( const PointType point) const
inlineoverride

Evaluate the function at non-integer positions

Definition at line 106 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ EvaluateAtContinuousIndex()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
OutputType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::EvaluateAtContinuousIndex ( const ContinuousIndexType cindex) const
inlineoverride

Evaluate the function at non-integer positions

Definition at line 112 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ EvaluateAtIndex()

template<class TInputImage , class TOutputPrecision , class TCoordRep >
HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::OutputType otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::EvaluateAtIndex ( const IndexType index) const
override

Evalulate the function at specified index

Definition at line 50 of file otbHistogramOfOrientedGradientCovariantImageFunction.hxx.

References otb::CONST_2PI, otb::CONST_PI, and otb::CONST_PI_2.

◆ GetNameOfClass()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual const char* otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

◆ GetNeighborhoodRadius()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual const unsigned int& otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::GetNeighborhoodRadius ( ) const
virtual

Evaluate the function at non-integer positions

◆ GetNumberOfOrientationBins()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual const unsigned int& otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::GetNumberOfOrientationBins ( ) const
virtual

Evaluate the function at non-integer positions

◆ New()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
static Pointer otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::New ( )
static

Method for creation through the object factory.

◆ operator=()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
void otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::operator= ( const Self )
privatedelete

Evaluate the function at non-integer positions

◆ PrintSelf()

template<class TInputImage , class TOutputPrecision , class TCoordRep >
void otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
overrideprotected

Evaluate the function at non-integer positions

Definition at line 42 of file otbHistogramOfOrientedGradientCovariantImageFunction.hxx.

◆ SetNeighborhoodRadius()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual void otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::SetNeighborhoodRadius ( unsigned int  _arg)
virtual

Get/Set the radius of the neighborhood over which the statistics are evaluated

◆ SetNumberOfOrientationBins()

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
virtual void otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::SetNumberOfOrientationBins ( unsigned int  _arg)
virtual

Get/Set the number of bins of the orientation histograms

Member Data Documentation

◆ ImageDimension

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
const unsigned int otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::ImageDimension = InputImageType::ImageDimension
static

Dimension of the underlying image.

Definition at line 100 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ m_NeighborhoodRadius

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
unsigned int otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::m_NeighborhoodRadius
private

Evaluate the function at non-integer positions

Definition at line 146 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.

◆ m_NumberOfOrientationBins

template<class TInputImage , class TOutputPrecision = double, class TCoordRep = double>
unsigned int otb::HistogramOfOrientedGradientCovariantImageFunction< TInputImage, TOutputPrecision, TCoordRep >::m_NumberOfOrientationBins
private

Evaluate the function at non-integer positions

Definition at line 149 of file otbHistogramOfOrientedGradientCovariantImageFunction.h.


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