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

无需重新训练即可高精度剪枝基础模型

Pruning Foundation Models for High Accuracy without Retraining

Northeastern University(东北大学);Meta

Pu Zhao, Fei Sun, Xuan Shen, Pinrui Yu, Zhenglun Kong, Yanzhi Wang, Xue Lin

AI总结:

本文提出一种无需重新训练的训练后剪枝算法,通过形式化逐层LLM压缩问题并给出最优解,同时支持非结构化和半结构化稀疏性,在多种LLM家族上超越现有SOTA基线。

摘要:

尽管基础模型或大语言模型(LLMs)具有卓越的性能,但由于其庞大的参数量和计算量,部署它们极具挑战性。剪枝是一种有前景的技术,可以减小模型规模并加速推理,但传统的剪枝技术很难应用于LLMs,因为它们需要在完整数据集上对模型进行多轮微调,消耗大量的数据和硬件资源。为了解决这一问题,研究者提出了训练后剪枝方法,以一次性方式对LLMs进行剪枝而无需重新训练。然而,由于缺乏大规模数据的重新训练,剪枝后的精度可能会遭受一定的性能下降。为了解决这一问题,在本文中,我们首先将逐层LLM压缩的训练后问题形式化,以同时剪枝LLMs中的多个权重。接着,我们为该问题提供了最优解,并针对非结构化和半结构化稀疏性设计了我们的训练后剪枝算法。我们的大量实验表明,与SOTA基线相比,所提出的方法在各种LLM家族(包括基于Transformer的LLMs和基于Mamba的LLMs)上均表现出优越的性能。代码链接:https://github.com/piuzha/APT

英文摘要:

Despite the superior performance, it is challenging to deploy foundation models or large language models (LLMs) due to their massive parameters and computations. While pruning is a promising technique to reduce model size and accelerate the inference, the traditional pruning techniques can hardly be applied for LLMs as they need to finetune the model on the full dataset with multiple epochs consuming massive data and hardware resources. To deal with this problem, post-training pruning methods are proposed to prune LLMs in one-shot without retraining. However, their accuracy after pruning may suffer from certain performance degradation due to the lack of retraining with massive data. To address this issue, in this paper, we first formulate the post-training problem for layer-wise LLM compression to simultaneously prune multiple weights in LLMs. Next, we provide an optimal solution for this problem and design our post-training pruning algorithm for both unstructured and semi-structured sparsity. Our extensive experiments demonstrate the superior performance of the proposed methods in comparison to SOTA baselines across various LLM families including transformer-based LLMs and Mamba-based LLMs. Code link: https://github.com/piuzha/APT

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

↑