Class ANN_MLP
- Namespace
- OpenCvSharp.ML
- Assembly
- OpenCvSharp.dll
Artificial Neural Networks - Multi-Layer Perceptrons.
public class ANN_MLP : StatModel, IDisposable
- Inheritance
-
ANN_MLP
- Implements
- Inherited Members
Properties
- BackpropMomentumScale
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 value is 0.1.
- BackpropWeightScale
Strength of the weight gradient term. The recommended value is about 0.1. Default value is 0.1.
- RpropDW0
Initial value Delta_0 of update-values Delta_{ij}. Default value is 0.1.
- RpropDWMax
Update-values upper limit Delta_{max}. It must be >1. Default value is 50.
- RpropDWMin
Update-values lower limit Delta_{min}. It must be positive. Default value is FLT_EPSILON.
- RpropDWMinus
Decrease factor eta^-. It must be >1. Default value is 0.5.
- RpropDWPlus
Increase factor eta^+. It must be >1. Default value is 1.2.
- TermCriteria
Termination criteria of the training algorithm.
Methods
- Create()
Creates the empty model.
- GetLayerSizes()
Integer vector specifying the number of neurons in each layer including the input and output layers. The very first element specifies the number of elements in the input layer. The last element - number of elements in the output layer.
- GetTrainMethod()
Returns current training method
- Load(string)
Loads and creates a serialized ANN from a file. Use ANN::save to serialize and store an ANN to disk. Load the ANN from this file again, by calling this function with the path to the file.
- LoadFromString(string)
Loads algorithm from a String.
- SetActivationFunction(ActivationFunctions, double, double)
Initialize the activation function for each neuron. Currently the default and the only fully supported activation function is ANN_MLP::SIGMOID_SYM.
- SetLayerSizes(InputArray)
Integer vector specifying the number of neurons in each layer including the input and output layers. The very first element specifies the number of elements in the input layer. The last element - number of elements in the output layer.Default value is empty Mat.
- SetTrainMethod(TrainingMethods, double, double)
Sets training method and common parameters.