CLIF: Complementary Leaky Integrate-and-Fire Neuron for Spiking Neural Networks

Yulong Huang, Xiaopeng Lin, Hongwei Ren, Haotian Fu, Yue Zhou, Zunchang Liu, biao pan, Bojun Cheng

TL;DR

Researchers have developed the Complementary Leaky Integrate-and-Fire (CLIF) neuron to solve the "temporal gradient vanishing" problem that plagues Spiking Neural Networks (SNNs). By adding a hyperparameter-free "complementary potential" that tracks decayed information, CLIF enables more effective training over longer time scales. This allows SNNs to match or even surpass the accuracy of traditional Artificial Neural Networks (ANNs) while maintaining superior energy efficiency.

The Challenge: Temporal Gradient Vanishing in SNNs

Spiking Neural Networks (SNNs) are the "brain-inspired" cousins of traditional deep learning. Unlike standard ANNs that pass continuous values, SNNs communicate via discrete, binary "spikes." This makes them incredibly energy-efficient on specialized neuromorphic hardware.

However, training them is notoriously difficult. Because spikes are discrete (0 or 1), they are non-differentiable, meaning standard backpropagation fails. Researchers typically use "Surrogate Gradients" (SG) to bypass this, but SNNs still usually lag behind their ANN counterparts in accuracy.

The authors of this paper identified a specific culprit for this performance gap: Temporal Gradient Vanishing. In a standard Leaky Integrate-and-Fire (LIF) neuron, the gradient (the signal used to update weights) decays rapidly over time steps due to two main factors:

  1. The Leak: The "leaky" nature of the neuron mathematically acts as a multiplier less than one, shrinking the gradient at every step.
  2. The Reset: When a neuron fires a spike, it resets its internal state, effectively "killing" the gradient path from previous time steps. If a neuron fires even once between time $t$ and $T$, the temporal gradient from $T$ to $t$ essentially vanishes.

The Solution: Complementary Leaky Integrate-and-Fire (CLIF)

To address this, the authors propose the CLIF (Complementary Leaky Integrate-and-Fire) neuron. The core innovation is the introduction of a Complementary Potential ($m_t$).

Comparison of LIF and CLIF forward and backward propagation
  • The Mechanism: While the standard membrane potential ($U_t$) integrates inputs and "leaks" over time, the complementary potential $m_t$ specifically captures and maintains the information that was "leaked" or lost during the reset.
  • Spike Frequency Adaptation: When the neuron fires, $m_t$ increases. This value is then used to make the next "reset" more substantial, mimicking a biological process called hyperpolarization where a recently fired neuron is harder to fire again.
  • Gradient Shortcuts: Mathematically, CLIF creates "extra paths" (shown as red arrows in the figure above) for the gradient to flow through during Backpropagation Through Time (BPTT). Even if the standard membrane potential path is zeroed out by a spike reset, the complementary potential path remains open, allowing the network to learn from long-term temporal dependencies.
  • Implementation: CLIF is "hyperparameter-free" (it uses the same time constant as the LIF neuron) and requires only two additional lines of code compared to a standard LIF model.

Key Insights and Results

The authors evaluated CLIF across static image datasets (CIFAR-10, CIFAR-100, Tiny-ImageNet) and dynamic neuromorphic datasets (DVS-Gesture, CIFAR10-DVS) using architectures like ResNet-18, VGG, and Spike-Driven Transformers.

  • Surpassing ANNs: One of the most striking findings is that CLIF-based SNNs can actually outperform their ANN counterparts (using ReLU) with identical structures. This suggests that the temporal dynamics of SNNs, when trained correctly, offer a distinct representational advantage.
  • State-of-the-Art Accuracy: On CIFAR-10, CLIF achieved 96.69% accuracy, outperforming other popular neuron models like GLIF and PLIF. On Tiny-ImageNet, CLIF reached 64.13% accuracy with only 6 time steps—a significant jump over previous SNN methods that hovered around 55-56%. On the DVS-Gesture dataset, it achieved 99.31% accuracy when paired with a Spike-Driven Transformer backbone.
  • Efficiency via Adaptation: Because CLIF implements spike frequency adaptation, it naturally results in a lower firing rate than standard LIF neurons. Fewer spikes mean fewer operations, leading to lower power consumption on neuromorphic hardware without sacrificing accuracy. Furthermore, CLIF-based networks converge significantly faster during training.

Limitations and Future Work

While CLIF serves as a powerful drop-in replacement for existing SNN neurons, the authors note a few areas for further exploration:

  • Mathematical Complexity: While the code implementation is simple, the underlying equations for the gradient flow are complex. A more thorough analysis of the long-term dynamic behavior of the neuron is still needed.
  • Hardware Implementation: The paper calculates energy efficiency based on Synaptic Operations (SOPs), but actual performance on physical neuromorphic chips (like Loihi or TrueNorth) remains to be tested.
  • Scaling: Future work will explore how CLIF behaves in even larger-scale models or more complex temporal tasks like natural language processing.

Summary updated

BibTeX
@inproceedings{huang2024clif,
  author = {Yulong Huang and Xiaopeng LIN and Hongwei Ren and Haotian FU and Yue Zhou and Zunchang LIU and biao pan and Bojun Cheng},
  title = {{CLIF: Complementary Leaky Integrate-and-Fire Neuron for Spiking Neural Networks}},
  booktitle = {International Conference on Machine Learning},
  year = {2024},
  url = {https://openreview.net/forum?id=yY6N89IlHa},
}
Figure