-
Notifications
You must be signed in to change notification settings - Fork 6k
Unable to load Flux LoRA trained with OneTrainer – NotImplementedError in _convert_mixture_state_dict_to_diffusers
#11441
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
Labels
bug
Something isn't working
Comments
Could you provide a full yet minimal reproducible snippet so that I could take a look? |
@sayakpaul Sorry for the delay, caught in the mayday holidays. Updated with the actual minimal reproduction example. |
iamwavecut
added a commit
to iamwavecut/diffusers
that referenced
this issue
May 3, 2025
…ORA conversion utility (huggingface#11441)
5 tasks
Thanks for #11487. Let me run some integration tests and get back to you there. |
iamwavecut
added a commit
to iamwavecut/diffusers
that referenced
this issue
May 6, 2025
…ORA conversion utility (huggingface#11441)
sayakpaul
added a commit
that referenced
this issue
May 6, 2025
…ORA conversion utility (#11441) (#11487) * [lora_conversion] Enhance key handling for OneTrainer components in LORA conversion utility (#11441) * Update src/diffusers/loaders/lora_conversion_utils.py Co-authored-by: Sayak Paul <[email protected]> --------- Co-authored-by: Sayak Paul <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Describe the bug
Loading a LoRA that was:
via
DiffusionPipeline.load_lora_weights()
(or indirectly through Nunchaku’s v0.2.0compose_lora
) crashes at application start-up with:The exception is thrown because the LoRA state-dict contains keys that start with
lora_transformer_single_transformer_blocks_…
, a pattern that the conversion helper does not yet handle.Here is the list of key types in state_dict of the mentioned LoRA (multiple digit prefixed keys collapsed to
%d
):Reproduction
Download the LoRA file first on Civitai.
The example assumes that the safetensors file is located in the current working directory.
Logs
System Info
diffusers@main as for April 28 2025
Who can help?
@sayakpaul I believe you've been involved in fixing OneTrainer LoRAs loading issues recently, would you be so kind to take your educated guess on this one.
The text was updated successfully, but these errors were encountered: