邻近斑块合并可减少空间冗余,加快视觉转换器的速度

IF 5.5 2区 计算机科学 Q1 COMPUTER SCIENCE, ARTIFICIAL INTELLIGENCE Neurocomputing Pub Date : 2024-10-19 DOI:10.1016/j.neucom.2024.128733
Kai Jiang , Peng Peng , Youzao Lian , Weihui Shao , Weisheng Xu
{"title":"邻近斑块合并可减少空间冗余,加快视觉转换器的速度","authors":"Kai Jiang ,&nbsp;Peng Peng ,&nbsp;Youzao Lian ,&nbsp;Weihui Shao ,&nbsp;Weisheng Xu","doi":"10.1016/j.neucom.2024.128733","DOIUrl":null,"url":null,"abstract":"<div><div>Vision Transformers (ViTs) deliver outstanding performance but often require substantial computational resources. Various token pruning methods have been developed to enhance throughput by removing redundant tokens; however, these methods do not address the peak memory consumption, which remains equivalent to that of the unpruned networks. In this study, we introduce Neighbor Patches Merging (NEPAM), a method that significantly reduces the maximum memory footprint of ViTs while pruning tokens. NEPAM targets spatial redundancy within images and prunes redundant patches at the onset of the model, thereby achieving the optimal throughput-accuracy trade-off without fine-tuning. Experimental results demonstrate that NEPAM can accelerate the inference speed of the Vit-Base-Patch16-384 model by 25% with a negligible accuracy loss of <strong>0.07%</strong> and a notable <strong>18%</strong> reduction in memory usage. When applied to VideoMAE, NEPAM doubles the throughput with a <strong>0.29%</strong> accuracy loss and a <strong>48%</strong> reduction in memory usage. These findings underscore the efficacy of NEPAM in mitigating computational requirements while maintaining model performance.</div></div>","PeriodicalId":19268,"journal":{"name":"Neurocomputing","volume":null,"pages":null},"PeriodicalIF":5.5000,"publicationDate":"2024-10-19","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":"{\"title\":\"Neighbor patches merging reduces spatial redundancy to accelerate vision transformer\",\"authors\":\"Kai Jiang ,&nbsp;Peng Peng ,&nbsp;Youzao Lian ,&nbsp;Weihui Shao ,&nbsp;Weisheng Xu\",\"doi\":\"10.1016/j.neucom.2024.128733\",\"DOIUrl\":null,\"url\":null,\"abstract\":\"<div><div>Vision Transformers (ViTs) deliver outstanding performance but often require substantial computational resources. Various token pruning methods have been developed to enhance throughput by removing redundant tokens; however, these methods do not address the peak memory consumption, which remains equivalent to that of the unpruned networks. In this study, we introduce Neighbor Patches Merging (NEPAM), a method that significantly reduces the maximum memory footprint of ViTs while pruning tokens. NEPAM targets spatial redundancy within images and prunes redundant patches at the onset of the model, thereby achieving the optimal throughput-accuracy trade-off without fine-tuning. Experimental results demonstrate that NEPAM can accelerate the inference speed of the Vit-Base-Patch16-384 model by 25% with a negligible accuracy loss of <strong>0.07%</strong> and a notable <strong>18%</strong> reduction in memory usage. When applied to VideoMAE, NEPAM doubles the throughput with a <strong>0.29%</strong> accuracy loss and a <strong>48%</strong> reduction in memory usage. These findings underscore the efficacy of NEPAM in mitigating computational requirements while maintaining model performance.</div></div>\",\"PeriodicalId\":19268,\"journal\":{\"name\":\"Neurocomputing\",\"volume\":null,\"pages\":null},\"PeriodicalIF\":5.5000,\"publicationDate\":\"2024-10-19\",\"publicationTypes\":\"Journal Article\",\"fieldsOfStudy\":null,\"isOpenAccess\":false,\"openAccessPdf\":\"\",\"citationCount\":\"0\",\"resultStr\":null,\"platform\":\"Semanticscholar\",\"paperid\":null,\"PeriodicalName\":\"Neurocomputing\",\"FirstCategoryId\":\"94\",\"ListUrlMain\":\"https://www.sciencedirect.com/science/article/pii/S0925231224015042\",\"RegionNum\":2,\"RegionCategory\":\"计算机科学\",\"ArticlePicture\":[],\"TitleCN\":null,\"AbstractTextCN\":null,\"PMCID\":null,\"EPubDate\":\"\",\"PubModel\":\"\",\"JCR\":\"Q1\",\"JCRName\":\"COMPUTER SCIENCE, ARTIFICIAL INTELLIGENCE\",\"Score\":null,\"Total\":0}","platform":"Semanticscholar","paperid":null,"PeriodicalName":"Neurocomputing","FirstCategoryId":"94","ListUrlMain":"https://www.sciencedirect.com/science/article/pii/S0925231224015042","RegionNum":2,"RegionCategory":"计算机科学","ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q1","JCRName":"COMPUTER SCIENCE, ARTIFICIAL INTELLIGENCE","Score":null,"Total":0}
引用次数: 0

摘要

视觉变换器(ViT)性能卓越,但通常需要大量计算资源。目前已开发出多种标记剪枝方法,通过去除多余标记来提高吞吐量;然而,这些方法并不能解决内存消耗峰值问题,内存消耗峰值仍与未剪枝网络的内存消耗峰值相当。在本研究中,我们引入了邻接片合并(NEPAM)方法,这种方法在剪枝标记的同时,还能显著减少 ViTs 的最大内存占用。NEPAM 以图像内的空间冗余为目标,在模型开始时就修剪冗余补丁,从而在不进行微调的情况下实现吞吐量与准确度的最佳权衡。实验结果表明,NEPAM 可以将 Vit-Base-Patch16-384 模型的推理速度提高 25%,而精度损失仅为 0.07%,可以忽略不计,同时显著减少了 18% 的内存使用量。当应用于 VideoMAE 时,NEPAM 的吞吐量翻了一番,准确度损失为 0.29%,内存使用量减少了 48%。这些发现强调了 NEPAM 在保持模型性能的同时降低计算要求的功效。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
查看原文
分享 分享
微信好友 朋友圈 QQ好友 复制链接
本刊更多论文
Neighbor patches merging reduces spatial redundancy to accelerate vision transformer
Vision Transformers (ViTs) deliver outstanding performance but often require substantial computational resources. Various token pruning methods have been developed to enhance throughput by removing redundant tokens; however, these methods do not address the peak memory consumption, which remains equivalent to that of the unpruned networks. In this study, we introduce Neighbor Patches Merging (NEPAM), a method that significantly reduces the maximum memory footprint of ViTs while pruning tokens. NEPAM targets spatial redundancy within images and prunes redundant patches at the onset of the model, thereby achieving the optimal throughput-accuracy trade-off without fine-tuning. Experimental results demonstrate that NEPAM can accelerate the inference speed of the Vit-Base-Patch16-384 model by 25% with a negligible accuracy loss of 0.07% and a notable 18% reduction in memory usage. When applied to VideoMAE, NEPAM doubles the throughput with a 0.29% accuracy loss and a 48% reduction in memory usage. These findings underscore the efficacy of NEPAM in mitigating computational requirements while maintaining model performance.
求助全文
通过发布文献求助,成功后即可免费获取论文全文。 去求助
来源期刊
Neurocomputing
Neurocomputing 工程技术-计算机:人工智能
CiteScore
13.10
自引率
10.00%
发文量
1382
审稿时长
70 days
期刊介绍: Neurocomputing publishes articles describing recent fundamental contributions in the field of neurocomputing. Neurocomputing theory, practice and applications are the essential topics being covered.
期刊最新文献
An efficient re-parameterization feature pyramid network on YOLOv8 to the detection of steel surface defect Editorial Board Multi-contrast image clustering via multi-resolution augmentation and momentum-output queues Augmented ELBO regularization for enhanced clustering in variational autoencoders Learning from different perspectives for regret reduction in reinforcement learning: A free energy approach
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
现在去查看 取消
×
提示
确定
0
微信
客服QQ
Book学术公众号 扫码关注我们
反馈
×
意见反馈
请填写您的意见或建议
请填写您的手机或邮箱
已复制链接
已复制链接
快去分享给好友吧!
我知道了
×
扫码分享
扫码分享
Book学术官方微信
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术
文献互助 智能选刊 最新文献 互助须知 联系我们:info@booksci.cn
Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。
Copyright © 2023 Book学术 All rights reserved.
ghs 京公网安备 11010802042870号 京ICP备2023020795号-1