LoRA-Pro: Are Low-Rank Adapters Properly Optimized?

Zhengbo Wang, Jian Liang, Ran He, Zilei Wang, Tieniu Tan
7/25/2024
cs.LGcs.AIcs.CL

Official code: mrflogs/LoRA-Pro (150 stars, MIT, last commit 2025-04-08).

Abstract

Low-rank adaptation, also known as LoRA, has emerged as a prominent method for parameter-efficient fine-tuning of foundation models. Despite its computational efficiency, LoRA still yields inferior performance compared to full fine-tuning. In this paper, we first uncover a fundamental connection between the optimization processes of LoRA and full fine-tuning: using LoRA for optimization is mathematically equivalent to full fine-tuning using a low-rank gradient for parameter updates. And this low-rank gradient can be expressed in terms of the gradients of the two low-rank matrices in LoRA. Leveraging this insight, we introduce LoRA-Pro, a method that enhances LoRA's performance by strategically adjusting the gradients of these low-rank matrices. This adjustment allows the low-rank gradient to more accurately approximate the full fine-tuning gradient, thereby narrowing the performance gap between LoRA and full fine-tuning. Furthermore, we theoretically derive the optimal solutions for adjusting the gradients of the low-rank matrices, applying them during fine-tuning in LoRA-Pro. We conduct extensive experiments across natural language understanding, dialogue generation, mathematical reasoning, code generation, and image classification tasks, demonstrating that LoRA-Pro substantially improves LoRA's performance, effectively narrowing the gap with full fine-tuning. Code is publicly available at https://github.com/mrflogs/LoRA-Pro.

View on arXivView PDF

Code Implementations(1)

mrflogs/LoRA-ProOfficial100%
MIT

Official code for our paper, "LoRA-Pro: Are Low-Rank Adapters Properly Optimized? "

1508C, C++Jul 26, 20241 years agoMIT

Similar Papers

Cite this paper

@article{wang2024lorapro,
  title  = {LoRA-Pro: Are Low-Rank Adapters Properly Optimized?},
  author = {Zhengbo Wang and Jian Liang and Ran He and Zilei Wang and Tieniu Tan},
  year   = {2024},
  eprint = {2407.18242},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2407.18242v3},
  journal = {ICLR 2024 2024}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2407.18242.svg)](https://codeofpaper.com/paper/2407.18242)

Discussion