Skip to content

Conversation

@woct0rdho
Copy link

This kind of LoRAs come from NewBie LoRA trainer, and there is the prefix base_model.model. in their keys. This may also happen for other training scripts that directly export the LoRA from PEFT. The official NewBie/Lumina2/Z-Image models do not have this prefix, so I implemented the mapping.

An example of the LoRA is https://civitai.com/models/2201563

@silveroxides
Copy link
Contributor

@woct0rdho Checked the layer syntax for the LoRA. Never seen a syntax as that but judging from fused qkv and the Lora_A, Lora_B suffixes I think the easiest method rather than having ComfyUI adding even more naming to keep track of, is to request the NewBie trainer to use more conventional name for the layers. In this case it is the prefix base_model.model that would be replaced by diffusion_model. You can try this one with the model and see if it loads.

https://huggingface.co/silveroxides/HF-Upload-Test/blob/main/datou-comfy.safetensors

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

Successfully merging this pull request may close these issues.

2 participants