OpenCV  3.4.2
Open Source Computer Vision
Public Member Functions | List of all members
cv::ml::ANN_MLP_ANNEAL Class Referenceabstract

Artificial Neural Networks - Multi-Layer Perceptrons. More...

#include "ml.hpp"

Inheritance diagram for cv::ml::ANN_MLP_ANNEAL:
cv::ml::ANN_MLP cv::ml::StatModel cv::Algorithm

Public Member Functions

virtual double getAnnealCoolingRatio () const =0
 
virtual double getAnnealFinalT () const =0
 
virtual double getAnnealInitialT () const =0
 
virtual int getAnnealItePerStep () const =0
 
virtual void setAnnealCoolingRatio (double val)=0
 
virtual void setAnnealEnergyRNG (const RNG &rng)=0
 Set/initialize anneal RNG. More...
 
virtual void setAnnealFinalT (double val)=0
 
virtual void setAnnealInitialT (double val)=0
 
virtual void setAnnealItePerStep (int val)=0
 
- Public Member Functions inherited from cv::ml::ANN_MLP
double getAnnealCoolingRatio () const
 
double getAnnealFinalT () const
 
double getAnnealInitialT () const
 
int getAnnealItePerStep () const
 
virtual double getBackpropMomentumScale () const =0
 
virtual double getBackpropWeightScale () const =0
 
virtual cv::Mat getLayerSizes () const =0
 
virtual double getRpropDW0 () const =0
 
virtual double getRpropDWMax () const =0
 
virtual double getRpropDWMin () const =0
 
virtual double getRpropDWMinus () const =0
 
virtual double getRpropDWPlus () const =0
 
virtual TermCriteria getTermCriteria () const =0
 
virtual int getTrainMethod () const =0
 
virtual Mat getWeights (int layerIdx) const =0
 
virtual void setActivationFunction (int type, double param1=0, double param2=0)=0
 
void setAnnealCoolingRatio (double val)
 
void setAnnealEnergyRNG (const RNG &rng)
 Set/initialize anneal RNG. More...
 
void setAnnealFinalT (double val)
 
void setAnnealInitialT (double val)
 
void setAnnealItePerStep (int val)
 
virtual void setBackpropMomentumScale (double val)=0
 
virtual void setBackpropWeightScale (double val)=0
 
virtual void setLayerSizes (InputArray _layer_sizes)=0
 
virtual void setRpropDW0 (double val)=0
 
virtual void setRpropDWMax (double val)=0
 
virtual void setRpropDWMin (double val)=0
 
virtual void setRpropDWMinus (double val)=0
 
virtual void setRpropDWPlus (double val)=0
 
virtual void setTermCriteria (TermCriteria val)=0
 
virtual void setTrainMethod (int method, double param1=0, double param2=0)=0
 
- Public Member Functions inherited from cv::ml::StatModel
virtual float calcError (const Ptr< TrainData > &data, bool test, OutputArray resp) const
 Computes error on the training or test dataset. More...
 
virtual bool empty () const CV_OVERRIDE
 Returns true if the Algorithm is empty (e.g. in the very beginning or after unsuccessful read. More...
 
virtual int getVarCount () const =0
 Returns the number of variables in training samples. More...
 
virtual bool isClassifier () const =0
 Returns true if the model is classifier. More...
 
virtual bool isTrained () const =0
 Returns true if the model is trained. More...
 
virtual float predict (InputArray samples, OutputArray results=noArray(), int flags=0) const =0
 Predicts response(s) for the provided sample(s) More...
 
virtual bool train (const Ptr< TrainData > &trainData, int flags=0)
 Trains the statistical model. More...
 
virtual bool train (InputArray samples, int layout, InputArray responses)
 Trains the statistical model. More...
 
- Public Member Functions inherited from cv::Algorithm
 Algorithm ()
 
virtual ~Algorithm ()
 
virtual void clear ()
 Clears the algorithm state. More...
 
virtual String getDefaultName () const
 
virtual void read (const FileNode &fn)
 Reads algorithm parameters from a file storage. More...
 
virtual void save (const String &filename) const
 
virtual void write (FileStorage &fs) const
 Stores algorithm parameters in a file storage. More...
 
void write (const Ptr< FileStorage > &fs, const String &name=String()) const
 simplified API for language bindings This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 

Additional Inherited Members

- Public Types inherited from cv::ml::ANN_MLP
enum  ActivationFunctions {
  IDENTITY = 0,
  SIGMOID_SYM = 1,
  GAUSSIAN = 2,
  RELU = 3,
  LEAKYRELU = 4
}
 
enum  TrainFlags {
  UPDATE_WEIGHTS = 1,
  NO_INPUT_SCALE = 2,
  NO_OUTPUT_SCALE = 4
}
 
enum  TrainingMethods {
  BACKPROP =0,
  RPROP = 1,
  ANNEAL = 2
}
 
- Public Types inherited from cv::ml::StatModel
enum  Flags {
  UPDATE_MODEL = 1,
  RAW_OUTPUT =1,
  COMPRESSED_INPUT =2,
  PREPROCESSED_INPUT =4
}
 
- Static Public Member Functions inherited from cv::ml::ANN_MLP
static Ptr< ANN_MLPcreate ()
 Creates empty model. More...
 
static Ptr< ANN_MLPload (const String &filepath)
 Loads and creates a serialized ANN from a file. More...
 
- Static Public Member Functions inherited from cv::ml::StatModel
template<typename _Tp >
static Ptr< _Tp > train (const Ptr< TrainData > &data, int flags=0)
 Create and train model with default parameters. More...
 
- Static Public Member Functions inherited from cv::Algorithm
template<typename _Tp >
static Ptr< _Tp > load (const String &filename, const String &objname=String())
 Loads algorithm from the file. More...
 
template<typename _Tp >
static Ptr< _Tp > loadFromString (const String &strModel, const String &objname=String())
 Loads algorithm from a String. More...
 
template<typename _Tp >
static Ptr< _Tp > read (const FileNode &fn)
 Reads algorithm from the file node. More...
 
- Protected Member Functions inherited from cv::Algorithm
void writeFormat (FileStorage &fs) const
 

Detailed Description

Artificial Neural Networks - Multi-Layer Perceptrons.

See also
Neural Networks

Member Function Documentation

§ getAnnealCoolingRatio()

virtual double cv::ml::ANN_MLP_ANNEAL::getAnnealCoolingRatio ( ) const
pure virtual
Python:
retval=cv.ml_ANN_MLP_ANNEAL.getAnnealCoolingRatio()

ANNEAL: Update cooling ratio. It must be >0 and less than 1. Default value is 0.95.

See also
setAnnealCoolingRatio

§ getAnnealFinalT()

virtual double cv::ml::ANN_MLP_ANNEAL::getAnnealFinalT ( ) const
pure virtual
Python:
retval=cv.ml_ANN_MLP_ANNEAL.getAnnealFinalT()

ANNEAL: Update final temperature. It must be >=0 and less than initialT. Default value is 0.1.

See also
setAnnealFinalT

§ getAnnealInitialT()

virtual double cv::ml::ANN_MLP_ANNEAL::getAnnealInitialT ( ) const
pure virtual
Python:
retval=cv.ml_ANN_MLP_ANNEAL.getAnnealInitialT()

§ getAnnealItePerStep()

virtual int cv::ml::ANN_MLP_ANNEAL::getAnnealItePerStep ( ) const
pure virtual
Python:
retval=cv.ml_ANN_MLP_ANNEAL.getAnnealItePerStep()

ANNEAL: Update iteration per step. It must be >0 . Default value is 10.

See also
setAnnealItePerStep

§ setAnnealCoolingRatio()

virtual void cv::ml::ANN_MLP_ANNEAL::setAnnealCoolingRatio ( double  val)
pure virtual
Python:
None=cv.ml_ANN_MLP_ANNEAL.setAnnealCoolingRatio(val)

§ setAnnealEnergyRNG()

virtual void cv::ml::ANN_MLP_ANNEAL::setAnnealEnergyRNG ( const RNG rng)
pure virtual

Set/initialize anneal RNG.

§ setAnnealFinalT()

virtual void cv::ml::ANN_MLP_ANNEAL::setAnnealFinalT ( double  val)
pure virtual
Python:
None=cv.ml_ANN_MLP_ANNEAL.setAnnealFinalT(val)

See also
getAnnealFinalT

§ setAnnealInitialT()

virtual void cv::ml::ANN_MLP_ANNEAL::setAnnealInitialT ( double  val)
pure virtual
Python:
None=cv.ml_ANN_MLP_ANNEAL.setAnnealInitialT(val)

§ setAnnealItePerStep()

virtual void cv::ml::ANN_MLP_ANNEAL::setAnnealItePerStep ( int  val)
pure virtual
Python:
None=cv.ml_ANN_MLP_ANNEAL.setAnnealItePerStep(val)

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