NeuralNetworkSolutions.com Homepage
HomeAboutContactResourcesProductsSupportNews

Unsupervised Learning in Neural Networks

Hopfield Networks

Unsupervised learning mechanisms differ from supervised learning in that there is no "teacher" to instruct the network. How then, do these networks learn? As early as ancient Greece, philosophers theorised that learning is concerned not with the abstract storage of information, but rather the association of different bits of information. For example, the mention of a friend might lead to all the childhood memories and details associated with them. In the brain this kind of association is important in all aspects of learning but computational models typically implement unsupervised learning rules in perceptual networks such as character recognition programs. While conventional Von-Neumann machines typically struggle with partial or incomplete data, neural networks can deal with this noise.

The networks used in associative memory are examples of a wider group of physical systems that may be thought of doing the same kind of thing. There are different ways of expressing the function of these systems. For example, the system can be thought of as seeking a stable energy state. Consider a ball freely moving within a bowl. If we let the ball go at the side of the bowl (has potential energy) it rolls back and forth (kinetic energy) until eventually it comes to rest at the bottom (no PE and KE) where it stays (system stable). The ball always comes to rest in the same place when it is released and that place is determined by the minimum energy of the system.

Another way of thinking of associative memory is in terms of the network storing multiple patterns and finding the closest match to the initial state. If instead of a single depression in the bowl described above we used a corrugated surface then each individual trough can be considered a memory. If the ball is place somewhere on the surface it will eventually come to rest at the local depression closest to its initial starting point. That is, it evokes the pattern closest to the initial partial pattern.

One example of a network using associative memory is the Hopfield network. Consider a three-node Hopfield network. The network is structured such that each node connects to very other node (but not itself) and the connection weights are symmetric in that the weight from node I to node j is the same as from j to i. Note that unlike the networks we have already encountered, the Hopfield network incorporates feedback and is recurrent rather than feed-forward. Also, unlike the architecture that has been previously used, there are no designated output neurones. Instead, the state of the net at any time is the vector of the node outputs. Given a particular input the network state will repeatedly change until it reaches a stable state where it then stays until the network receives new data. So, the Hopfield network receives "partial data" and processes it eventually resting on a stable state that represents the associated memorised patterns or memories stored by the network. This is analogous to the ball resting at the depressions of the corrugated surface described earlier.

One way of describing the energy dynamics of the Hopfield network is to consider each pair of nodes as joined by a spring, some of which are stretched and other tightly compressed. These springs have the effect of pushing nodes closer and further away from each other in space respectively. This can be considered analogous to the effects of positive and negative weights driving nodes towards the same or different states. To illustrate this consider a positive weight connecting two nodes that initially have opposite values. Over time the "on" node is drives the "off" nodes activation above the threshold. When both nodes are "on" each contributes to the others activation to reinforce this stable state. Note that if both nodes are "off" no contribution to either node is made. Now consider the case of negative weight -w. The situation is now reversed. If one of the nodes fires and the other does not, the "on" node inhibits the "off" node making it even less likely to fire in future, thus reinforcing the stable state. On the other hand if both nodes fire then each inhibits the other, which tends to destabilise this state.

The energy framework can be formally applied by assigning high energies to states that tend to get destabilised and low energies to those that are reinforced. The internode energy eij may be defined as:

This results in the values for eij given in the table below.

xi xj eij
0 0 0
0 1 0
1 0 0
1 1 -wij

To illustrate the meaning of this table consider first, that the weight wij is positive. The last energy entry in the table (-wij) is then negative and is the lowest energy value in the table and therefore the most stable energy state. If the weight wij is negative then the '11' state is the highest energy state and is not favoured. The energy of the entire network E is found by summing over all the pairs of nodes:

Since the sum includes each pair two times (as wij and wji where wij = wji) this may be written as:

We are now in a position to prove mathematically that the network tends towards a stable state. Consider a node k fires. What is the change in network energy?

The first term here contains no reference to node k and for ease of notation may be denoted S. The second term contains node k. xk of the second term is constant and can be taken outside the summation:

The sum following xk is just the activation of the kth node so that:

Let the new output after node k has updated by xk' and the energy be E'. Then:

If we denote change in energy E'-E by "change in E" and the change in output xk' - xk by "change in xk" then:

We can now consider two different cases:

From the above we can see that for any selected node to fire we always the energy of the net decreases or stays the same. However, the energy cannot continue to decrease indefinitely and a lower limit is found by putting xi,xj = 1 in our initial equation:

Thus E must reach some fixed value and stay the same. However, stating that E must stay the same is still not quite the same as reaching a steady state as further change might still take place as long as there are no changes in E. Does this happen? State changes imply changes in xk, but in order for E to remain unchanged ak must be 0 which is not true. So, each change in state does reduce E. There can be at most N of these changes, where N is the number of nodes in the Hopfield network. After this there can be no further change to the net's state and a stable state is achieved.

So far we have allowed only a single node to fire at any one time. That is, they function asynchronously - there is no co-ordination between them in time. The alternative to this approach is synchronous update. Here, all nodes fire at the same time. In order for synchronous update to work each nodes previous output must be available to the rest of the network until all nodes have determined their activation and been updated. Synchronous networks behave somewhat differently to the asynchronous networks already described. Rather than being probabilistic (depending on which node the network starts) the net is deterministic with any state leading a well-defined next state. Interestingly, synchronous networks allow for the possibility of "multiple state cycles" rather than a stable state.

Previous | Next | Page 1 2 3 4

Index | Unsupervised Learning | Hopfield Networks

References:

J.J. Hopfield. Neural networks and physical systems with emergent collective computational properties. Proceedings of the National Academy of Sciences of the USA, 79:2554 - 2588, 1982.

© 2008 Marcus bros


Message Board released
We have just opened a new message board that will provide a centre for...
29 Jul 2005 by marcus



Website released
We have released our new website to provide information about our...
29 Jul 2005 by marcus