Skip to content

LoRA multi step training question #4006

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Bezdarnost opened this issue Apr 27, 2025 · 0 comments
Closed

LoRA multi step training question #4006

Bezdarnost opened this issue Apr 27, 2025 · 0 comments

Comments

@Bezdarnost
Copy link

Bezdarnost commented Apr 27, 2025

Hello, thank you very much for your incredible work!
I have a question regarding fine-tuning with LoRA.
If I fine-tune a LoRA and then perform a merge, and afterward start a new LoRA fine-tuning using this merged model as the base (instead of the original base model), like this:

swift sft \
    --model OpenGVLab/InternVL2_5-78B-MPO \
    --train_type lora \

and then like this:

swift sft \
    --model ./InternVL2_5-78B-MPO/checkpoint-xxxx-merged \
    --train_type lora \

what will happen to the previous LoRA?
(especially if the rank and alpha parameters are changed in the second stage)?
Will a new LoRA be created, or will the training somehow continue from the previous one?
Will the previous LoRA be erased?
(especially if no specific parameter for continuing training was set)

What should I do if I want to train a LoRA and then add another one on top of it?
Specifically: I want to first train one LoRA, and then, while keeping the first one applied, start a second fine-tuning on top of it, without losing the previous LoRA.
How should I properly set this up?

@Bezdarnost Bezdarnost changed the title LoRa multi step training question LoRA multi step training question Apr 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant