SetMjuEx(newMju: Double; layerIndex: Integer);
SetMjuEx(newMju: double; layerIndex: integer);
newMju. Coefficient of inertia. The value is within the range of [0.0; 1.0].
layerIndex. Layer index.
The SetMjuEx method sets coefficient of inertia of learning for the specified layer of the back-propagation network.
For details about inertia see INeuralNetwork.SetMju.
Indexation of the network layers is continuous and starts with zero.
As an example, a function is given, which input has back-propagation network fed into (the Net parameter). To execute the example, add a link to the NN system assembly.
Function m_SetMjuNju(Net: NeuralNetwork): NeuralNetwork;
Var
i: Integer;
Begin
For i := 0 To Net.GetNumberOfLayers - 1 Do
Net.SetNjuEx(0.15, i);
Net.SetMjuEx(0.01, i);
End For;
Return Net;
End Function m_SetMjuNju;
After executing the example for all the layers of the network there is a unified coefficient of inertia assigned as well as unified learning rate.
As an example, a function is given, which input has back-propagation network fed into (the Net parameter).
Imports Prognoz.Platform.Interop.NN;
…
Public Shared Function m_SetMjuNju(Net: NeuralNetwork): NeuralNetwork;
Var
i: Integer;
Begin
For i := 0 To Net.GetNumberOfLayers() - 1 Do
Net.SetNjuEx(0.15, i);
Net.SetMjuEx(0.01, i);
End For;
Return Net;
End Function;
After executing the example a unified coefficient of inertia as well as unified learning rate are assigned for network layers.
See also: