Outlier Weighed Layerwise Sparsity (OWL): A Missing Secret Sauce for Pruning LLMs to High Sparsity

Fuente: arXiv
Saved in:
Bibliographic Details
Main Authors: Yin, Lu, Wu, You, Zhang, Zhenyu, Hsieh, Cheng-Yu, Wang, Yaqing, Jia, Yiling, Li, Gen, Jaiswal, Ajay, Pechenizkiy, Mykola, Liang, Yi, Bendersky, Michael, Wang, Zhangyang, Liu, Shiwei
Format: Preprint
Published: 2023
Subjects:
Online Access:
Tags: Add Tag
No Tags, Be the first to tag this record!
_version_ 1866918076553887744
author Yin, Lu
Wu, You
Zhang, Zhenyu
Hsieh, Cheng-Yu
Wang, Yaqing
Jia, Yiling
Li, Gen
Jaiswal, Ajay
Pechenizkiy, Mykola
Liang, Yi
Bendersky, Michael
Wang, Zhangyang
Liu, Shiwei
author_facet Yin, Lu
Wu, You
Zhang, Zhenyu
Hsieh, Cheng-Yu
Wang, Yaqing
Jia, Yiling
Li, Gen
Jaiswal, Ajay
Pechenizkiy, Mykola
Liang, Yi
Bendersky, Michael
Wang, Zhangyang
Liu, Shiwei
contents Large Language Models (LLMs), renowned for their remarkable performance across diverse domains, present a challenge when it comes to practical deployment due to their colossal model size. In response to this challenge, efforts have been directed toward the application of traditional network pruning techniques to LLMs, uncovering a massive number of parameters that can be pruned in one-shot without hurting performance. Prevailing LLM pruning strategies have consistently adhered to the practice of uniformly pruning all layers at equivalent sparsity, resulting in robust performance. However, this observation stands in contrast to the prevailing trends observed in the field of vision models, where non-uniform layerwise sparsity typically yields stronger results. To understand the underlying reasons for this disparity, we conduct a comprehensive study and discover a strong correlation with the emergence of activation outliers in LLMs. Inspired by this finding, we introduce a novel LLM pruning methodology that incorporates a tailored set of non-uniform layerwise sparsity ratios, termed as Outlier Weighed Layerwise sparsity (OWL). The sparsity ratio of OWL is proportional to the outlier ratio observed within each layer, facilitating a more effective alignment between layerwise weight sparsity and outlier ratios. Our empirical evaluation, conducted across the LLaMA-V1 family and OPT, spanning various benchmarks, demonstrates the distinct advantages offered by OWL over previous methods. For instance, OWL exhibits a remarkable performance gain, surpassing the state-of-the-art Wanda and SparseGPT by 61.22 and 6.80 perplexity at a high sparsity level of 70%, respectively, while delivering 2.6x end-to-end inference speed-up in the DeepSparse inference engine. Codes are available at https://github.com/luuyin/OWL.
format Preprint
id arxiv_https___arxiv_org_abs_2310_05175
institution arXiv
publishDate 2023
record_format arxiv
spellingShingle Outlier Weighed Layerwise Sparsity (OWL): A Missing Secret Sauce for Pruning LLMs to High Sparsity
Yin, Lu
Wu, You
Zhang, Zhenyu
Hsieh, Cheng-Yu
Wang, Yaqing
Jia, Yiling
Li, Gen
Jaiswal, Ajay
Pechenizkiy, Mykola
Liang, Yi
Bendersky, Michael
Wang, Zhangyang
Liu, Shiwei
Machine Learning
Large Language Models (LLMs), renowned for their remarkable performance across diverse domains, present a challenge when it comes to practical deployment due to their colossal model size. In response to this challenge, efforts have been directed toward the application of traditional network pruning techniques to LLMs, uncovering a massive number of parameters that can be pruned in one-shot without hurting performance. Prevailing LLM pruning strategies have consistently adhered to the practice of uniformly pruning all layers at equivalent sparsity, resulting in robust performance. However, this observation stands in contrast to the prevailing trends observed in the field of vision models, where non-uniform layerwise sparsity typically yields stronger results. To understand the underlying reasons for this disparity, we conduct a comprehensive study and discover a strong correlation with the emergence of activation outliers in LLMs. Inspired by this finding, we introduce a novel LLM pruning methodology that incorporates a tailored set of non-uniform layerwise sparsity ratios, termed as Outlier Weighed Layerwise sparsity (OWL). The sparsity ratio of OWL is proportional to the outlier ratio observed within each layer, facilitating a more effective alignment between layerwise weight sparsity and outlier ratios. Our empirical evaluation, conducted across the LLaMA-V1 family and OPT, spanning various benchmarks, demonstrates the distinct advantages offered by OWL over previous methods. For instance, OWL exhibits a remarkable performance gain, surpassing the state-of-the-art Wanda and SparseGPT by 61.22 and 6.80 perplexity at a high sparsity level of 70%, respectively, while delivering 2.6x end-to-end inference speed-up in the DeepSparse inference engine. Codes are available at https://github.com/luuyin/OWL.
title Outlier Weighed Layerwise Sparsity (OWL): A Missing Secret Sauce for Pruning LLMs to High Sparsity
topic Machine Learning
url https://arxiv.org/abs/2310.05175