给音频Transformer做剪枝,能省30%-40%计算量,准确率损失不到1%。
Token Pruning in Audio Transformers: Optimizing Performance and Decoding Patch Importance
- 按重要性筛选音视频片段,动态删减不关键的令牌以降耗。
- 剪枝后计算量减少30%-40%,准确率仅下降不足1%。
- 发现低强度片段也重要,适合优化音频模型推理效率。
视觉变换器(ViTs)在多种计算机视觉任务中达到顶尖性能,但其高计算开销仍是挑战。通过有选择地移除不重要的令牌来降低开销的令牌剪枝方法已被提出。尽管在视觉任务中有效,但在音频任务中应用面临独特挑战,因为时频表示中区分相关与无关区域较困难。本研究首次将令牌剪枝应用于基于Mel-spectrogram的音频分类模型,分析了模型性能与计算成本之间的权衡:TopK剪枝可使AudioMAE和AST的乘加操作(MAC)减少30%-40%,准确率下降不足1%。分析表明,高能量或高变化率的令牌对精度贡献大,但低能量或低变化率的令牌在剪枝后仍具重要性;仅依据能量或变化率剪枝会导致明显精度下降。我们通过注意力分数与这些统计特征间的高度相关性,以及保留令牌获得更显著注意力的事实支持该结论。此外,AudioMAE比AST保留更多低能量令牌,这可归因于AudioMAE的自监督重建目标促使关注所有区块,而AST的监督训练则聚焦标签相关令牌。
原文摘要 · Abstract (English)
Vision Transformers (ViTs) have achieved state-of-the-art performance across various computer vision tasks, but their high computational cost remains a challenge. Token pruning has been proposed to reduce this cost by selectively removing less important tokens. While effective in vision tasks by discarding non-object regions, applying this technique to audio tasks presents unique challenges, as distinguishing relevant from irrelevant regions in time-frequency representations is less straightforward. In this study, for the first time, we applied token pruning to ViT-based audio classification models using Mel-spectrograms and analyzed the trade-offs between model performance and computational cost: TopK token pruning can reduce MAC operations of AudioMAE and AST by 30-40%, with less than a 1% drop in accuracy. Our analysis reveals that while high-intensity or high-variation tokens contribute significantly to model accuracy, low-intensity or low variation tokens also remain important when token pruning is applied; pruning solely based on the intensity or variation of signals in a patch leads to a noticeable drop in accuracy. We support our claim by measuring high correlation between attention scores and these statistical features and by showing retained tokens consistently receive distinct attention compared to pruned ones. We also show that AudioMAE retains more low-intensity tokens than AST. This can be explained by AudioMAE's self-supervised reconstruction objective, which encourages attention to all patches, whereas AST's supervised training focuses on label-relevant tokens.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。