论文标题
通过参数校准将人工神经网络转换为尖峰神经网络
Converting Artificial Neural Networks to Spiking Neural Networks via Parameter Calibration
论文作者
论文摘要
源自生物学的神经行为的尖峰神经网络(SNN)被认为是下一代神经网络之一。通常,可以通过从预先训练的人工神经网络(ANN)转换来通过使用尖峰神经元替换非线性激活而无需更改参数来获得SNN。在这项工作中,我们认为,简单地将ANN的权重复制和粘贴到SNN不可避免地会导致激活不匹配,尤其是对于经过批处理(BN)层训练的ANN。为了解决激活不匹配问题,我们首先通过将局部转换误差分解为剪辑误差和地板误差,然后定量测量该误差如何使用二阶分析在整个层中传播该误差,从而提供理论分析。在理论结果的激励下,我们提出了一组层的参数校准算法,该算法调整了参数以最大程度地减少激活不匹配。对所提出的算法进行了广泛的实验,对现代体系结构和大规模任务进行了包括Imagenet分类和MS可可检测的实验。我们证明,我们的方法可以通过批处理层面层处理SNN转换,即使在32个时间步骤中也可以有效地保持高精度。例如,在用BN层转换VGG-16时,我们的校准算法可以提高高达65%的精度。
Spiking Neural Network (SNN), originating from the neural behavior in biology, has been recognized as one of the next-generation neural networks. Conventionally, SNNs can be obtained by converting from pre-trained Artificial Neural Networks (ANNs) by replacing the non-linear activation with spiking neurons without changing the parameters. In this work, we argue that simply copying and pasting the weights of ANN to SNN inevitably results in activation mismatch, especially for ANNs that are trained with batch normalization (BN) layers. To tackle the activation mismatch issue, we first provide a theoretical analysis by decomposing local conversion error to clipping error and flooring error, and then quantitatively measure how this error propagates throughout the layers using the second-order analysis. Motivated by the theoretical results, we propose a set of layer-wise parameter calibration algorithms, which adjusts the parameters to minimize the activation mismatch. Extensive experiments for the proposed algorithms are performed on modern architectures and large-scale tasks including ImageNet classification and MS COCO detection. We demonstrate that our method can handle the SNN conversion with batch normalization layers and effectively preserve the high accuracy even in 32 time steps. For example, our calibration algorithms can increase up to 65% accuracy when converting VGG-16 with BN layers.