14
FPGA Implementa.on of a Spiking Neural Network for Pa9ern Matching LouisCharles Caron Frédéric Mailhot Jean Rouat

FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

FPGA  Implementa.on  of  a  Spiking  Neural  Network  for  Pa9ern  

Matching  Louis-­‐Charles  Caron  Frédéric  Mailhot  

Jean  Rouat  

Page 2: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Pa9ern  matching  

•  What  is  pa9ern  matching  ?  –  Iden.fica.on  and  associa.on  of  pa9erns  in  a  set  of  input  data  

•  How  is  it  implemented  ?  – The  Oscillatory  Dynamic  Link  Matcher  (ODLM)  

•  Image  segmenta.on  and  comparison  [1]  

•  Monophonic  sound  source  separa.on  [2]  

•  Why  port  it  to  hardware  ?  – Versa.lity  of  the  ODLM  on  an  embedded  system  

[1]  Pichevar  et  al.,  Neurocompu.ng  (2006)  [2]  Pichevar  and  Rouat,  Neurocompu.ng  (2007)  

Page 3: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

The  ODLM  

•  Signal  processing  task  determines  – the  size  of  the  network  – the  topology  of  the  network  

•  Image  segmenta.on  Original  image   State  of  the  network  

ODLM:  Oscillatory  Dynamic  Link  Matcher  

Page 4: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

The  ODLM  

•  Leaky  integrate  and  fire  neuron  model  

ODLM:  Oscillatory  Dynamic  Link  Matcher  

– Synap.c  weights  – Membrane  model  

Page 5: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Main  focus  points  

•  Scalability  – Adapt  the  size  of  the  network  to  the  applica.on  at  hand  

•  Flexibility  – Allow  the  implementa.on  of  networks  of  any  topology  

•  Parallelism  – Perform  batch  propaga.on  of  simultaneous  spikes  

Page 6: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Scalability  

•  Bit-­‐slice  architecture  – Layout  friendly,  easy  placement  and  rou.ng  – Each  slice  implements  one  neuron  

Slice  1  

Slice  2  

Slice  3  

Slice  4  

Slice  5  

Slice  6  

Slice  7  

Page 7: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Flexibility  

•  Store  the  weights  as  if  fully  connected  – Slice  i  stores  the  weights  from  all  the  neurons  to  neuron  i  

W[N,N]  =  0.16  

W[1,N]  =  1  W[i,N]  =  …  

W[2,N]  =  0  

N  

1   i  

2  

Page 8: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Parallelism  

•  Update  of  the  membrane  poten.als  

•  Propaga.on  of  simultaneous  spikes  

W[4,3]  

W[5,3]  

W[1,3]  

Weights[  :  ,  4  ]  

Weights[  :  ,  5  ]  

Weights[  :  ,  2  ]  

Weights[  :  ,  1  ]  

0   1   1   0   0  

W[4,4]   W[5,5]  W[3,3]  W[2,2]  W[1,1]   W[3,3]  

W[3,4]   W[4,5]  W[1,2]  W[5,1]   W[2,3]  W[2,3]  

Spiking  bits  1  0  

0   0  

Page 9: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Performance  •  Xilinx  XC5VSX50T  Virtex-­‐5  FPGA  clocked  at  100  MHz  

– 648  neurons  and  419904  synapses  

•  Processing  speed  – Full  synchroniza.on:    6M  spikes/s  – No  synchroniza.on:    9.6k  spikes/s  

•  Image  segmenta.on  – 27×24  pixel  image  – 8-­‐neighbor  topology  – 648  neurons  – 2  seconds  of  processing  

•  Image  comparison  – 90×30  pixel  images  – Fully  connected  topology  – 112  neurons  – 550  ms  of  processing  

Page 10: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Performance  

•  Compared  to  other  hardware  spiking  neural  networks  [3]  – Be9er  flexibility  – Lower  performance  

•  Compared  to  solware  ODLM  – Low  number  of  neurons  – Ini.aliza.on  method  

[3]  Vega-­‐Pineda  et  al.,  IEEE  IJCNN  Proceedings,  2006.  

Page 11: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Future  work  

•  Improve  support  for  various  regular  topologies  – Slices  should  • handle  several  neurons  •  store  fewer  weights  per  neuron  

Weights[  :  ,  1  ]  

Weights[  :  ,  2  ]  

Weights[  :  ,  1  ]  

2N  neurons  N  neurons  

– A  network  of  52488  neurons  with  8-­‐neighbor  connec.vity  (81  neurons  /  slice)  

Slice  1  

N  weights  per  neuron  N/2  weights  per  neuron  

Page 12: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Conclusion  

•  Bit-­‐slice  architecture  + Scalable  + Placement  and  rou.ng  on  ASIC  

•  Square  weight  matrix  + Flexible  + Plas.city/learning  − Burdensome  

ASIC:  Applica.on-­‐specific  integrated  circuit  

Page 13: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Conclusion  

•  Level  of  synchrony  affects  processing  speed  + Exploits  the  synchrony  in  the  network  − Random  ini.aliza.on  of  poten.als  

•  Performance  + Be9er  flexibility  − Lower  processing  speed  

•  Spike  detec.on  signal  − Cri.cal  path  

Page 14: FPGA%Implementaon%of%aSpiking% …...Paern% matching% • What%is%paern% matching? – Iden.ficaon%and%associaon%of%paerns%in%asetof%input data • How%is%it%implemented? – The%Oscillatory%Dynamic

Summary  

•  FPGA  implementa.on  of  a  spiking  neural  network  for  pa9ern  matching  – Processes  simultaneous  spikes  in  parallel  – Can  be  ajusted  in  size  – Can  perform  different  signal  processing  tasks  

– Can  be  improved  to  yield  be9er  performance  with  networks  of  regular  topology