Two Sparse Matrices are Better than One: Sparsifying Neural Networks with Double Sparse Factorization

要約

ニューラル ネットワークは、サイズが大きく複雑であるため、操作が困難なことがよくあります。
これに対処するために、さまざまな方法は、マグニチュード枝刈りや低ランクまたはブロック対角分解など、重み行列をスパース化または分解することによってモデル サイズを削減することを目的としています。
この研究では、各重み行列を 2 つのスパース行列に因数分解する Double Sparse Factorization (DSF) を紹介します。
この問題を正確に解決することは計算上不可能ですが、ADMM による交互最小化に基づく効率的なヒューリスティックを提案します。これにより、最先端の結果が得られ、前例のないニューラル ネットワークのスパース化が可能になります。
たとえば、ワンショット プルーニング設定では、私たちの方法は、高密度 LLaMA2-7B モデルよりも優れたパフォーマンスを維持しながら、LLaMA2-13B モデルのサイズを 50% 削減できます。
また、畳み込みニューラル ネットワーク向けの最先端の層ごとの枝刈りアプローチである Optimal Brain Compression とも良好に比較できます。
さらに、モデルをさらに微調整した後でも、私たちの方法の精度の向上は持続します。
コードは https://github.com/usamec/double_sparse で入手できます。

要約(オリジナル)

Neural networks are often challenging to work with due to their large size and complexity. To address this, various methods aim to reduce model size by sparsifying or decomposing weight matrices, such as magnitude pruning and low-rank or block-diagonal factorization. In this work, we present Double Sparse Factorization (DSF), where we factorize each weight matrix into two sparse matrices. Although solving this problem exactly is computationally infeasible, we propose an efficient heuristic based on alternating minimization via ADMM that achieves state-of-the-art results, enabling unprecedented sparsification of neural networks. For instance, in a one-shot pruning setting, our method can reduce the size of the LLaMA2-13B model by 50% while maintaining better performance than the dense LLaMA2-7B model. We also compare favorably with Optimal Brain Compression, the state-of-the-art layer-wise pruning approach for convolutional neural networks. Furthermore, accuracy improvements of our method persist even after further model fine-tuning. Code available at: https://github.com/usamec/double_sparse.

arxiv情報

著者 Vladimír Boža,Vladimír Macko
発行日 2024-09-27 15:48:39+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.LG パーマリンク