Pulsed Neural Networks and Their Application: Daniel R. Kunkle Chadd Merrigan
Pulsed Neural Networks and Their Application: Daniel R. Kunkle Chadd Merrigan
February, 2002
3
customary to define a length of time after which the
response function can be approximated as zero.
(b)
6+ 4 2
Figure 4: Shape of a biological response function (Maass,
− cos π +1
1997). ′
2
t − s + 1+ 2
One spike is generally not enough to cause a postsynaptic t end − t ′ π
neuron to fire. Biological neurons typically must have
their potentials raised by around 20 mV, while individual 2
spikes change this potential by a few millivolts at most
(Maass, 1997). Therefore to determine Pv(t) it is necessary where t - s’ represents the time since the spike reached the
to integrate the response function for each spike neuron, tend - t’ represents the duration of the applicable
encountered before time t. This could be a daunting task response function values. This equation effectively
as spikes accumulate over a simulation. Accordingly, it is stretches a cosine wave shrunk to [0, 1] onto the range of
4
all positive numbers (t - s’) using a quadratic mapping (b) The effect of several spikes arriving at one synapse
β u, v
function of the form .
(x + α )2 ∑ ε (t − s′ )
u ,v n
n:sn∈Fu
3.4 Weights
where Fu is the set of firing times of neuron u.
As in the models of the previous two generations of
artificial neurons, the input potential Pv(t) a spiking
(c) The effect of spike trains from several input neurons
neuron v are mediated by a weight wij where i is the index
of the presynaptic neuron for which this w applies. u1 Ku n
:
Generally, this is used as a multiplicand with the value of
_(t - s) to arrive at the effective EPSP or IPSP for the
connection from ui to vj as it is in the perceptron model. ∑ ∑ ε (t − s′ )
i:un∈Γv n:sn∈Fui
u ,v n
However, it has been shown that real synapses do not fire
in a deterministic manner (Maass, 1997). Rather, the
property represented by our w value would be analogous where Γv is the set of all input neurons to v.
to a probability of firing at a real synapse. The vesicles
containing neurotransmitters to cross the synaptic gap
release their contents completely, yet the release is not (d) Finally, with the effect of weights wij :
guaranteed to happen consistently. There are currently
many researchers working with these stochastic networks
which are essentially the same as networks known as the
Pv (t ) = ∑ ∑ ε (t − s′ ) w
i:un∈Γv n:sn∈Fui
u ,v n ij
5
10! orders. Furthermore, the model of neuronal dynamics
which can accomplish a sensitivity to order is alluringly
simple.
7
where tv is the firing time of the postsynaptic neuron and is increased above 1 or decreased below 0 it is set to 1 or
t0 is the second firing time of the presynaptic neuron (tu is 0 respectively. Over time, this rule leads to neuron v firing
the first firing time of neuron u), and η is the learning at desired times and remaining inactive at other times.
rate. If the second firing of u, t0, occurs before the firing
Because training in this way only occurs when the
of v (tv – t0 > 0) then the weight between them, w u,v ,
postsynaptic neuron fires it is crucial that the neuron
should be increased. If the opposite occurs, tv is before t0,
always has a chance to fire, even when the initial weights
the weight should be decreased. This is shown by figure
for its synapses are very low. There are two ways to
8, which compares these two cases.
ensure that a neuron always has at least some chance of
The assumption is that the first firing of the presynaptic firing. The first is to have a dynamic threshold. When the
neuron, u, is intended to make the postsynaptic neuron, v, neuron fires the threshold is increased by some value.
fire at time t0, along with the second firing of u. So, the Over periods of inactivity the threshold is decreased. So,
firings of the presynaptic and postsynaptic neurons are to if a neuron does not fire for an extended period of time
be synchronized and the network will have learned to the threshold will lower enough such that it begins firing
output the desired spike train when given a specific input. and hence learning. The second method is to have a base
firing rate that the neuron maintains even when it receives
The above method includes only one presynaptic and one no activation. In this case also the neuron has a chance to
postsynaptic neuron. In most situations, however, a learn periodically even though it may not be receiving
postsynaptic neuron will have many presynaptic neurons enough activation due to low weights. This base firing
contributing to its activation. In this case the weights rate exists is known to exist in biological neurons. In this
could still be learned in the same manner, but the case we chose to implement the first method, a dynamic
postsynaptic neuron could only receive input from only threshold.
one presynaptic neuron at a time. The weights in this case
would be learned serially.
The weights can also be learned in parallel through an
expansion of the above method. The postsynaptic neuron
in this case is induced to fire at some time t0 by way of an
additional synapse with sufficient weight. The weights
wui,v on the synapse from neuron ui to neuron v are
updated by the following rule
∆wui,v = η(t0 – tui)
where t ui is the firing time of neuron ui. Further, the
weight vector must be normalized after each application
of the learning rule.
5 IMPLEMENTATION OF LEARNING
Our implementation of supervised learning with a spiking
neuron, like that presented by Ruf and Schmitt, is based
on Hebbian learning. That is, synaptic weights are
increased when both the presynaptic neuron is active at
the time that the postsynaptic neuron produces a spike. Figure 9: Three types of rhythms used in training. a)
The weights in this case are initialized randomly in the The top shows a high frequency spike train on the first
range from 0 to 1. The rule for the change of weight w ui,v input and a low frequency spike train on the second
from neuron ui to neuron v whenever neuron v produces a input. Below this is the opposite. Correspondingly, the
spike is first output neuron should spike for the top set and the
second output neuron should spike for the bottom set.
∆wui,v = η εu(t – tu) χ b) A training set where the inputs are either
where η is the learning rate, εu(t – tu ) is the response of synchronized or not. c) A training set where either the
neuron u at the time, t, that neuron v fires, and χ is an first input regularly occurs shortly before or shortly
indicator of whether the spiking of neuron v is desired at after the second.
this time. If the spiking is not desired, χ is –1, otherwise it
is 1. In other words, the weight of the synapse from u to v A set of simple test data was constructed to evaluate the
will change by an amount proportional to the contribution learning rule above. Earlier generations of neurons, based
of neuron u at the time of firing and will be positive if the on rate coding, often use simple functions of two inputs to
spiking is desired and negative if not desired. If a weight test neural models and learning, such as the logical AND,
8
Figure 10: Top: Action potential of two output Figure 11: Top: Action potential of two output
neurons while training on frequency rhythms. A “1” at neurons while testing after training. Bottom: Spikes
the top of the graph signifies that a high frequency generated by output neurons. The question marks
input is being given on input one and that output one signify that the network does not know which output it
(blue) should be more active. A “2” signifies that the is expected to provide.
opposite pattern is being presented and that the second
output (green) should be more active. The dashed lines
represent the dynamic thresholds of the output neurons. 5.2 Results
Bottom: The corresponding spikes of output one and
two. A vertical line is one spike, blue for 1 and green The graphs in figure 10 show the results of training a
for 2. network of spiking neurons with two inputs and two
outputs using the frequency based rhythms as training
vectors. In the case of a high frequency spike train on the
OR and XOR functions. We sought to create equally first input and a low frequency spike train on the second
simple functions based on temporal coding. input the first output neuron should be active, that is, have
a higher action potential and spike more often. In the case
5.1 Rhythms of the reverse the second neuron should be the more
active.
We developed three “rhythms” to test the presented
supervised learning algorithm for spiking neurons. The You can see that after one a few presentations of data the
networks in this case are composed of two input neurons, appropriate neurons begin to fire when presented with the
which receive the rhythmic sequences of firing, and two frequency patterns. While encouraging at first this result
output neurons, that will fire to signal which rhythm is is actually misleading, as is shown by figure 11. These
being presented. The three rhythms are based on the graphs show the response of the network after it has been
relative frequency of spikes, the synchrony of spikes, and trained and the weights are stationary. The network was
the relative timing of spikes. These rhythms are presented presented with the same frequency rhythm data that it was
graphically in figure 9. trained on. You can see that one neuron is continually
9
active while the other hardly responds at all. The
promising results during training were actually created by The networks that can be created on the simulator are
the changing of the weights and not the weights highly configurable. Individual neurons may be added at
themselves. Each time a neuron is supposed to respond its any time and connected by dragging the mouse from the
weights are increased, hence making it respond more. source neuron to the destination. New layers can be added
Correspondingly, when it is desired that a neuron not fire en masse, with the options partially shown in this box:
its weights are decreased. This occurs each time that a
pattern is presented. The network is small enough such
that it can respond to these changes rapidly enough that it
produces the correct responses for most of the time.
Because the second neuron (graphed as green) was the
last one to be trained positively during the learning
sessions, it is the one that responds to the inputs in the
testing set.
The simulation shown above was from a layer of seven Each of the dynamics of our learning model were
input neurons to two outputs. The potentials of the two configurable by the control panel on the right. The
following shows our default experimental starting points:
output neurons are recorded by the scrolling graph at the
upper right.
10
The default threshold is given as a multiple of the 2 Gerstner, W., Kempter, R., Leo van Hemmen, J.,
maximum response function voltage. The threshold boost Wagner, H. (1999) “Hebbian Learning of Pulse
is a factor applied to neurons when they fire, partly to Timing in the Barn Own Auditory System”. In W.
make up for their eventual loss of resistance through the Maass and C. M. Bishop (eds.), Pulsed Neural
periodic threshold decay, but partly to reduce their Networks. MIT Press, Cambridge, Mass., 1999.
sensitivity when overstimulated. It is our observation that 3 Jahnke, A., Roth U., Schönauer, T. (1999) “Digital
biological neurons consistently find a middle ground Simulation of Spiking Neural Networks”. In W.
between not firing at all and firing at their maximum rate. Maass and C. M. Bishop (eds.), Pulsed Neural
Since neurons, like all cells, are essentially autonomous Networks. MIT Press, Cambridge, Mass., 1999.
entities within the protection of the environment held
constant by the body around them, it seems sensible that 4 Kohonen, T. (2001) Self-Organizing Maps. Springer
Series in Information Sciences, Vol. 30, Springer,
their gravitation toward the middle ground of firing (30-
Berlin, Heidelberg, New York, 2001.
50Hz) is critical to their health. The learning rate is the
η found in our learning equation, 5 Krüger, J., Aiple, F. (1988) "Multielectrode
investigation of monkey striate cortex: spike train
wnew = wold + η εu(t – tu) χ correlations in the infragranular layers", J.
Neurophysiology, vol. 60, pp 798--828, 1988.
where t is the target value and ε represents the strength of 6 Maass, W. (1997) “Networks of Spiking Neurons:
the EPSP at the time of firing. The Third Generation of Neural Network Models”
Neural Networks, 10(9):1659–1671.
The simulator was used to verify the MATLAB results as
7 Maass, W. (1999) “Computing with spiking
per learning rhythms as well as to get immediate results
neurons”. In W. Maass and C. M. Bishop (eds.),
with various experiments. Many configurations of
Pulsed Neural Networks. MIT Press, Cambridge,
network were tried and trained within a short period to Mass., 1999.
gauge their abilities to learn. Though our nets did not
realize a satisfying learning achievement, we ourselves 8 Ruf, B., Schmitt, M. (1997) "Learning temporally
learned to recognize many unpredicted dynamics of encoded patterns in networks of spiking neurons,"
spiking nets through the observations of our data. The Neural Processing Letters, vol. 5, no. 1, pp. 9--18,
program is available at 1997.
9 Ruf, B., Schmitt, M. (1998) "Self-Organization of
http://www.cs.rit.edu/~ccm2451 /pub/snn.exe Spiking Neurons Using Action Potential Timing", in
IEEE Trans on Neural Networks, Vol. 9, No. 3, May
for anyone who is interested in using it. 1998, pp. 575-578.
10 Thorpe, S., Delorme, A., VanRullen, R. (2001)
“Spike based strategies for rapid processing”. Neural
7 REFERENCES Networks, 14(6-7), 715-726.
1 Gerstner, W. (1999) “Spiking Neurons”. In W. Maass
and C. M. Bishop (eds.), Pulsed Neural Networks.
MIT Press, Cambridge, Mass., 1999.
11