Frustratingly Simple Memory Efficiency for Pre-trained Language Models via Dynamic Embedding Pruning
Abstract
The extensive memory footprint of pre-trained language models (PLMs) can hinder deployment in memory-constrained settings, such as cloud environments or on-device. PLMs use embedding matrices to represent extensive vocabularies, forming a large proportion of the model parameters. While previous work towards parameter-efficient PLM development has considered pruning parameters within the transformer layers, pruning the embedding matrix as part of fine-tuning or inference has yet to be explored. We first demonstrate that a significant proportion of the vocabulary remains unused in these scenarios. We then propose a simple yet effective approach that leverages this finding to minimize the memory footprint of the embedding matrix. We show that this approach provides substantial reductions in memory usage across a wide range of models and tasks. Notably, our approach maintains equivalent downstream task performance while allowing a more efficient use of compute resources.
Community
This is an automated message from the Librarian Bot. I found the following papers similar to this paper.
The following papers were recommended by the Semantic Scholar API
- Structural Pruning of Pre-trained Language Models via Neural Architecture Search (2024)
- DoRA: Enhancing Parameter-Efficient Fine-Tuning with Dynamic Rank Distribution (2024)
- SKIP: Skill-Localized Prompt Tuning for Inference Speed Boost-Up (2024)
- SPAFIT: Stratified Progressive Adaptation Fine-tuning for Pre-trained Large Language Models (2024)
- XC-Cache: Cross-Attending to Cached Context for Efficient LLM Inference (2024)
Please give a thumbs up to this comment if you found it helpful!
If you want recommendations for any Paper on Hugging Face checkout this Space
You can directly ask Librarian Bot for paper recommendations by tagging it in a comment:
@librarian-bot
recommend
Models citing this paper 0
No model linking this paper
Datasets citing this paper 0
No dataset linking this paper
Spaces citing this paper 0
No Space linking this paper