NAME

AI::NeuralNet::Kohonen::Node - a node for AI::NeuralNet::Kohonen

DESCRIPTION

Implimentation of a node in a SOM - see AI::NeuralNet::Kohonen.

CONSTRUCTOR (new)

dim

The number of dimensions of this node's weights. Do not supply if you are supplying weight.

weight

Optional: a reference to an array containing the weight for this node. Supplying this allows the constructor to work out dim, above.

METHOD distance_from

Find the distance of this node from the target.

Accepts: the target vector as an array reference.

Returns: the distance.

               __________________
              / i=n            2
Distance  =  /   E  ( V  -  W )
           \/   i=0    i     i

Where V is the current input vector, and W is this node's weight vector.

METHOD distance_effect

Calculates the effect on learning of distance from a given point (intended to be the BMU).

Accepts: the distance of this node from the given point; the radius of the neighbourhood of affect around the given point.

Returns:

               (            2  )
               (    distance   )
THETA(t) = exp ( - ----------- )
               (          2    )
               (   2 sigma (t) )

Where distance is the distance of the node from the BMU (that is, $bmu->[0] in the method's paramter), and sigma is the width of the neighbourhood as calculated above (see "FINDING THE NEIGHBOURS OF THE BMU"). THETA also decays over time.

The time t is always that of the calling object.

AUTHOR AND COYRIGHT

This implimentation Copyright (C) Lee Goddard, 2003. All Rights Reserved.

Available under the same terms as Perl itself.