www.elsevier.com/locate/micpro
a
Federal Center of Technological Education, Belo Horizonte, MG, Brazil
Department of Electronics Engineering, Federal University of Minas Gerais, Caixa Postal 209, CEP 30.161-970 Belo Horizonte, MG, Brazil
c
Department of Computing, Federal University of Lavras, Lavras, MG, Brazil
Abstract
The implementation on hardware of the first layer of Kanervas sparse distributed memory (SDM) is presented in this work. The hardware
consist on a co-processor board for connection on ISA standard bus of an IBM PCcompatible computer. The board, named reconfigurable
co-processor for SDM(RC-SDM), comprises on Xilinx FPGAs, local random access memory and bus interface circuits. Based on in-system
reconfiguration capacity of FPGAs, RC-SDM easily allows change of the characteristics of SDM topology implemented. First results show a
speed-up of four times of RC-SDM in relation to a software implementation of the algorithm.
q 2004 Elsevier B.V. All rights reserved.
Keywords: Associative memory; Neural networks; FPGAs
1. Introduction
Physical implementation of associative memories is in
the agenda for more than four decades and has been studied
from different perspectives. From the computer architecture
point of view, the term content addressable memories
(CAM) [1] has been coined to refer to those memory
implementations that can retrieve information with partial
clues of the content. The physical implementation of CAM
was usually accomplished with conventional random access
memories (RAM) and additional hardware. From the
connectionist point of view [2], associative memories
were implemented with neuron-like elements, or processing
elements(PE), connected by a network structure. Information was spread throughout the network and stored in the
connections between processors.
The sparse distributed memory (SDM) [3] is an
associative memory model that can be seen from both
perspectives. From the computer architecture point of view,
it can be seen as a generalization of a RAM and from the
connectionist perspective as an artificial neural network
(ANN). Associative memory properties are achieved by
* Corresponding author. Tel.: 55-31-3499-4869; fax: 55-31-34994850.
E-mail address: apbraga@cpdee.ufmg.br (A.P. Braga).
0141-9331/$ - see front matter q 2004 Elsevier B.V. All rights reserved.
doi:10.1016/j.micpro.2004.01.003
128
2. Description of SDM
The essence of SDMs is to use sparsely distributed
decoders in a high dimensional Boolean space so that any
sparse decoder, or hard storage location, is accessed from
anywhere in the space that is at a Hamming distance
smaller than r bits from its base address. Therefore, each
decoder responds to all the vectors inside a hyper-sphere,
or circle in SDMs terminology, with radius r and centre at
the locations base address. Depending on the selected
value for r, input vectors may access more than one storage
location at the same time, allowing data to be stored and
retrieved concurrently to and from several memory storage
locations. Using Kanervas analogy between a hypersphere in the n-dimensional Boolean space and a circle in
the plane [5], an example of the effect of the chosen radius
r in the concurrent access by an input vector j to two
sparse decoders zm and zn is shown in Fig. 1. The chosen
radius ra is large enough to allow access by j to both
decoders zm and zn : If ra were too small, j could have been
located outside the two hyper-spheres and, consequently,
could not have accessed any of them. Therefore, the
condition for j accessing both the arbitrary sparse decoders
zm and zn is that the distance from j to both of them is
less than the chosen radius r: In other words, j must be
inside the intersection of the hyper-spheres with centres in
zm and zn [5].
The size of the radius r in SDMs must be such that the
union of all the sets of elements inside the hyper-spheres
Si zi ; ri includes all the 2n elements of the space {0; 1}n ;
so that any input vector access at least one sparse decoder.
129
130
end if
end for
for col 0 to U 2 1 do
if vcol # 0 then
ocol 1
else
ocol 0
end if
end for
131
132
133
5. Performance considerations
In order to evaluate the performance of RC-SDM, two
programs, one that uses the board and the other that does
not, were implemented. In both programs, the SDM
implemented was set with parameters n 256 and M
16; 384: The machine used to implement the programs and
host the board was a PC microcomputer with a Pentium
Celeron CPU running at 300 MHz. The programs were
written in ANSI C with all SDM functions implemented in
assembly. The main program written in C deals mainly
with accesses to disk and screen, whereas the assembly
routines treat SDM processing in both hardware and
software versions of the program in order to have an
unbiased software implementation. This assures that the
comparison of the hardware is made with a as fast as
possible software implementation. The second program
consists of a modification of the first one, where the
assembly routines were substituted by the processing in the
board. Processing time, that was measured with a logic
analyzer, of the assembly routine was 49.8 ms whereas the
hardware processing at RC-SDM was 13.06 ms, what
resulted in a speed-up of about four times in relation to the
software implementation.
6. Conclusions
More than a proof-of-concept, the implementation of
RC-SDM presented an efficient version of SDMs with
134
Acknowledgements
The authors would like to thank the support from Xilinx
University Program, CNPq and FINEP.
References
[1] A. Krikelis, C.C. Weems, Associative processing and processors, IEEE
Computer (Guest Editorial) (November) (1994).
[2] C. Orovas, Cellular Associative Networks for Pattern Recognition, PhD
thesis, University of York, England, 1999.
[3] P. Kanerva, Sparse Distribuited Memory, Bradford/MIT Press, Cambridge, USA, 1988.
[4] P. Kanerva, Associative-memory models of the cerebellum, in: I.
Aleksander, J. Taylor (Eds.), Artificial Neural Networks, Elsevier
Science Publishers B. V, Amsterdam, 1992.
[5] P. Kanerva, in: M.H. Hassoun (Ed.), Sparse Distributed Memory and
Related Models, Associative Neural Memories: Theory and Implementation, Oxford University Press, New York, 1993, pp. 5076.
[6] R.W. Hartenstein et al., Custom Computing Machines vs. Hardware/
Software Co-Design: from a Globalized Point of View. In: 6th
International Workshop on Field Programmable Logic And Applications, Darmstadt, Germany, September 23-25, 1996.
[7] A.P. Braga, I. Aleksander, Geometrical treatment and statistical
modeling of the distribution of patterns in the n-dimensional boolean
space, Pattern Recognition Letters 16 (1994) 507 515.