arXiv:2410.07461cs.CL2024-10EMNLP被引 23

选对校准数据能让大模型剪枝更高效,不一定非得用C4。

Is C4 Dataset Optimal for Pruning? An Investigation of Calibration Data for LLM Pruning

  • 用不同数据集做剪枝校准,发现C4并非最佳选择。
  • 算术类数据表现堪比预训练数据,甚至更好。
  • 下游数据未必提升对应任务效果,ICL普遍有用。

网络剪枝是降低大模型部署成本的潜在方案,但现有方法均依赖C4数据集作为剪枝评分的校准数据,其最优性未被探究。本研究评估了多种常见预训练与下游任务数据集作为校准数据的效果,涵盖四类相关数据及三类下游任务中的九个数据集,每个数据集分别采用上下文学习(ICL)和思维链(CoT)提示。结果表明:(1)C4并非最优校准数据,即使在常用预训练数据中亦然;(2)算术类数据作为校准数据时表现与预训练数据相当甚至更优;(3)使用下游数据进行剪枝,并不必然提升对应任务性能;(4)ICL对所有数据类别均有益,而CoT仅在特定任务上有用。研究强调了校准数据选择的重要性,为大模型高效部署提供新思路。代码已开源:https://github.com/abx393/llm-pruning-calibration-data。

原文摘要 · Abstract (English)

Network pruning has emerged as a potential solution to make LLMs cheaper to deploy. However, existing LLM pruning approaches universally rely on the C4 dataset as the calibration data for calculating pruning scores, leaving its optimality unexplored. In this study, we evaluate the choice of calibration data on LLM pruning, across a wide range of datasets that are most commonly used in LLM training and evaluation, including four pertaining datasets as well as three categories of downstream tasks encompassing nine datasets. Each downstream dataset is prompted with In-Context Learning (ICL) and Chain-of-Thought (CoT), respectively. Besides the already intriguing observation that the choice of calibration data significantly impacts the performance of pruned LLMs, our results also uncover several subtle and often unexpected findings, summarized as follows: (1) C4 is not the optimal choice for LLM pruning, even among commonly used pre-training datasets; (2) arithmetic datasets, when used as calibration data, performs on par or even better than pre-training datasets; (3) pruning with downstream datasets does not necessarily help the corresponding downstream task, compared to pre-training data; (4) ICL is widely beneficial to all data categories, whereas CoT is only useful on certain tasks. Our findings shed light on the importance of carefully selecting calibration data for LLM pruning and pave the way for more efficient deployment of these powerful models in real-world applications. We release our code at: https://github.com/abx393/llm-pruning-calibration-data.

大模型剪枝校准数据LLM部署算术数据

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。