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的变体SLTT-K,仅允许在K个时间步进行反向传播,从而进一步减少所需标量乘法次数且与总时间步数无关。在静态与神经形态数据集上的实验表明,SLTT具有卓越的训练效率与性能。特别地,我们的方法在ImageNet上达到当前最优精度,同时与BPTT相比,内存开销与训练时间分别减少超过70%与50%。