Neural Network Toolbox
  Go to function:
    Search    Help Desk 
learncon    Examples   See Also

Conscience bias learning function

Syntax

[dB,LS] = learncon(B,P,Z,N,A,T,E,gW,gA,D,LP,LS)

info = learncon(code)

Description

learncon is the conscience bias learning function used to increase the net input to neurons which have the lowest average output until each neuron responds roughly an equal percentage of the time.

learncon(B,P,Z,N,A,T,E,gW,gA,D,LP,LS) takes several inputs,

and returns

Learning occurs according to learncon's learning parameter, shown here with its default value.

learncon(code) returns useful information for each code string,

NNT 2.0 compatibility: The LP.lr described above equals 1 minus the bias time constant used by trainc in NNT 2.0.

Examples

Here we define a random output A, and bias vector W for a layer with 3 neurons. We also define the learning rate LR.

Since learncon only needs these values to calculate a bias change (see algorithim below), we will use them to do so.

Network Use

To prepare the bias of layer i of a custom network to learn with learncon:

   1.
Set net.trainFcn to 'trainwb1'. (net.trainParam will automatically become adaptwb's default parameters.)
   2.
Set net.adaptFcn to 'adaptwb'. (net.adaptParam will automatically become adaptwb's default parameters.)
   3.
Set net.inputWeights{i}.learnFcn to 'learncon'. Set each net.layerWeights{i,j}.learnFcn to 'learncon'. (Each weight learning parameter property will automatically be set to learncon's default parameters.)
To train the network (or enable it to adapt):

   1.
Set net.trainParam (or net.adaptParam) properties as desired.
   2.
Call train (or adapt).

Algorithm

learncon calculates the bias change db for a given neuron by first updating each neuron's conscience, i.e. the running average of its output:

The conscience is then used to compute a bias for the neuron that is greatest for smaller conscience values.

(Note that learncon is able to recover C each time it is called from the bias values.)

See Also

learnk, learnos, adaptwb, trainwb, adapt, train



[ Previous | Help Desk | Next ]