Ternary quantization of spiking neural networks

Yu-Lun WU , Rui-Rui TAN , Shu-Hao ZHANG , Shuang LIANG , Zi-Ang LIU , Zhao WANG , Shao-Qun ZHANG

Front. Comput. Sci. ›› 2027, Vol. 21 ›› Issue (2) : 2102326

PDF (1673KB)
Front. Comput. Sci. ›› 2027, Vol. 21 ›› Issue (2) :2102326 DOI: 10.1007/s11704-025-51519-1
Artificial Intelligence
RESEARCH ARTICLE
Ternary quantization of spiking neural networks
Author information +
History +
PDF (1673KB)

Abstract

In recent years, there has emerged an increasing interest in Spiking Neural Networks (SNNs) due to their potential to handle spatio-temporal information and adapt to resource-constrained environments. However, the high memory and computational demands of full-precision embeddings pose challenges for deployment in low-power edge devices. Existing lightweight algorithms of SNNs often pursue memory compression and inference acceleration, leading to precision dropping and uncertainty increasing. To address this challenge, we introduce a ternary quantization method for achieving both lightweight computation and uncertainty reduction of SNNs. The proposed method comprises two quantization training algorithms that apply ternary quantization to synaptic weights and a regularizer for enhancing both accuracy improvement and uncertainty reduction of ternary SNNs. Our method is compatible with various SNN architectures and surrogate-gradient-based training algorithms. Experiments conducted on various datasets demonstrate that our proposed method outperforms existing methods in terms of accuracy, inference efficiency, energy consumption, memory storage, and uncertainty.

Graphical abstract

Keywords

spiking neural networks / ternary quantization / surrogate gradients / ternarization-aware distillation / uncertainty reduction

Cite this article

Download citation ▾
Yu-Lun WU, Rui-Rui TAN, Shu-Hao ZHANG, Shuang LIANG, Zi-Ang LIU, Zhao WANG, Shao-Qun ZHANG. Ternary quantization of spiking neural networks. Front. Comput. Sci., 2027, 21(2): 2102326 DOI:10.1007/s11704-025-51519-1

登录浏览全文

4963

注册一个新账户 忘记密码

References

[1]

Furber S B, Galluppi F, Temple S, Plana L A . The spinnaker project. Proceedings of the IEEE, 2014, 102( 5): 652–665

[2]

Merolla P A, Arthur J V, Alvarez-Icaza R, Cassidy A S, Sawada J, Akopyan F, Jackson B L, Imam N, Guo C, Nakamura Y, Brezzo B, Vo I, Esser S K, Appuswamy R, Taba B, Amir A, Flickner M D, Risk W P, Manohar R, Modha D S . A million spiking-neuron integrated circuit with a scalable communication network and interface. Science, 2014, 345( 6197): 668–673

[3]

Davies M, Srinivasa N, Lin T H, Chinya G, Cao Y, Choday S H, Dimou G, Joshi P, Imam N, Jain S, Liao Y, Lin C K, Lines A, Liu R, Mathaikutty D, McCoy S, Paul A, Tse J, Venkataramanan G, Weng Y H, Wild A, Yang Y, Wang H . Loihi: a neuromorphic manycore processor with on-chip learning. IEEE Micro, 2018, 38( 1): 82–99

[4]

Zhang S Q, Chen J Y, Wu J H, Zhang G, Xiong H, Gu B, Zhou Z H . On the intrinsic structures of spiking neural networks. Journal of Machine Learning Research, 2024, 25( 194): 1–74

[5]

Samanta A, Hatai I, Mal A K . A survey on hardware accelerator design of deep learning for edge devices. Wireless Personal Communications, 2024, 137( 3): 1715–1760

[6]

Ding J, Zhang J, Huang T, Liu J K, Yu Z . Assisting training of deep spiking neural networks with parameter initialization. IEEE Transactions on Neural Networks and Learning Systems, 2025, 36( 8): 15015–15028

[7]

Deng L, Wu Y, Hu Y, Liang L, Li G, Hu X, Ding Y, Li P, Xie Y . Comprehensive SNN compression using ADMM optimization and activity regularization. IEEE Transactions on Neural Networks and Learning Systems, 2023, 34( 6): 2791–2805

[8]

Hu Y, Zheng Q, Jiang X, Pan G . Fast-SNN: fast spiking neural network by converting quantized ANN. IEEE Transactions on Pattern Analysis and Machine Intelligence, 2023, 45( 12): 14546–14562

[9]

Wei W, Liang Y, Belatreche A, Xiao Y, Cao H, Ren Z, Wang G, Zhang M, Yang Y. Q-SNNs: quantized spiking neural networks. In: Proceedings of the 32nd ACM International Conference on Multimedia. 2024, 8441−8450

[10]

Lin D D, Talathi S S, Annapureddy V S. Fixed point quantization of deep convolutional networks. In: Proceedings of the 33rd International Conference on Machine Learning. 2016, 2849−2858

[11]

Liu Z, Wang Y, Han K, Zhang W, Ma S, Gao W. Post-training quantization for vision transformer. In: Proceedings of the 35th International Conference on Neural Information Processing Systems. 2021, 2152

[12]

Han S, Mao H, Dally W J. Deep compression: compressing deep neural network with pruning, trained quantization and Huffman coding. In: Proceedings of the 4th International Conference on Learning Representations. 2016

[13]

Courbariaux M, Bengio Y, David J P. BinaryConnect: training deep neural networks with binary weights during propagations. In: Proceedings of the 29th International Conference on Neural Information Processing Systems. 2015, 3123−3131

[14]

Courbariaux M, Hubara I, Soudry D, El-Yaniv R, Bengio Y. Binarized neural networks: training deep neural networks with weights and activations constrained to +1 or -1. 2016, arXiv preprint arXiv: 1602.02830

[15]

Esser S K, McKinstry J L, Bablani D, Appuswamy R, Modha D S. Learned step size quantization. 2019, arXiv preprint arXiv: 1902.08153

[16]

Krishnamoorthi R. Quantizing deep convolutional networks for efficient inference: a whitepaper. 2018, arXiv: 1806.08342

[17]

Rastegari M, Ordonez V, Redmon J, Farhadi A. XNOR-Net: ImageNet classification using binary convolutional neural networks. In: Proceedings of the 14th European Conference on Computer Vision. 2016, 525−542

[18]

Hubara I, Courbariaux M, Soudry D, El-Yaniv R, Bengio Y . Quantized neural networks: training neural networks with low precision weights and activations. Journal of Machine Learning Research, 2018, 18( 187): 1–30

[19]

Jacob B, Kligys S, Chen B, Zhu M, Tang M, Howard A, Adam H, Kalenichenko D. Quantization and training of neural networks for efficient integer-arithmetic-only inference. In: Proceedings of 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2018, 2704−2713

[20]

Wang K, Liu Z J, Lin Y J, Lin J, Han S. HAQ: hardware-aware automated quantization with mixed precision. In: Proceedings of 2019 IEEE/CVF Conference on Computer Vision and Pattern Recognition. 2019, 8604−8612

[21]

Zhu C, Han S, Mao H, Dally W J. Trained ternary quantization. In: Proceedings of the 5th International Conference on Learning Representations. 2017

[22]

Li Y, Ding W, Liu C, Zhang B, Guo G. TRQ: ternary neural networks with residual quantization. In: Proceedings of the 35th AAAI Conference on Artificial Intelligence. 2021, 8538−8546

[23]

Vindas Y, Roux E, Guépié B K, Almar M, Delachartre P . An asymmetric heuristic for trained ternary quantization based on the statistics of the weights: an application to medical signal classification. Pattern Recognition Letters, 2025, 188: 37–45

[24]

Neftci E O, Mostafa H, Zenke F . Surrogate gradient learning in spiking neural networks: bringing the power of gradient-based optimization to spiking neural networks. IEEE Signal Processing Magazine, 2019, 36( 6): 51–63

[25]

Zhang S Q, Zhang Z Y, Zhou Z H . Bifurcation spiking neural network. Journal of Machine Learning Research, 2021, 22( 1): 253

[26]

Zheng H, Wu Y, Deng L, Hu Y, Li G. Going deeper with directly-trained larger spiking neural networks. In: Proceedings of the 35th AAAI Conference on Artificial Intelligence. 2021, 11062−11070

[27]

Ding J, Yu Z, Tian Y, Huang T. Optimal ANN-SNN conversion for fast and accurate inference in deep spiking neural networks. In: Proceedings of the 30th International Joint Conference on Artificial Intelligence. 2021, 2328−2336

[28]

Lu S, Sengupta A . Exploring the connection between binary and spiking neural networks. Frontiers in Neuroscience, 2020, 14: 535

[29]

Wang Y, Xu Y, Yan R, Tang H . Deep spiking neural networks with binary weights for object recognition. IEEE Transactions on Cognitive and Developmental Systems, 2021, 13( 3): 514–523

[30]

Pfeiffer M, Pfeil T . Deep learning with spiking neurons: opportunities and challenges. Frontiers in Neuroscience, 2018, 12: 774

[31]

Eshraghian J K, Lu W D. The fine line between dead neurons and sparsity in binarized spiking neural networks. 2022, arXiv preprint arXiv: 2201.11915

[32]

Qiao G, Ning N, Zuo Y, Hu S, Yu Q, Liu Y . Direct training of hardware-friendly weight binarized spiking neural network with surrogate gradient learning towards spatio-temporal event-based dynamic data recognition. Neurocomputing, 2021, 457: 203–213

[33]

Jang H, Skatchkovsky N, Simeone O. BiSNN: training spiking neural networks with binary weights via Bayesian learning. In: Proceedings of 2021 IEEE Data Science and Learning Workshop. 2021, 1−6

[34]

Kheradpisheh S R, Mirsadeghi M, Masquelier T . BS4NN: binarized spiking neural networks with temporal coding and learning. Neural Processing Letters, 2022, 54( 2): 1255–1273

[35]

Pei Y, Xu C, Wu Z, Liu Y, Yang Y . ALBSNN: ultra-low latency adaptive local binary spiking neural network with accuracy loss estimator. Frontiers in Neuroscience, 2023, 17: 1225871

[36]

Rueckauer B, Lungu I A, Hu Y, Pfeiffer M, Liu S C . Conversion of continuous-valued deep networks to efficient event-driven networks for image classification. Frontiers in Neuroscience, 2017, 11: 682

[37]

Li F, Liu B, Wang X, Zhang B, Yan J. Ternary weight networks. 2016, arXiv preprint arXiv: 1605.04711

[38]

Bengio Y, Léonard N, Courville A. Estimating or propagating gradients through stochastic neurons for conditional computation. 2013, arXiv preprint arXiv: 1308.3432

[39]

Zhang S H, Tang W C, Wu C, Hu P, Li N, Zhang L J, Zhang Q, Zhang S Q. TernaryCLIP: efficiently compressing vision-language models with ternary weights and distilled knowledge. 2025, arXiv preprint arXiv: 2510.21879

[40]

Bottou L. Large-scale machine learning with stochastic gradient descent. In: Proceedings of the 19th International Conference on Computational Statistics. 2010, 177−186

[41]

Kingma D P, Ba J. Adam: a method for stochastic optimization. 2014, arXiv preprint arXiv: 1412.6980

[42]

Kendall A, Gal Y. What uncertainties do we need in Bayesian deep learning for computer vision? In: Proceedings of the 31st International Conference on Neural Information Processing Systems. 2017, 5580−5590

[43]

Gal Y, Ghahramani Z. Dropout as a Bayesian approximation: representing model uncertainty in deep learning. In: Proceedings of the 33rd International Conference on International Conference on Machine Learning. 2016, 1050−1059

[44]

Lecun Y, Bottou L, Bengio Y, Haffner P . Gradient-based learning applied to document recognition. Proceedings of the IEEE, 1998, 86( 11): 2278–2324

[45]

Krizhevsky A. Learning multiple layers of features from tiny images. Toronto: University of Toronto, 2009

[46]

Shrestha S B, Orchard G. SLAYER: spike layer error reassignment in time. In: Proceedings of the 32nd International Conference on Neural Information Processing Systems. 2018, 1419−1428

[47]

Fang W, Yu Z, Chen Y, Masquelier T, Huang T, Tian Y. Incorporating learnable membrane time constant to enhance learning of spiking neural networks. In: Proceedings of 2021 IEEE/CVF International Conference on Computer Vision. 2021, 2641−2651

[48]

Sakai Y, Pedroni B U, Joshi S, Tanabe S, Akinin A, Cauwenberghs G . Dropout and DropConnect for reliable neuromorphic inference under communication constraints in network connectivity. IEEE Journal on Emerging and Selected Topics in Circuits and Systems, 2019, 9( 4): 658–667

[49]

Fang W, Chen Y, Ding J, Yu Z, Masquelier T, Chen D, Huang L, Zhou H, Li G, Tian Y . SpikingJelly: an open-source machine learning infrastructure platform for spike-based intelligence. Science Advances, 2023, 9( 40): eadi1480

[50]

Yu Q, Tang H, Tan K C, Li H . Rapid feedforward computation by temporal encoding and learning with spiking neurons. IEEE Transactions on Neural Networks and Learning Systems, 2013, 24( 10): 1539–1552

[51]

Xu Q, Qi Y, Yu H, Shen J, Tang H, Pan G. CSNN: an augmented spiking based framework with perceptron-inception. In: Proceedings of the 27th International Joint Conference on Artificial Intelligence. 2018, 1646−1652

[52]

Liu Q, Pan G, Ruan H, Xing D, Xu Q, Tang H . Unsupervised AER object recognition based on multiscale spatio-temporal features and spiking neurons. IEEE Transactions on Neural Networks and Learning Systems, 2020, 31( 12): 5300–5311

[53]

Zhao B, Ding R, Chen S, Linares-Barranco B, Tang H . Feedforward categorization on AER motion events using cortex-like features in a spiking neural network. IEEE Transactions on Neural Networks and Learning Systems, 2015, 26( 9): 1963–1978

[54]

Wang T, Shi C, Zhou X, Lin Y, He J, Gan P, Li P, Wang Y, Liu L, Wu N, Luo G . CompSNN: a lightweight spiking neural network based on spatiotemporally compressive spike features. Neurocomputing, 2021, 425: 96–106

[55]

Roy D, Chakraborty I, Roy K. Scaling deep spiking neural networks with binary stochastic activations. In: Proceedings of 2019 IEEE International Conference on Cognitive Computing. 2019, 50−58

[56]

Yan Z, Bai Z, Wong W F. Reconsidering the energy efficiency of spiking neural networks. 2024, arXiv preprint arXiv: 2409.08290

RIGHTS & PERMISSIONS

Higher Education Press

PDF (1673KB)

Supplementary files

Highlights

430

Accesses

0

Citation

Detail

Sections
Recommended

/