Backpropagation neural network with optional momentum and adaptive learn rate. More...
#include <NeuralNetwork.h>
Public Member Functions | |
Network (int inlen, int len1, int len2, int outlen) | |
Network (int id, Connection &conn) | |
Network (const Network &net) | |
void | Write (Connection &conn) |
double | CalcError (const Array< double > &input, const Array< double > &output) |
double | Train (const Array< double > &input, const Array< double > &output, double dErrTarget, int maxCycles) |
void | Activate (const Array< double > &input, Array< double > &output) |
int | NetworkId () const |
int | InputCount () const |
int | Layer1Count () const |
int | Layer2Count () const |
int | OutputCount () const |
void | ResetID () |
Network & | operator= (const Network &net) |
void | ValidateMem () const |
void | CheckMem () const |
Protected Member Functions | |
void | Init () |
void | ActivateLayer (Array< double > &layer1, Array< double > &layer2, Array< double > &wt) |
layer1 is "behind" layer 2. If layer1 is Input, then layer2 is hidden layer 1. | |
void | Activate () |
Protected Attributes | |
int | m_networkId |
double | m_learnRate |
double | m_momentum |
double | m_wtRange |
bool | m_useAdaptiveLR |
bool | m_useAdaptiveMom |
double | m_previousError |
Array< double > | m_input |
Array< double > | m_output |
Backpropagation neural network with optional momentum and adaptive learn rate.
Definition at line 49 of file NeuralNetwork.h.
Network::Network | ( | int | inlen, | |
int | len1, | |||
int | len2, | |||
int | outlen | |||
) |
Normal init
Definition at line 142 of file BackPropNeuralNetwork.cpp.
Network::Network | ( | int | id, | |
Connection & | conn | |||
) |
Datebase load
Definition at line 185 of file BackPropNeuralNetwork.cpp.
void Network::ActivateLayer | ( | Array< double > & | layer1, | |
Array< double > & | layer2, | |||
Array< double > & | wt | |||
) | [protected] |
layer1 is "behind" layer 2. If layer1 is Input, then layer2 is hidden layer 1.
Definition at line 344 of file BackPropNeuralNetwork.cpp.