arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2507.08765cs.CVcs.AI
收藏

压缩任意 Segment Anything Model (SAM)

Compress Any Segment Anything Model (SAM)

Frontier of Artificial Networks (FAN) Lab, Department of Data Science, City University of Hong Kong(前沿人工智能网络实验室,数据科学系,香港城市大学);Data Storage Product Line, Huawei Technologies Co., Ltd.(数据存储产品线,华为技术有限公司);Lagrange Mathematics and Computing Research Center(拉格朗日数学与计算研究中心);School of Cyber Science and Engineering, Sichuan University(信息科学与工程学院,四川大学);Key Laboratory of Data Protection and Intelligent Management, Ministry of Education, Sichuan University(数据保护与智能管理重点实验室,教育部,四川大学);Department of Industrial and Systems Engineering, The Hong Kong Polytechnic University(工业与系统工程系,香港理工大学)

Juntong Fan, Zhiwei Hao, Jianqiang Shen, Shang-Ling Jui, Yi Zhang, Jing-Xiao Liao, Feng-Lei Fan

AI总结:

本文提出无数据压缩算法 Birkhoff,通过 Hyper-Compression 算法将高维参数向量转化为低维标量,并设计 HyperLinear 算子加速推理,在保持性能的同时实现了对 SAM 及其变体的高效快速压缩。

摘要:

由于在产生高质量、零样本分割方面的卓越性能,Segment Anything Model (SAM) 及其变体已被广泛应用于医疗和智能制造等多种场景。因此,有效压缩 SAM 已成为日益紧迫的实际需求。在本研究中,我们提出了 Birkhoff,一种用于 SAM 及其变体的新型无数据压缩算法。与量化、剪枝、蒸馏和其他压缩方法不同,Birkhoff 体现了跨模型类型的通用性、部署的敏捷性、对原始模型的忠实性以及模型尺寸的紧凑性。具体而言,Birkhoff 引入了一种新型压缩算法:Hyper-Compression,其核心原理是寻找一条密集轨迹,将高维参数向量转化为低维标量。此外,Birkhoff 设计了专用的线性层算子 HyperLinear,将解压与矩阵乘法融合,以显著加速压缩后 SAM 的推理。在 COCO、LVIS 和 SA-1B 数据集上对 18 个 SAM 进行的广泛实验表明,Birkhoff 在压缩时间、压缩率、压缩后性能和推理速度方面表现一致且具竞争力。例如,Birkhoff 能在 SAM2-B 上实现 5.17 倍的压缩率,在不使用任何微调数据的情况下性能下降不到 1%。此外,所有模型的压缩均在 60 秒内完成。

英文摘要:

Due to the excellent performance in yielding high-quality, zero-shot segmentation, Segment Anything Model (SAM) and its variants have been widely applied in diverse scenarios such as healthcare and intelligent manufacturing. Therefore, effectively compressing SAMs has become an increasingly pressing practical need. In this study, we propose Birkhoff, a novel data-free compression algorithm for SAM and its variants. Unlike quantization, pruning, distillation, and other compression methods, Birkhoff embodies versatility across model types, agility in deployment, faithfulness to the original model, and compactness in model size. Specifically, Birkhoff introduces a novel compression algorithm: Hyper-Compression, whose core principle is to find a dense trajectory to turn a high-dimensional parameter vector into a low-dimensional scalar. Furthermore, Birkhoff designs a dedicated linear layer operator, HyperLinear, to fuse decompression and matrix multiplication to significantly accelerate inference of the compressed SAMs. Extensive experiments on 18 SAMs in the COCO, LVIS, and SA-1B datasets show that Birkhoff performs consistently and competitively in compression time, compression ratio, post-compression performance, and inference speed. For example, Birkhoff can achieve a compression ratio of 5.17x on SAM2-B, with less than 1% performance drop without using any fine-tuning data. Moreover, the compression is finished within 60 seconds for all models.

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

↑