Weight Quantization Method for Spiking Neural Networks and Analysis of Adversarial Robustness

LI Ying,LI Yanjie,CUI Xiaoxin,NI Qinglong,ZHOU Yinhao
DOI: https://doi.org/10.11999/JEIT230300
2023-01-01
Abstract:Spiking Neural Networks (SNNs) in neuromorphic chips have the advantages of high sparsity and low power consumption, which make them suitable for visual classification tasks. However, they are still vulnerable to adversarial attacks. Existing studies lack robustness metrics for the quantization process when deploying the network into hardware. The weight quantization method of SNNs during hardware mapping is studied and the adversarial robustness is analyzed in this paper. A supervised training algorithm based on backpropagation and alternative gradients is proposed, and one types of adversarial attack samples, Fast Gradient Sign Method (FGSM), on the CIFAR-10 dataset are generated. A perception quantization method and an evaluation framework that integrates adversarial training and inference are provided innovatively. Experimental results show that direct encoding leads to the worst adversarial robustness in the VGG9 network. The difference between the accuracy loss and inter-layer pulse activity change before and after weight quantization increases by 73.23% and 51.5%, respectively, for four encoding and four structural parameter combinations. The impact of sparsity factors on robustness is: threshold increase > bit reduction in weight quantization > sparse coding. The proposed analysis framework and weight quantization method have been evaluated on the PIcore neuromorphic chip.
What problem does this paper attempt to address?