Introduction to the BrainWave Simulator

Copyright © 1997 Devin McAuley
Rewritten for BrainWave 2.0 by Simon Dennis
  1. The Word Identification Network
  2. Creating, Moving, and Deleting Objects
  3. Selecting Objects
  4. Changing Object Parameters
  5. Labels
  6. Values
  7. Weights
  8. Sets
  9. Buttons and Cycling your Network
  10. Graphs
  11. Saving your Network
  12. Printing

Now that you have learned a little bit about what a neural network is, you are ready to begin running and constructing neural networks using BrainWave. In the following sections, create a simple word recognition network from scratch, providing examples of the objects available in the BrainWave simulator.

The Word Identification Network

The network we are going to build in this exercise is shown in Figure 1.

Figure 1: The word identification network.

The word identification network uses all of the basic objects available in BrainWave (units, weights, labels, values, buttons, sets, and graphs). It contains three input units (shown as squares) representing the letters "C", "A", and "T" respectively and one output unit representing the entire word "CAT". The letters "C", "A" and "T" are labels, while the string "CAT = 0" is a value. Values allow us to see activations, weights etc in numerical form. The units representing the letters are connected to the word unit by weights (shown as arrows). In this network each of the three weights is positive indicated by the red colour. In addition, there are two buttons. The first button, labelled "Cycle", starts the network processing. The second button, labelled "Zero Units" resets all of the units to zero activations. At the base of the netowrk is a pattern set. The pattern set allows us to record and quickly reinstate patterns of activations or weights. Try clicking on each of the patterns ("C", "CA", "CAT"). Note how the activations of the input units changes. On the right hand side is a series of graphs. Graphs record the progression of an activation or weight over time.

Start the network by clicking on the Cycle button. The network will execute 10 cycles and the CAT unit will become active because it is connected to active units with a positive weight. Notice that the Total Cycles value has increased to 10 indicating how many cycles have been executed in total. Click on the "Cycle" button again and you should see this value increase to 20. Now click on the Zero Units button. All of the units including the letter units will revert to zero. If you would like to run the network again click on each of the letter units. This toggles their activation either from zero to one. Alternatively, you can click on the "CAT" pattern in the pattern set which will instaniate the entire pattern. Now you can click on Cycle again to repeat the experiment.

Now that we have successfully run the network, lets work through how we would construct such a network. When you entered this page a second window will have appeared with a blank simulator. Construct your network here.

Creating, Moving, and Deleting Objects

To start creating objects, right click anywhere on the screen to bring up the popup menu and move down to the Object menu. Within the object menu you will see the selection of objects from which you may choose. Select the IAC unit object. Now when you click on the BrainWave area a unit will appear. Right away you will notice that it is important to be able to move objects, since it is hard to place a unit exactly where you want it, and you may change your mind about where it should go.

Figure 2: Creating Units.

To move an object, position the mouse over the object you want to move, click down, drag the cursor to the new position for the object, and release the mouse button. Select the Grid On item in the Options menu to place an aligning grid on the workspace. The grid is especially useful for aligning units. To turn off the grid, unselect the Grid On item.

To delete an object, position the mouse over the object that you want to delete, hold down the control key and click.

Exercise 1: In the blank window create four units and arrange them as in Figure 2.

Selecting Objects

When objects are created in BrainWave, they become selected. Selected items in the workspace have green "handles" on their corners. To select an existing object hold down the shift key, position the mouse over the object you want to select and click. If you click again the object will become double selected and the handles will turn yellow. Another click will unselect the object.

Multiple objects can be selected by holding down the shift key while you select the additional objects. Another way to select multiple objects is to click on any unoccupied area of the workspace and drag over the set of objects that you wish to select. A yellow box will indicate the region within which items will be selected. When all of the to-be-selected objects are captured in the box, release the mouse button to select these objects. Any currently selected objects captured in the box will become double selected and any double selected items will become unselected. All currently selected objects can also be unselected by holding down shift and clicking on an unoccupied part of the workspace.

Exercise 2: Select the three letter units by dragging the yellow box over them. Now double select just the first unit. Finally, shift click on the background to unselect all fo the units.

Changing Object Parameters

Right clicking on any object popups a menu showing the parameters associated with that object. To change any parameter select that menu option. For numeric or string values a dialog box will appear allowing you to enter a new value. When you change a value it is updated in that object and all other objects of the same type that are currently selected. This is a very efficient way of changing large numbers of parameters at once.

Exercise 3: Right click on one of the units. The menu should contain six options. The Activation, Max, Min, Rest, and Decay options allow you to change each of these parameters. The frozen option allows you to fix the unit's activation so that it will not be updated when the network is cycled. Try changing the activation of the first unit to 0.5. Now try changing the values of all three units to -0.2 by selecting them all and changing the activation of one of them.

Labels

Carefully selected labels make your network easier for others to understand. For example, labels for units or groups of units provide information about what the units represent; title labels identify a specific model or simulation. To create a label, select the label object from the Object Menu, position the mouse where you would like to place the label, and click (The default text for a label is "Label"). Right click to change the text and the font name, style and size.

Exercise 4: Create labels for the three letter units of your network. Choose a font size of 16 for each of the letter labels and choose the Helvetica font. Your labelled network should look like Figure 3.

Figure 3: Adding Labels to the network.

[Next Section: Values]