Spiking neural networks (SNNs) operating with asynchronous discrete events show higher energy efficiency with sparse computation. A popular approach for implementing deep SNNs is ANN-SNN conversion combining both efficient training of ANNs and efficient inference of SNNs. However, the accuracy loss is usually non-negligible, especially under a few time steps, which restricts the applications of SNN on latency-sensitive edge devices greatly. In this paper, we first identify that such performance degradation stems from the misrepresentation of the negative or overflow residual membrane potential in SNNs. Inspired by this, we decompose the conversion error into three parts: quantization error, clipping error, and residual membrane potential representation error. With such insights, we propose a two-stage conversion algorithm to minimize those errors respectively. Besides, We show each stage achieves significant performance gains in a complementary manner. By evaluating on challenging datasets including CIFAR-10, CIFAR- 100 and ImageNet, the proposed method demonstrates the state-of-the-art performance in terms of accuracy, latency and energy preservation. Furthermore, our method is evaluated using a more challenging object detection task, revealing notable gains in regression performance under ultra-low latency when compared to existing spike-based detection algorithms. Codes are available at https://github.com/Windere/snn-cvt-dual-phase.
翻译:脉冲神经网络(SNNs)通过异步离散事件进行运算,凭借稀疏计算展现出更高能效。实现深度SNN的主流方法之一是ANN-SNN转换技术,该技术融合了ANN的高效训练与SNN的高效推理优势。然而,尤其在时间步数较少的情况下,精度损失通常不可忽略,这严重制约了SNN在延迟敏感型边缘设备上的应用。本文首先揭示了这种性能退化源于SNN中负或溢出残余膜电位的错误表征。基于此发现,我们将转换误差分解为量化误差、截断误差和残余膜电位表征误差三部分。据此提出一种双阶段转换算法,分别对上述误差进行最小化处理。此外,我们证明每个阶段都能以互补方式实现显著的性能提升。通过在CIFAR-10、CIFAR-100和ImageNet等挑战性数据集上的评估,所提方法在精度、延迟和能量保持方面均展现出最先进的性能。进一步地,我们将该方法应用于更具挑战性的目标检测任务,在超低延迟条件下,与现有基于脉冲的检测算法相比,在回归性能上取得了显著提升。代码见https://github.com/Windere/snn-cvt-dual-phase。