HW/SW Codesign for Robust and Efficient Binarized SNNs by Capacitor Minimization

Mikail Yayla, Simon Thomann, Ming-Liang Wei, Chia-Lin Yang, Jian-Jia Chen, Hussam AmroucharXiv 2023 · DOI

Introduction

Analog computing is a promising frontier for running massive Neural Network (NN) workloads efficiently. Specifically, Integrate-and-Fire (IF) Spiking Neural Networks use capacitors to integrate current over time; when a threshold is reached, the neuron "fires."

However, there is a major hardware bottleneck: the membrane capacitor. To represent a wide range of Multiply-Accumulate (MAC) values accurately, these capacitors often need to be quite large. Large capacitors consume significant silicon area, increase latency (taking longer to charge), and waste energy. Furthermore, analog components are sensitive to process variations—tiny differences in how chips are manufactured—which can cause timing errors and degrade inference accuracy.

Proposed Methods: CapMin and CapMin-V

The authors propose two main techniques focused on Binarized Neural Networks (BNNs), which are inherently more efficient and robust than high-precision networks:

  1. CapMin (Capacitor Minimization): The authors observed that MAC values in BNNs follow a normal distribution—most values cluster around the mean, while extreme values are incredibly rare. CapMin exploits this by only assigning unique spike times to the most frequent MAC values (controlled by a parameter $k$). Rare values at the "tails" of the distribution are clipped and mapped to the nearest represented value. Reducing the number of required spike times allows for a much smaller capacitor.
  2. CapMin-V (Variation-Aware CapMin): To handle hardware noise, the authors analyzed which spike times are most susceptible to error. They found that larger currents (which lead to shorter spike times) have smaller "safety margins." CapMin-V improves robustness by merging these "weak" spike times with their neighbors, effectively trading a small amount of capacitor size for significantly better tolerance to current fluctuations.

The team used a specialized HW/SW framework connecting PyTorch (for neural network logic) with SPICE (for accurate circuit simulation of 14nm FD-SOI technology).

Key Insights and the "Long Tail" Phenomenon

A central observation of this work is that dedicating hardware resources to represent rare events is a poor trade-off. In a BNN, the highest and lowest MAC values occur 5 to 7 orders of magnitude less frequently than the mean.

Distribution of MAC values across five standard image classification benchmarks.

There is a reciprocal relationship between spike times and MAC values. Smaller capacitors charge faster, which reduces latency but makes the "distance" between spike times smaller and harder for a clock to distinguish. Furthermore, variation is not uniform; by identifying which MAC levels are most likely to be misidentified due to process variation, the authors can selectively "strengthen" the network's hardware mapping.

Evaluation and Results

The methods were evaluated on five standard image classification benchmarks: FashionMNIST, KuzushijiMNIST, SVHN, CIFAR10, and Imagenette (a subset of ImageNet).

  • 14× Capacitor Reduction: CapMin reduced capacitor size from 135.2 pF to just 9.6 pF while keeping accuracy degradation under 1%.
  • 14× Latency Improvement: Because smaller capacitors charge faster, the "Guaranteed Response Time" improved by the same factor.
  • Robustness: While standard CapMin struggles under process variation, CapMin-V sustained high accuracy by only increasing the minimized capacitor size by 28%—still a massive net win over the baseline.
  • Energy Efficiency: Energy consumption per MAC computation is directly proportional to capacitor size; thus, the 14× reduction in size translates to significant energy savings.

Conclusion and Future Work

This paper introduces CapMin, a hardware/software codesign approach that slashes the size of membrane capacitors in analog SNNs by up to 14×. While currently focused on BNNs, the concepts of clipping rare values and variation-aware mapping provide a roadmap for more efficient analog AI hardware. Future work may involve "variation-aware training," where the model learns to be even more comfortable with the hardware's specific clipping and noise characteristics.

Summary updated

Abstract

Using accelerators based on analog computing is an efficient way to process the immensely large workloads in Neural Networks (NNs). One example of an analog computing scheme for NNs is Integrate-and-Fire (IF) Spiking Neural Networks (SNNs). However, to achieve high inference accuracy in IF-SNNs, the analog hardware needs to represent current-based multiply-accumulate (MAC) levels as spike times, for which a large membrane capacitor needs to be charged for a certain amount of time. A large capacitor results in high energy use, considerable area cost, and long latency, constituting one of the major bottlenecks in analog IF-SNN implementations. In this work, we propose a HW/SW Codesign method, called CapMin, for capacitor size minimization in analog computing IF-SNNs. CapMin minimizes the capacitor size by reducing the number of spike times needed for accurate operation of the HW, based on the absolute frequency of MAC level occurrences in the SW. To increase the operation of IF-SNNs to current variation, we propose the method CapMin-V, which trades capacitor size for protection based on the reduced capacitor size found in CapMin. In our experiments, CapMin achieves more than a 14$\times$ reduction in capacitor size over the state of the art, while CapMin-V achieves increased variation tolerance in the IF-SNN operation, requiring only a small increase in capacitor size.
BibTeX
@misc{yayla2023hw,
  author = {Mikail Yayla and Simon Thomann and Ming-Liang Wei and Chia-Lin Yang and Jian-Jia Chen and Hussam Amrouch},
  title = {{HW/SW Codesign for Robust and Efficient Binarized SNNs by Capacitor Minimization}},
  year = {2023},
  eprint = {2309.02111},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2309.02111},
}
Figure