Spiking Neural Networks (SNNs) are promising energy-efficient models for neuromorphic computing. For training the non-differentiable SNN models, the backpropagation through time (BPTT) with surrogate gradients (SG) method has achieved high performance. However, this method suffers from considerable memory cost and training time during training. In this paper, we propose the Spatial Learning Through Time (SLTT) method that can achieve high performance while greatly improving training efficiency compared with BPTT. First, we show that the backpropagation of SNNs through the temporal domain contributes just a little to the final calculated gradients. Thus, we propose to ignore the unimportant routes in the computational graph during backpropagation. The proposed method reduces the number of scalar multiplications and achieves a small memory occupation that is independent of the total time steps. Furthermore, we propose a variant of SLTT, called SLTT-K, that allows backpropagation only at K time steps, then the required number of scalar multiplications is further reduced and is independent of the total time steps. Experiments on both static and neuromorphic datasets demonstrate superior training efficiency and performance of our SLTT. In particular, our method achieves state-of-the-art accuracy on ImageNet, while the memory cost and training time are reduced by more than 70% and 50%, respectively, compared with BPTT.
翻译:脉冲神经网络(SNN)作为神经形态计算中极具潜力的能效模型,其训练面临非可微难题。基于替代梯度(SG)的时间反向传播(BPTT)方法虽已取得高性能,但训练过程中存在巨大的内存开销与时间成本。本文提出空间时序学习(SLTT)方法,在保持高性能的同时显著提升训练效率。首先,我们发现SNN沿时间维度的反向传播对最终梯度计算的贡献极小,因此建议在反向传播中忽略计算图中的非关键路径。所提方法可减少标量乘法运算量,并实现与总时间步长无关的低内存占用。进一步地,我们提出SLTT-K变体,仅允许在K个时间步长进行反向传播,使所需标量乘法运算量进一步降低且保持与总时间步长解耦。在静态数据集与神经形态数据集上的实验表明,SLTT方法兼具卓越的训练效率与性能。值得注意的是,本方法在ImageNet上达到当前最优的精度,同时相比BPTT方法,内存开销与训练时间分别降低超70%与50%。