arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2408.12293cs.AIcs.CV
收藏

AT-SNN:脉冲神经网络上的视觉Transformer自适应Token

AT-SNN: Adaptive Tokens for Vision Transformer on Spiking Neural Network

KAIST(韩国科学技术院);University of Seoul(首尔市立大学);Sungkyunkwan University(成均馆大学);Hanyang University(汉阳大学);Incheon National University(仁川大学)

Donghwa Kang, Youngmoon Lee, Eun-Kyu Lee, Brent Kang, Jinkyu Lee, Hyeongboo Baek

AI总结:

提出AT-SNN,通过动态调整直接训练的基于SNN的ViTs推理时的token数量,结合ACT丢弃低信息token和新的token合并机制,在保持高准确性的同时显著降低功耗。

摘要:

在脉冲神经网络(SNNs)的训练和推理中,直接训练和轻量级计算方法已被正交开发,旨在降低功耗。然而,只有少数方法同时应用了这两种机制,且未能充分发挥基于SNN的视觉Transformer(ViTs)的优势,因为它们最初是为卷积神经网络(CNNs)设计的。本文提出AT-SNN,旨在动态调整直接训练的基于SNN的ViTs在推理期间处理的token数量,其中功耗与token数量成正比。我们首先展示了自适应计算时间(ACT)对基于SNN的ViTs的适用性(此前仅限于RNNs和ViTs),并增强其以选择性地丢弃信息量较少的空间token。此外,我们提出了一种新的基于token相似性的token合并机制,在提高准确性的同时进一步减少token数量。我们在Spikformer上实现了AT-SNN,并在图像分类任务CIFAR10、CIFAR-100和TinyImageNet上证明了AT-SNN相比最先进方法在实现高能效和准确性方面的有效性。例如,在CIFAR-100上,我们的方法比现有最佳方法最多减少42.4%的token,同时保持更高的准确性。

英文摘要:

In the training and inference of spiking neural networks (SNNs), direct training and lightweight computation methods have been orthogonally developed, aimed at reducing power consumption. However, only a limited number of approaches have applied these two mechanisms simultaneously and failed to fully leverage the advantages of SNN-based vision transformers (ViTs) since they were originally designed for convolutional neural networks (CNNs). In this paper, we propose AT-SNN designed to dynamically adjust the number of tokens processed during inference in SNN-based ViTs with direct training, wherein power consumption is proportional to the number of tokens. We first demonstrate the applicability of adaptive computation time (ACT), previously limited to RNNs and ViTs, to SNN-based ViTs, enhancing it to discard less informative spatial tokens selectively. Also, we propose a new token-merge mechanism that relies on the similarity of tokens, which further reduces the number of tokens while enhancing accuracy. We implement AT-SNN to Spikformer and show the effectiveness of AT-SNN in achieving high energy efficiency and accuracy compared to state-of-the-art approaches on the image classification tasks, CIFAR10, CIFAR-100, and TinyImageNet. For example, our approach uses up to 42.4% fewer tokens than the existing best-performing method on CIFAR-100, while conserving higher accuracy.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑