Fixing Kohya loras loading: Flux.1-dev loras with TE ("lora_te1_" prefix)#13188
Merged
sayakpaul merged 2 commits intohuggingface:mainfrom Feb 27, 2026
Merged
Fixing Kohya loras loading: Flux.1-dev loras with TE ("lora_te1_" prefix)#13188sayakpaul merged 2 commits intohuggingface:mainfrom
sayakpaul merged 2 commits intohuggingface:mainfrom
Conversation
sayakpaul
approved these changes
Feb 27, 2026
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
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.
Text encoder lora layers are dropped for some loras such as this one
A log message confirms it:
No LoRA keys associated to CLIPTextModel found with the prefix='text_encoder'. This is safe to ignore if LoRA state dict didn't originally have any CLIPTextModel related params. You can also try specifying prefix=None to resolve the warning. Otherwise, open an issue if you think it's unexpected: https://github.com/huggingface/diffusers/issues/newAt least, this PR brings more consistency (wherever there is lora_te_, there should be also lora_te1_)
Closes #12053
Reproducers:
FLUX.1 Dev
FLUX.1 Kontext
The Loras have been trained with Kohya/sd-scripts framework.
With the fix of this PR, the warning message disappears, solving the drop of layers for the text encoder.
@sayakpaul