Main Page   Compound List   File List   Compound Members  

PerceptronNeuron Class Reference

#include <PerceptronNeuron.h>

List of all members.

Public Member Functions

 PerceptronNeuron (unsigned int in_layer_num)
double getDelta (void)
void setDelta (double newval)
double getTheta (void)
void setTheta (double newval)
double getThetaDiff (void)
void initializeWeightings (unsigned int succ_count)
void resetWeights (void)
void resetWeightDiffs (void)
void resetDiffs (void)
void postprocessWeight (PerceptronNeuron *succ, double epsilon, double weight_decay, double momterm)
void postprocessTheta (double epsilon, double weight_decay, double momterm)
void update (void)

Public Attributes

unsigned int num
double input
double output
vector< double > weight
vector< double > weight_diff

Protected Attributes

double delta
double theta
double theta_diff
double theta_diff_last
vector< double > weight_diff_last


Detailed Description

Represent one neuron within a layer of the neural network.


Constructor & Destructor Documentation

PerceptronNeuron::PerceptronNeuron (  unsigned int    in_layer_num ) 
 

Main constructor.

Parameters:
in_layer_num number of neuron within its layer.


Member Function Documentation

double PerceptronNeuron::getDelta (  void    )  [inline]
 

Getter function for the delta variable.

double PerceptronNeuron::getTheta (  void    )  [inline]
 

Getter function for theta parameter.

double PerceptronNeuron::getThetaDiff (  void    )  [inline]
 

Getter for the difference calculated for the theta parameter.

void PerceptronNeuron::initializeWeightings (  unsigned int    succ_count ) 
 

Initialize the weightings vectors used for each neuron to zero.

Parameters:
succ_count number of successor neurons to this neuron.

void PerceptronNeuron::postprocessTheta (  double    epsilon,
double    weight_decay,
double    momterm
) 
 

Theta postprocess algorithm. Assign the theta differences to this neuron.

Parameters:
epsilon Learning parameter.
weight_decay Weight decay factor.
momterm Momentum term factor.

void PerceptronNeuron::postprocessWeight (  PerceptronNeuron *    succ,
double    epsilon,
double    weight_decay,
double    momterm
) 
 

Weighting postprocess algorithm. Assign the weight differences to this neuron. Note that the assignment is done by adding the new delta value to the current one. Hence, both batch- and online learning can use this function. For online-learning the values must be resetted after each update using the resetWeightDiffs method. Also, only one weighting difference is calculated at a time. The computation of all differences is scheduled by PerceptronLayer::postprocess.

Parameters:
succ Successor neuron to the current neuron.
epsilon Learning parameter.
weight_decay Weight decay factor.
momterm Momentum term factor.
See also:
resetWeightDiffs ()

void PerceptronNeuron::resetDiffs (  void    ) 
 

Reset all learned differences.

void PerceptronNeuron::resetWeightDiffs (  void    ) 
 

Reset all weight deltas to zero.

void PerceptronNeuron::resetWeights (  void    ) 
 

Reset all weightings to zero.

void PerceptronNeuron::setDelta (  double    newval )  [inline]
 

Setter function for the delta variable.

Parameters:
newval New value to be assigned to delta.

void PerceptronNeuron::setTheta (  double    newval )  [inline]
 

Setter function for theta parameter.

void PerceptronNeuron::update (  void    ) 
 

Update algorithm. Update weightings and theta parameter by the values calculated in the postprocess step.


Member Data Documentation

double PerceptronNeuron::delta [protected]
 

Errorsignal, computed by the backpropagation algorithm. Used to compute the deltas for both the weightings and the sensitivity parameter

double PerceptronNeuron::input
 

Input signal level for this node, .

unsigned int PerceptronNeuron::num
 

Counter within the current layer (top = 0)

double PerceptronNeuron::output
 

Output signal level for this node, .

double PerceptronNeuron::theta [protected]
 

Sensitivity parameter to the activation function

double PerceptronNeuron::theta_diff [protected]
 

Delta-value for the sensitivity, calculated by the Processing algorithm, used to update theta within the Update algorithm

double PerceptronNeuron::theta_diff_last [protected]
 

The previous theta difference, used for momentum term calculation.

vector<double> PerceptronNeuron::weight
 

Weightings to neurons in the next layer. Hence, the size of the vector must equal the number of neurons in the next layer

vector<double> PerceptronNeuron::weight_diff
 

Delta-value for the individual weightings the node has to its successor nodes. Computed by the Processing algorithm

Note this is within the public space due to the from-file constructor of PerceptronNetwork, which push_back's zeroes here.

vector<double> PerceptronNeuron::weight_diff_last [protected]
 

The previous weight differences, used for momentum term.


The documentation for this class was generated from the following files:
Generated on Sun Mar 2 21:35:50 2003 for libperceptronnetwork by doxygen1.3-rc3