Neural Network Toolbox Previous page   Next Page
traingda

Gradient descent with adaptive learning rate backpropagation

Syntax

[net,TR,Ac,El] = traingda(net,Pd,Tl,Ai,Q,TS,VV,TV)

info = traingda(code)

Description

traingda is a network training function that updates weight and bias values according to gradient descent with adaptive learning rate.

traingda(net,Pd,Tl,Ai,Q,TS,VV) takes these inputs,

and returns,

Training occurs according to the traingda's training parameters, shown here with their default values:

Dimensions for these variables are

where

If VV or TV is not [], it must be a structure of validation vectors,

Validation vectors are used to stop training early if the network performance on the validation vectors fails to improve or remains the same for max_fail epochs in a row. Test vectors are used as a further check that the network is generalizing well, but do not have any effect on training.

traingda(code) returns useful information for each code string:

Network Use

You can create a standard network that uses traingda with newff, newcf, or newelm.

To prepare a custom network to be trained with traingda

  1. Set net.trainFcn to 'traingda'. This will set net.trainParam to traingda's default parameters.
  2. Set net.trainParam properties to desired values.

In either case, calling train with the resulting network will train the network with traingda.

See newff, newcf, and newelm for examples.

Algorithm

traingda can train any network as long as its weight, net input, and transfer functions have derivative functions.

Backpropagation is used to calculate derivatives of performance dperf with respect to the weight and bias variables X. Each variable is adjusted according to gradient descent:

At each epoch, if performance decreases toward the goal, then the learning rate is increased by the factor lr_inc. If performance increases by more than the factor max_perf_inc, the learning rate is adjusted by the factor lr_dec and the change, which increased the performance, is not made.

Training stops when any of these conditions occur:

See Also

newff, newcf, traingd, traingdm, traingdx, trainlm


Previous page  traingd traingdm Next page

© 1994-2005 The MathWorks, Inc.