Add support to APOLLO - #6617
Merged
Merged
Conversation
hiyouga
self-requested a review
January 13, 2025 06:43
This was referenced Jan 30, 2025
This was referenced Feb 6, 2025
5 tasks
This was referenced Feb 9, 2025
This was referenced Feb 17, 2025
1587causalai
pushed a commit
to 1587causalai/llama_factory
that referenced
this pull request
Feb 18, 2025
This was referenced Feb 19, 2025
stephen-nju
pushed a commit
to stephen-nju/Llmtrain
that referenced
this pull request
Mar 24, 2025
Former-commit-id: d9189f9
yoonseok312
pushed a commit
to pensieve-ai/LLaMA-Factory-vlm
that referenced
this pull request
Apr 29, 2025
Former-commit-id: d9189f9
liu-qingyuan
pushed a commit
to liu-qingyuan/LLaMA-Factory-Megafake
that referenced
this pull request
Jun 6, 2025
Former-commit-id: d9189f9
xuguodong1999
pushed a commit
to xuguodong1999/LLaMA-Factory
that referenced
this pull request
May 5, 2026
Former-commit-id: 5a252e5a458457adbd19da3b68a3897ad2962824
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adding Support for APOLLO
This pull request introduces APOLLO, a memory-efficient optimizer tailored for pre-training large language models (LLMs) and full-parameter fine-tuning. APOLLO significantly reduces memory overhead compared to AdamW while maintaining comparable performance, making it ideal for LLM workflows.
Project page: APOLLO GitHub Repository
Features
Tests
We have added a test in the
examples/extras/apollodirectory. Additionally, we conducted a comparative evaluation with GaLore by fine-tuning models and testing on the MMLU task.GaLore Performance
APOLLO Performance (Scaling Factor = 32)
With a scaling factor derived from the ratio of LLaMA-8B dimension (4096) to rank (128):
Why APOLLO?
APOLLO offers a compelling alternative to existing optimizers, especially for large-scale LLM pre-training and fine-tuning. Its reduced memory footprint and simplicity (no SVD) make it a practical choice for researchers and engineers.