Direct Training Needs Regularisation: Anytime Optimal Inference Spiking Neural Network
Dengyu Wu, Yi Qi, Kaiwen Cai, Gaojie Jin, Xinping Yi, Xiaowei Huang
TL;DR
The paper tackles the challenge of training Spiking Neural Networks (SNNs) for Anytime Optimal Inference (AOI), where reliable predictions should be maintained across varying timesteps. It introduces Spatial-Temporal Factor (STF) and Spatial-Temporal Regulariser (STR) to regulate the balance between spike activity and membrane potential at each timestep, enabling AOI through direct training, and combines this with Temporal Efficient Training (TET) loss and a softmax-based cutoff. Across frame-based and event-based datasets, STR reduces prediction uncertainty, lowers latency, and maintains or improves accuracy; with cutoff, the approach achieves 2.14 to 2.89× faster inference with only 0.50% to 0.64% accuracy loss on event-based data. The work offers a practical pathway to fast, reliable, and energy-efficient SNNs suitable for real-time neuromorphic applications.
Abstract
Spiking Neural Network (SNN) is acknowledged as the next generation of Artificial Neural Network (ANN) and hold great promise in effectively processing spatial-temporal information. However, the choice of timestep becomes crucial as it significantly impacts the accuracy of the neural network training. Specifically, a smaller timestep indicates better performance in efficient computing, resulting in reduced latency and operations. While, using a small timestep may lead to low accuracy due to insufficient information presentation with few spikes. This observation motivates us to develop an SNN that is more reliable for adaptive timestep by introducing a novel regularisation technique, namely Spatial-Temporal Regulariser (STR). Our approach regulates the ratio between the strength of spikes and membrane potential at each timestep. This effectively balances spatial and temporal performance during training, ultimately resulting in an Anytime Optimal Inference (AOI) SNN. Through extensive experiments on frame-based and event-based datasets, our method, in combination with cutoff based on softmax output, achieves state-of-the-art performance in terms of both latency and accuracy. Notably, with STR and cutoff, SNN achieves 2.14 to 2.89 faster in inference compared to the pre-configured timestep with near-zero accuracy drop of 0.50% to 0.64% over the event-based datasets. Code available: https://github.com/Dengyu-Wu/AOI-SNN-Regularisation
