invoke-ai / InvokeAI

Invoke is a leading creative engine for Stable Diffusion models, empowering professionals, artists, and enthusiasts to generate and create visual media using the latest AI-driven technologies. The solution offers an industry leading WebUI, and serves as the foundation for multiple commercial products.
https://invoke-ai.github.io/InvokeAI/
Apache License 2.0
23.77k stars 2.44k forks source link

[bug]: Certain FLUX LoRAs don't install #7131

Open SencneS opened 1 month ago

SencneS commented 1 month ago

Is there an existing issue for this problem?

Operating system

Windows

GPU vendor

Nvidia (CUDA)

GPU model

No response

GPU VRAM

No response

Version number

5.0.1

Browser

Chrome Version 129.0.6668.100 (Official Build) (64-bit)

Python dependencies

No response

What happened

All of a sudden some LoRa's just stopped being able to be installed.

[2024-10-16 15:47:52,892]::[ModelInstallService]::ERROR --> Model install error: Z:/AI-Models/Art-Models/Loras/Flux.1 D/Style-SFW/style/EnvyFluxDarkToon01.safetensors InvalidModelConfigException: Unable to determine model type for Z:\AI-Models\Art-Models\Loras\Flux.1 D\Style-SFW\style\EnvyFluxDarkToon01.safetensors

Given that Envy's LoRa were working, and then they stopped I reached out to Envy and asked if they changed something recently. They mentioned that they started making DoRa's in "OneTrainer" Just to be clear the non-flux "LoRas" and "DoRa" from the creator work just fine in Invoke, but the Flux version does not. Again it's only something recent, and not the older ones. (Older by literally 2 weeks), any LoRa they had created after Oct 1st for FLUX appears to have this issue.

They have informed me that they have done nothing different. Just that they started creating DoRa's in OneTrainer.

List of FLUX LoRas that are having the issue - -EnvyFluxDarkWatercolor01.safetensors -EnvyFluxMoonlightFusion01.safetensors -EnvyFluxThickOilPainting01a.safetensors -EnvyFluxSakuraSunset01.safetensors -EnvyFlux3Cute5U01b.safetensors -EnvyFluxDarkToon01.safetensors -EnvyFluxThickOilPainting01c.safetensors -EnvyFluxAnimeFusion01.safetensors -EnvyFluxPunkGirls01.safetensors -EnvyFluxDigitalBrush01.safetensors -EnvyFlux70sScifi01.safetensors -EnvyFluxThickOilPainting01b.safetensors -EnvyFluxAnimeSketch01.safetensors -EnvyFluxDreamtown01.safetensors -EnvyFluxThickOilPainting01d.safetensors -EnvyFlux3Cute5U01a.safetensors

All their other FLUX LoRa's as of today (Oct 16th) work just fine.

What you expected to happen

It should have installed and used the FLUX LoRa

How to reproduce the problem

No response

Additional context

No response

Discord username

No response

psychedelicious commented 1 month ago

Can you please provide a couple links to the specific versions of the LoRAs that don't work?

SencneS commented 1 month ago

Can you please provide a couple links to the specific versions of the LoRAs that don't work?

Certainly! I'll give you three of the non-loading ones and three of the loading and working ones.

Non-working LoRas https://civitai.com/models/838594/envy-flux-dreamtown-01?modelVersionId=938205 https://civitai.com/models/836757/envy-flux-digital-brush-01?modelVersionId=936167 https://civitai.com/models/844821/envy-flux-dark-watercolor-01?modelVersionId=945159

Working LoRas https://civitai.com/models/669112/envy-flux-dreamlands-01?modelVersionId=749041 https://civitai.com/models/663056/envy-flux-classic-02?modelVersionId=743101 https://civitai.com/models/653947/envy-flux-dark-sketch-01-creepy-anime-color-ink-sketches?modelVersionId=731613

psychedelicious commented 1 month ago

Thanks!

rikublock commented 1 month ago

Here is another one that doesn't install currently:

SencneS commented 1 month ago

OK So Envy got a pinch more info for me. They said "Those are DoRa's but I must have labeled them LoRa's out of habbit..." So maybe because it's labeled a LoRa, but is really coded as a DoRa Invoke is having a problem understanding? I only say that because other DoRa's for non-flux models load just fine in Invoke. But those are specifically tagged as DoRa. Maybe? I am not a coder by any means, just trying to follow some logic here.

freshlesh3 commented 2 weeks ago

OK So Envy got a pinch more info for me. They said "Those are DoRa's but I must have labeled them LoRa's out of habbit..." So maybe because it's labeled a LoRa, but is really coded as a DoRa Invoke is having a problem understanding? I only say that because other DoRa's for non-flux models load just fine in Invoke. But those are specifically tagged as DoRa. Maybe? I am not a coder by any means, just trying to follow some logic here.

Thanks for the insight but what is a Dora? And how can we check what they are labeled, and relabel them if necessary?

SencneS commented 2 weeks ago

Thanks for the insight but what is a Dora? And how can we check what they are labeled, and relabel them if necessary?

From what I've read, DoRA is a faster model than LoRA. How can you know if a DoRA has been tagged a LoRA? I have no idea, the creator needs to make certain to tag the metadata DoRA... Because if they tag it LoRA it appears Invoke doesn't like it. That said, A1111, ComfyUI, and Foooocus don't seem to have this problem. This is distinctively a InvokeAI issue.

If I had to guess, having the file tagged LoRA but is really configured to be a DoRA, Invoke probably has a specific loading protocol to read just LoRA formatting. The other programs might have taken a more 'dumbed down' approach, you feed it a file and it determines what it is based on the file structure. It's slower doing it this way, but more flexible for dummies that mis-tag their file structure :) But I am not a coder so I'm just throwing stuff out there.

DzikiREX commented 1 week ago

As suggested by the admins on the discord channel, I'm reporting here LORA styles for Flux that don't work. The same styles work perfectly well with FLUX in Swartm UI, so everything is fine with them. None of these styles want to install in Invoke.

https://civitai.com/models/643886/flux-faetastic-details?modelVersionId=720252 https://civitai.com/models/580857/realistic-skin-texture-style-xl-detailed-skin-sd15-flux1d https://civitai.com/models/631986/xlabs-flux-realism-lora https://civitai.com/models/178215?modelVersionId=734230 https://civitai.com/models/636355/flux-detailer https://civitai.com/models/776375/chrome-texture-flux-paseer

Here is one exception and a slightly different case. A style that theoretically installs, but then throws an error when you try to use it. https://civitai.com/models/643395/latexskinnsfw-flux-paseer