vladmandic / automatic

SD.Next: Advanced Implementation of Stable Diffusion and other Diffusion-based generative image models
https://github.com/vladmandic/automatic
GNU Affero General Public License v3.0
5.36k stars 382 forks source link

[Issue]: Launching hangs when loading models and LORA (JSONDecodeError?) #1412

Closed r0buster closed 1 year ago

r0buster commented 1 year ago

Issue Description

As the title says, after todays commit I cannot get the launch to finish.

2023-06-13 16:04:34,978 | sd | DEBUG | launch | Setup complete without errors: 1686665075 2023-06-13 16:04:34,983 | sd | INFO | installer | Extension preload: 0.0s C:\Apps\AI\automatic\extensions-builtin 2023-06-13 16:04:34,984 | sd | INFO | installer | Extension preload: 0.0s C:\Apps\AI\automatic\extensions 2023-06-13 16:04:34,998 | sd | INFO | launch | Server arguments: ['--upgrade'] 2023-06-13 16:04:40,467 | sd | INFO | webui | Libraries loaded 2023-06-13 16:04:40,470 | sd | INFO | webui | Using data path: C:\Apps\AI\automatic 2023-06-13 16:04:40,479 | sd | INFO | sd_vae | Available VAEs: C:\Apps\AI\automatic\models\VAE 5 2023-06-13 16:04:40,591 | sd | INFO | sd_models | Available models: C:\Apps\AI\automatic\models\Stable-diffusion 48

In the commit before this one, I got many errors like this in the sdnext.log. It might have to do with the way I sort my models, with spaces.

2023-06-13 13:26:25,123 | sd | ERROR | errors | reading lora C:\Apps\AI\automatic\models\Lora\9 Untested\toradora_v10.safetensors: JSONDecodeError

Version Platform Description

16:03:45-715956 INFO Python 3.10.11 on Windows 16:03:45-756514 INFO Version: 0d101b9d Tue Jun 13 15:36:41 2023 +0300 16:03:46-121668 INFO nVidia CUDA toolkit detected 16:03:47-400597 INFO Torch 2.0.0+cu118 16:03:47-420730 INFO Torch backend: nVidia CUDA 11.8 cuDNN 8700 16:03:47-421731 INFO Torch detected GPU: NVIDIA GeForce RTX 3080 VRAM 10240 Arch (8, 6) Cores 68

Acknowledgements

vladmandic commented 1 year ago

i've downloaded https://civitai.com/models/32794/toradora and it seems that lora really does not have a valid metadata segment. i have no idea how that lora was created/trained, it wasn't using any normal tools. i've tried one other lora from the same author and that one does have a valid metadata, so there is something wrong with this specific one. all-in-all, it seems like a valid error trying to load metadata, but it should not prevent rest of application to function at all, its just that particular metadata could not be loaded.