arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2403.06978cs.CV
收藏

Attention Prompt Tuning:面向时空建模的预训练模型参数高效适配

Attention Prompt Tuning: Parameter-efficient Adaptation of Pre-trained Models for Spatiotemporal Modeling

Johns Hopkins University(约翰斯·霍普金斯大学)

Wele Gedara Chaminda Bandara, Vishal M. Patel

AI总结:

提出 APT 参数高效微调方法,通过将 prompt 注入非局部注意力的键和值并引入重参数化,在视频动作识别上降低 FLOPs 与延迟且提升性能。

摘要:

本文提出 Attention Prompt Tuning(APT),这是一种用于动作识别等基于视频的应用、计算高效的 prompt tuning 变体。Prompt tuning 方法在微调期间将一组可学习 prompt 与数据 token 一同注入,同时保持骨干网络冻结。与完全微调相比,该方法大幅减少了可学习参数数量。对于基于图像的下游任务,通常只需几个可学习 prompt 就能取得接近完全微调的结果。然而,视频包含更复杂的时空信息,需要数百个可调 prompt 才能获得相当好的结果。这降低了在图像任务中观察到的参数效率,并显著增加推理期间的延迟和浮点运算(FLOPs)数量。为解决这些问题,我们将 prompt 直接注入 transformer 块内非局部注意力机制的键和值中。此外,我们提出一种新的 prompt 重参数化技术,使 APT 对超参数选择更加鲁棒。所提出的 APT 方法大幅减少了 FLOPs 和延迟,同时在 UCF101、HMDB51 和 SSv2 动作识别数据集上相较现有参数高效微调方法实现了显著性能提升。代码和预训练模型可在 https://github.com/wgcban/apt 获取。

英文摘要:

In this paper, we introduce Attention Prompt Tuning (APT) - a computationally efficient variant of prompt tuning for video-based applications such as action recognition. Prompt tuning approaches involve injecting a set of learnable prompts along with data tokens during fine-tuning while keeping the backbone frozen. This approach greatly reduces the number of learnable parameters compared to full tuning. For image-based downstream tasks, normally a couple of learnable prompts achieve results close to those of full tuning. However, videos, which contain more complex spatiotemporal information, require hundreds of tunable prompts to achieve reasonably good results. This reduces the parameter efficiency observed in images and significantly increases latency and the number of floating-point operations (FLOPs) during inference. To tackle these issues, we directly inject the prompts into the keys and values of the non-local attention mechanism within the transformer block. Additionally, we introduce a novel prompt reparameterization technique to make APT more robust against hyperparameter selection. The proposed APT approach greatly reduces the number of FLOPs and latency while achieving a significant performance boost over the existing parameter-efficient tuning methods on UCF101, HMDB51, and SSv2 datasets for action recognition. The code and pre-trained models are available at https://github.com/wgcban/apt

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

↑