7.3 Train with FindMinimum
If you prefer, you can use the built-in Mathematica command FindMinimum to train FF, RBF, and dynamic networks. This is done by giving the option MethodFindMinimum to NeuralFit. The other choices for Method call algorithms especially written for neural network minimization and thus happen to be superior to FindMinimum in most neural network problems.
You can submit any FindMinimum options by putting them in a list and using the option ToFindMinimum.
See the documentation on FindMinimum for further details.
Consider the following small example.
Read in the Neural Networks package and a standard add-on package.
Generate data and look at the function.
Initialize an RBF network randomly.
Train with FindMinimum and specify that the Levenberg-Marquardt algorithm of FindMinimum should be used.
A main disadvantage with FindMinimum is that it is hard to say whether or not the training was in fact successful. You have no intermediate results during training, and no criterion plot given at the end of the training. You almost always get the warning at the end of the training that the minimum was not reached. However, the trained network might be a good description of the data anyway. You can visually inspect the model with a plot.
Plot the approximation obtained with the network.
You can repeat the example changing the number of iterations and the algorithm used in FindMinimum.