NN.MDB
The Database that thinks
© 2007 Ben Margolis
How to Use NN.MDB
The Neural Workbench form contains all the controls needed to create
an MLP,
link it to a datasource, train, test, run and evaluate it.
MLP Name & Architecture
MLP Name: A
reference name for this NN. Just for user convenience. Each NN is also
assigned a unique autonumber for internal reference.
MLP Architecture. Enter the number of Input Neurons, Hidden
Neurons and Output Neurons. The system calculates the number of
synaptic connections. Click "Gernerate" to create the MLP as entered.
You will see the NN appear in the Neural Network Diagram Window.
If you want to change the MLP design, click "Delete,"
change the parameters and click "Generate " again. To retrain the MLP
without changing the design, click "Randomize"
Backup and Restore are NYI. PrepNN
is only required with shared neurons. (Click here for more about shared
neurons in version 2.)
Version 2 supports Serial Memory, which enables the
NN to remember data from one activation to the next. This will, for
instance, allow your NN read data stored in a "one day per row" table to
evaluate it on a "last five days" basis. Check the box for Serial Memory
and enter the number of Events. This will create one "memory
neuron" for each event, for each input neuron. At runtime, system
automatically passes the values of the inputs down this "memory chain."
|
Data
Sources
Simply enter
the names of any MS Access tables or queries in the current MDB file. These
can be tables in linked files, or SQL or ODBC data sources.
FactData refers to the Training Set and is
opened for read only access. Its a good idea to use a Select Query and a
random sort.
TestData (the Verification Set) and
RunData (the runtime data source) must be updatable. The system will
write data to those tables at runtime.
Click Map I/O Fields to open a subwindow
displaying the current NN's layer one and layer three neurons to allow you
to enter field names to map those neurons to specific columns in the tables
entered above. Current version expects all I/O data to be within the range
{-1...+1}. Automatic scaling is NYI.
Note: If you Delete and re-Generate the NN you
must remap I/O neurons. |
Training
Once your NN has
been Generated and you have entered a FactData source and Mapped I/O Fields,
you are ready to begin training.
Enter a Learning Rate (that is >0 and <1), and
a Tolerance, which can be anything you want based on the fact that
the expected output going to be within the range {-1...+1}. Enter one or
more Stop On parameters. (If you don't, the system will run for exactly one
full epoch.) Click TRAIN to begin.
Note: The Break Button was designed to stop
training immediately. However, I noticed that checking for this condition
slowed down training, so it has been temporarily disabled. |
MLP Education
Just the total
number of training facts run through this NN, how many were good, how many
bad and mean squared error. Watch this window during training you should see
number of Good Facts going up and the MSE going down. If not, you (or I)
have done something wrong. |
NN Training History
I got tired of trying to remember "Did I try twenty-five
neurons on the hidden layer yet?" and "Which was the best Learning Rate .5
or .4?" So I added the memo field called Training History. Every
significant event the "life" of a particular NN is automatically recorded in
reverse chronological order. Beginning and ending training, when the
NN was built and rebuilt etc. You can also manually type any notes you wish
in this field. |
Neural Network Diagram
This was fun. I implemented
Steve Lebans excellent VBA Picturebox
control to draw a diagram of the NN.
The thickness of the lines indicate the weights, lighter color is positive,
darker is negative.
Click on any neuron to get a... |
Neuron Detail Report
This window tells you everything there is to know about
a neuron. The nID, the
Datafield (I/O neurons only), a Trigger value for binary neurons
(NYI) an alternate activation Function (NYI) the last delta, the last
value and its current weight. The
two subforms show the Input and Output (synaptic) weights. You
can type in these values and change the weights.
The Replace button is only use when sharing
neurons. |
Histograms
Straight out of BrainMaker. The x axis show the
weights (to plus or minus 8), and the height of the bars indicate the number
of synapses with that weight. As usual, we are looking for a nice bell curve
in these bar charts. However, I can tell if the MLP is learning or not,
based on MSE and the Neural Cluster Diagram long before the
Historgram shows it. |
|
|