OTB  6.7.0
Orfeo Toolbox
Public Types | Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | List of all members
otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue > Class Template Reference

#include <otbNeuralNetworkMachineLearningModel.h>

+ Inheritance diagram for otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >:
+ Collaboration diagram for otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >:

Public Types

typedef
Superclass::ConfidenceValueType 
ConfidenceValueType
 
typedef itk::SmartPointer
< const Self
ConstPointer
 
typedef
Superclass::InputListSampleType 
InputListSampleType
 
typedef Superclass::InputSampleType InputSampleType
 
typedef Superclass::InputValueType InputValueType
 
typedef std::map
< TargetValueType, unsigned
int > 
MapOfLabelsType
 
typedef itk::SmartPointer< SelfPointer
 
typedef Superclass::ProbaSampleType ProbaSampleType
 
typedef
NeuralNetworkMachineLearningModel 
Self
 
typedef MachineLearningModel
< TInputValue, TTargetValue > 
Superclass
 
typedef
Superclass::TargetListSampleType 
TargetListSampleType
 
typedef
Superclass::TargetSampleType 
TargetSampleType
 
typedef Superclass::TargetValueType TargetValueType
 
- Public Types inherited from otb::MachineLearningModel< TInputValue, TTargetValue >
typedef MachineLearningModel Self
 
typedef itk::Object Superclass
 
typedef itk::SmartPointer< SelfPointer
 
typedef itk::SmartPointer
< const Self
ConstPointer
 
typedef MLMSampleTraits
< TInputValue >::ValueType 
InputValueType
 
typedef MLMSampleTraits
< TInputValue >::SampleType 
InputSampleType
 
typedef
itk::Statistics::ListSample
< InputSampleType
InputListSampleType
 
typedef MLMTargetTraits
< TTargetValue >::ValueType 
TargetValueType
 
typedef MLMTargetTraits
< TTargetValue >::SampleType 
TargetSampleType
 
typedef
itk::Statistics::ListSample
< TargetSampleType
TargetListSampleType
 
typedef MLMTargetTraits
< double >::ValueType 
ConfidenceValueType
 
typedef MLMTargetTraits
< double >::SampleType 
ConfidenceSampleType
 
typedef
itk::Statistics::ListSample
< ConfidenceSampleType
ConfidenceListSampleType
 
typedef
itk::VariableLengthVector
< double > 
ProbaSampleType
 
typedef
itk::Statistics::ListSample
< ProbaSampleType
ProbaListSampleType
 
- Public Types inherited from itk::Object
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef Object Self
 
typedef LightObject Superclass
 
- Public Types inherited from itk::LightObject
typedef SmartPointer< const SelfConstPointer
 
typedef SmartPointer< SelfPointer
 
typedef LightObject Self
 

Public Member Functions

void Load (const std::string &filename, const std::string &name="") override
 
void Save (const std::string &filename, const std::string &name="") override
 
void SetLayerSizes (const std::vector< unsigned int > layers)
 
virtual int GetTrainMethod ()
 
virtual void SetTrainMethod (int _arg)
 
virtual int GetActivateFunction ()
 
virtual void SetActivateFunction (int _arg)
 
virtual double GetAlpha ()
 
virtual void SetAlpha (double _arg)
 
virtual double GetBeta ()
 
virtual void SetBeta (double _arg)
 
virtual double GetBackPropDWScale ()
 
virtual void SetBackPropDWScale (double _arg)
 
virtual double GetBackPropMomentScale ()
 
virtual void SetBackPropMomentScale (double _arg)
 
virtual double GetRegPropDW0 ()
 
virtual void SetRegPropDW0 (double _arg)
 
virtual double GetRegPropDWMin ()
 
virtual void SetRegPropDWMin (double _arg)
 
virtual int GetTermCriteriaType ()
 
virtual void SetTermCriteriaType (int _arg)
 
virtual int GetMaxIter ()
 
virtual void SetMaxIter (int _arg)
 
virtual double GetEpsilon ()
 
virtual void SetEpsilon (double _arg)
 
Classification model file compatibility tests
bool CanReadFile (const std::string &) override
 
bool CanWriteFile (const std::string &) override
 
- Public Member Functions inherited from otb::MachineLearningModel< TInputValue, TTargetValue >
bool HasConfidenceIndex () const
 
bool HasProbaIndex () const
 
 itkGetObjectMacro (ConfidenceListSample, ConfidenceListSampleType)
 
TargetSampleType Predict (const InputSampleType &input, ConfidenceValueType *quality=nullptr, ProbaSampleType *proba=nullptr) const
 
TargetListSampleType::Pointer PredictBatch (const InputListSampleType *input, ConfidenceListSampleType *quality=nullptr, ProbaListSampleType *proba=nullptr) const
 
virtual void SetDimension (unsigned int _arg)
 
virtual unsigned int GetDimension ()
 
virtual void SetInputListSample (InputListSampleType *_arg)
 
 itkGetObjectMacro (InputListSample, InputListSampleType)
 
virtual const InputListSampleTypeGetInputListSample () const
 
 itkGetObjectMacro (TargetListSample, TargetListSampleType)
 
virtual void SetTargetListSample (TargetListSampleType *_arg)
 
virtual bool GetRegressionMode ()
 
void SetRegressionMode (bool flag)
 
- Public Member Functions inherited from itk::Object
unsigned long AddObserver (const EventObject &event, Command *)
 
unsigned long AddObserver (const EventObject &event, Command *) const
 
virtual void DebugOff () const
 
virtual void DebugOn () const
 
CommandGetCommand (unsigned long tag)
 
bool GetDebug () const
 
const MetaDataDictionaryGetMetaDataDictionary () const
 
MetaDataDictionaryGetMetaDataDictionary ()
 
virtual ModifiedTimeType GetMTime () const
 
virtual const std::string & GetObjectName () const
 
virtual const TimeStampGetTimeStamp () const
 
bool HasObserver (const EventObject &event) const
 
void InvokeEvent (const EventObject &)
 
void InvokeEvent (const EventObject &) const
 
virtual void Modified () const
 
virtual void Register () const override
 
void RemoveAllObservers ()
 
void RemoveObserver (unsigned long tag)
 
void SetDebug (bool debugFlag) const
 
void SetMetaDataDictionary (const MetaDataDictionary &rhs)
 
virtual void SetObjectName (std::string _arg)
 
virtual void SetReferenceCount (int) override
 
virtual void UnRegister () const noexceptoverride
 
- Public Member Functions inherited from itk::LightObject
virtual void Delete ()
 
virtual int GetReferenceCount () const
 
 itkCloneMacro (Self)
 
void Print (std::ostream &os, Indent indent=0) const
 

Protected Member Functions

TargetSampleType DoPredict (const InputSampleType &input, ConfidenceValueType *quality=nullptr, ProbaSampleType *proba=nullptr) const override
 
 NeuralNetworkMachineLearningModel ()
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
 ~NeuralNetworkMachineLearningModel () override
 
- Protected Member Functions inherited from otb::MachineLearningModel< TInputValue, TTargetValue >
 MachineLearningModel ()
 
void PrintSelf (std::ostream &os, itk::Indent indent) const override
 
 ~MachineLearningModel () override
 
- Protected Member Functions inherited from itk::Object
 Object ()
 
bool PrintObservers (std::ostream &os, Indent indent) const
 
virtual void SetTimeStamp (const TimeStamp &time)
 
virtual ~Object ()
 
- Protected Member Functions inherited from itk::LightObject
virtual LightObject::Pointer InternalClone () const
 
 LightObject ()
 
virtual void PrintHeader (std::ostream &os, Indent indent) const
 
virtual void PrintTrailer (std::ostream &os, Indent indent) const
 
virtual ~LightObject ()
 

Private Member Functions

 NeuralNetworkMachineLearningModel (const Self &)=delete
 
void operator= (const Self &)=delete
 

Private Attributes

int m_ActivateFunction
 
double m_Alpha
 
CvANN_MLP * m_ANNModel
 
double m_BackPropDWScale
 
double m_BackPropMomentScale
 
double m_Beta
 
CvMat * m_CvMatOfLabels
 
double m_Epsilon
 
std::vector< unsigned int > m_LayerSizes
 
MapOfLabelsType m_MapOfLabels
 
int m_MaxIter
 
double m_RegPropDW0
 
double m_RegPropDWMin
 
int m_TermCriteriaType
 
int m_TrainMethod
 
static Pointer New ()
 
virtual ::itk::LightObject::Pointer CreateAnother (void) const
 
virtual const char * GetNameOfClass () const
 
void Train () override
 
void LabelsToMat (const TargetListSampleType *listSample, cv::Mat &output)
 
void CreateNetwork ()
 
void SetupNetworkAndTrain (cv::Mat &labels)
 
CvANN_MLP_TrainParams SetNetworkParameters ()
 

Additional Inherited Members

- Static Public Member Functions inherited from itk::Object
static bool GetGlobalWarningDisplay ()
 
static void GlobalWarningDisplayOff ()
 
static void GlobalWarningDisplayOn ()
 
static Pointer New ()
 
static void SetGlobalWarningDisplay (bool flag)
 
- Static Public Member Functions inherited from itk::LightObject
static void BreakOnError ()
 
static Pointer New ()
 
- Protected Attributes inherited from otb::MachineLearningModel< TInputValue, TTargetValue >
bool m_ConfidenceIndex
 
ConfidenceListSampleType::Pointer m_ConfidenceListSample
 
unsigned int m_Dimension
 
InputListSampleType::Pointer m_InputListSample
 
bool m_IsDoPredictBatchMultiThreaded
 
bool m_IsRegressionSupported
 
bool m_ProbaIndex
 
bool m_RegressionMode
 
TargetListSampleType::Pointer m_TargetListSample
 
InputListSampleType::Pointer m_ValidationListSample
 
- Protected Attributes inherited from itk::LightObject
AtomicInt< int > m_ReferenceCount
 

Detailed Description

template<class TInputValue, class TTargetValue>
class otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >

Definition at line 34 of file otbNeuralNetworkMachineLearningModel.h.

Member Typedef Documentation

template<class TInputValue, class TTargetValue>
typedef Superclass::ConfidenceValueType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::ConfidenceValueType

Definition at line 50 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef itk::SmartPointer<const Self> otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::ConstPointer

Definition at line 42 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::InputListSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::InputListSampleType

Definition at line 46 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::InputSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::InputSampleType

Definition at line 45 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::InputValueType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::InputValueType

Definition at line 44 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef std::map<TargetValueType, unsigned int> otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::MapOfLabelsType

Definition at line 52 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef itk::SmartPointer<Self> otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::Pointer

Definition at line 41 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::ProbaSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::ProbaSampleType

Definition at line 51 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef NeuralNetworkMachineLearningModel otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::Self

Standard class typedefs.

Definition at line 39 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef MachineLearningModel<TInputValue, TTargetValue> otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::Superclass

Definition at line 40 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::TargetListSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::TargetListSampleType

Definition at line 49 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::TargetSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::TargetSampleType

Definition at line 48 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
typedef Superclass::TargetValueType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::TargetValueType

Definition at line 47 of file otbNeuralNetworkMachineLearningModel.h.

Constructor & Destructor Documentation

template<class TInputValue , class TOutputValue >
otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::NeuralNetworkMachineLearningModel ( )
protected
template<class TInputValue , class TOutputValue >
otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::~NeuralNetworkMachineLearningModel ( )
overrideprotected

Destructor

Definition at line 57 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::NeuralNetworkMachineLearningModel ( const Self )
privatedelete

Member Function Documentation

template<class TInputValue , class TOutputValue >
bool otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::CanReadFile ( const std::string &  file)
overridevirtual

Is the input model file readable and compatible with the corresponding classifier ?

Implements otb::MachineLearningModel< TInputValue, TTargetValue >.

Definition at line 369 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue , class TOutputValue >
bool otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::CanWriteFile ( const std::string &  )
overridevirtual

Is the input model file writable and compatible with the corresponding classifier ?

Implements otb::MachineLearningModel< TInputValue, TTargetValue >.

Definition at line 400 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
virtual::itk::LightObject::Pointer otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::CreateAnother ( void  ) const
virtual

Run-time type information (and related methods).

Reimplemented from itk::Object.

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::CreateNetwork ( )
private

Train the machine learning model

Train the machine learning model for classification

Definition at line 149 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue , class TOutputValue >
NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::TargetSampleType otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::DoPredict ( const InputSampleType input,
ConfidenceValueType quality = nullptr,
ProbaSampleType proba = nullptr 
) const
overrideprotected

Predict values using the model

Definition at line 239 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
virtual int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetActivateFunction ( )
virtual

Setters/Getters to the neuron activation function 3 methods are available:

template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetAlpha ( )
virtual

Setters/Getters to the alpha parameter of the activation function Default is 0.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetBackPropDWScale ( )
virtual

Strength of the weight gradient term in the BACKPROP method. The recommended value is about 0.1 Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetBackPropMomentScale ( )
virtual

Strength of the momentum term (the difference between weights on the 2 previous iterations). This parameter provides some inertia to smooth the random fluctuations of the weights. It can vary from 0 (the feature is disabled) to 1 and beyond. The value 0.1 or so is good enough Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetBeta ( )
virtual

Setters/Getters to the beta parameter of the activation function Default is 0.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetEpsilon ( )
virtual

Epsilon value used in the Termination criteria. default is 0.01

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetMaxIter ( )
virtual

Maximum number of iteration used in the Termination criteria. default is 1000

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual const char* otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetNameOfClass ( ) const
virtual

Run-time type information (and related methods).

Reimplemented from otb::MachineLearningModel< TInputValue, TTargetValue >.

template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetRegPropDW0 ( )
virtual

Initial value $ \Delta_0 $ of update-values $ \Delta_{ij} $ in RPROP method. Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetRegPropDWMin ( )
virtual

Update-values lower limit $ \Delta_{min} $ in RPROP method. It must be positive. Default is FLT_EPSILON

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetTermCriteriaType ( )
virtual

Termination criteria. It can be CV_TERMCRIT_ITER or CV_TERMCRIT_EPS or CV_TERMCRIT_ITER+CV_TERMCRIT_EPS default is CV_TERMCRIT_ITER+CV_TERMCRIT_EPS.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::GetTrainMethod ( )
virtual

Setters/Getters to the train method 2 methods are available:

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::LabelsToMat ( const TargetListSampleType labels,
cv::Mat &  output 
)
protected

Converts a ListSample of VariableLengthVector to a CvMat. The user is responsible for freeing the output pointer with the cvReleaseMat function. A null pointer is resturned in case the conversion failed.

Definition at line 82 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::Load ( const std::string &  filename,
const std::string &  name = "" 
)
overridevirtual

Load the model from file

Implements otb::MachineLearningModel< TInputValue, TTargetValue >.

Definition at line 329 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
static Pointer otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::New ( )
static

Run-time type information (and related methods).

template<class TInputValue, class TTargetValue>
void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::operator= ( const Self )
privatedelete
template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::PrintSelf ( std::ostream &  os,
itk::Indent  indent 
) const
overrideprotectedvirtual

PrintSelf method

Reimplemented from itk::Object.

Definition at line 406 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::Save ( const std::string &  filename,
const std::string &  name = "" 
)
overridevirtual

Save the model to file

Implements otb::MachineLearningModel< TInputValue, TTargetValue >.

Definition at line 294 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetActivateFunction ( int  _arg)
virtual

Setters/Getters to the neuron activation function 3 methods are available:

template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetAlpha ( double  _arg)
virtual

Setters/Getters to the alpha parameter of the activation function Default is 0.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetBackPropDWScale ( double  _arg)
virtual

Strength of the weight gradient term in the BACKPROP method. The recommended value is about 0.1 Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetBackPropMomentScale ( double  _arg)
virtual

Strength of the momentum term (the difference between weights on the 2 previous iterations). This parameter provides some inertia to smooth the random fluctuations of the weights. It can vary from 0 (the feature is disabled) to 1 and beyond. The value 0.1 or so is good enough Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetBeta ( double  _arg)
virtual

Setters/Getters to the beta parameter of the activation function Default is 0.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetEpsilon ( double  _arg)
virtual

Epsilon value used in the Termination criteria. default is 0.01

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::SetLayerSizes ( const std::vector< unsigned int >  layers)

Set the number of neurons in each layer (including input and output layers). The number of neuron in the first layer (input layer) must be equal to the number of samples in the InputListSample

Sets the topology of the NN

Definition at line 67 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetMaxIter ( int  _arg)
virtual

Maximum number of iteration used in the Termination criteria. default is 1000

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue , class TOutputValue >
CvANN_MLP_TrainParams otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::SetNetworkParameters ( )
private

Train the machine learning model

Train the machine learning model for classification

Definition at line 173 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetRegPropDW0 ( double  _arg)
virtual

Initial value $ \Delta_0 $ of update-values $ \Delta_{ij} $ in RPROP method. Default is 0.1

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetRegPropDWMin ( double  _arg)
virtual

Update-values lower limit $ \Delta_{min} $ in RPROP method. It must be positive. Default is FLT_EPSILON

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetTermCriteriaType ( int  _arg)
virtual

Termination criteria. It can be CV_TERMCRIT_ITER or CV_TERMCRIT_EPS or CV_TERMCRIT_ITER+CV_TERMCRIT_EPS default is CV_TERMCRIT_ITER+CV_TERMCRIT_EPS.

See Also
http://docs.opencv.org/modules/ml/doc/neural_networks.html
template<class TInputValue, class TTargetValue>
virtual void otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::SetTrainMethod ( int  _arg)
virtual

Setters/Getters to the train method 2 methods are available:

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::SetupNetworkAndTrain ( cv::Mat &  labels)
private

Train the machine learning model

Train the machine learning model for classification

Definition at line 188 of file otbNeuralNetworkMachineLearningModel.hxx.

template<class TInputValue , class TOutputValue >
void otb::NeuralNetworkMachineLearningModel< TInputValue, TOutputValue >::Train ( )
overridevirtual

Train the machine learning model

Train the machine learning model for classification

Implements otb::MachineLearningModel< TInputValue, TTargetValue >.

Definition at line 219 of file otbNeuralNetworkMachineLearningModel.hxx.

Member Data Documentation

template<class TInputValue, class TTargetValue>
int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_ActivateFunction
private

Definition at line 214 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_Alpha
private

Definition at line 216 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
CvANN_MLP* otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_ANNModel
private

Definition at line 211 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_BackPropDWScale
private

Definition at line 218 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_BackPropMomentScale
private

Definition at line 219 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_Beta
private

Definition at line 217 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
CvMat* otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_CvMatOfLabels
private

Definition at line 226 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_Epsilon
private

Definition at line 224 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
std::vector<unsigned int> otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_LayerSizes
private

Definition at line 215 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
MapOfLabelsType otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_MapOfLabels
private

Definition at line 227 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_MaxIter
private

Definition at line 223 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_RegPropDW0
private

Definition at line 220 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
double otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_RegPropDWMin
private

Definition at line 221 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_TermCriteriaType
private

Definition at line 222 of file otbNeuralNetworkMachineLearningModel.h.

template<class TInputValue, class TTargetValue>
int otb::NeuralNetworkMachineLearningModel< TInputValue, TTargetValue >::m_TrainMethod
private

Definition at line 213 of file otbNeuralNetworkMachineLearningModel.h.


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