AUTOMATIC1111 / stable-diffusion-webui

Stable Diffusion web UI
GNU Affero General Public License v3.0
141.58k stars 26.75k forks source link

[Bug]: can't load a symbolic link subfolder in models\Stable-diffusion #10405

Closed NeutronStarT closed 1 year ago

NeutronStarT commented 1 year ago

Is there an existing issue for this?

What happened?

Because the disk space required to store the models is huge, I put them into a folder on another disk, and created a symbolic link under models\Stable-diffusion to point to this folder. Before v1.2.0, these models can be read normally, but starting from v1.2.0, these models cannot be read anymore. WUGYNH601(J$((22B1CJ3DP QQ图片20230515180204 QQ图片20230515180231

Steps to reproduce the problem

  1. create a symbolic link folder under models\Stable-diffusion
  2. open webui
  3. browse top left corner 'Stable Diffusion checkpoint'

What should have happened?

models in symbolic link folder under models\Stable-diffusion should be showen

Commit where the problem happens

89f9faa (v1.2.1) and b08500c (v1.2.0)

What platforms do you use to access the UI ?

Windows

What browsers do you use to access the UI ?

Google Chrome

Command Line Arguments

No

List of extensions

DreamArtist-sd-webui-extension | https://github.com/7eu7d7/DreamArtist-sd-webui-extension.git | 12f80775 (Mon Apr 24 05:53:26 2023) | unknown SD-latent-mirroring | https://github.com/dfaker/SD-latent-mirroring | 05df9e83 (Sat Mar 25 14:37:33 2023) | unknown a1111-sd-webui-lycoris | https://github.com/KohakuBlueleaf/a1111-sd-webui-lycoris.git | 1f3e452c (Tue May 9 12:30:54 2023) | unknown a1111-sd-webui-tagcomplete | https://github.com/DominikDoom/a1111-sd-webui-tagcomplete | cc67adf8 (Tue May 9 12:42:32 2023) | unknown novelai-2-local-prompt | https://github.com/animerl/novelai-2-local-prompt | 0e03ca1a (Sat Jan 28 06:33:03 2023) | unknown openpose-editor | https://github.com/fkunn1326/openpose-editor.git | d74fdd72 (Tue May 2 09:49:03 2023) | unknown sd-webui-3d-open-pose-editor | https://github.com/nonnonstop/sd-webui-3d-open-pose-editor.git | f2d5aac5 (Sat Apr 15 13:21:06 2023) | unknown sd-webui-additional-networks | https://github.com/kohya-ss/sd-webui-additional-networks.git | c6006f8e (Mon May 8 13:05:50 2023) | unknown sd-webui-controlnet | https://github.com/Mikubill/sd-webui-controlnet.git | c9c8ca6e (Sun May 7 17:15:00 2023) | unknown sd-webui-infinite-image-browsing | https://github.com/zanllp/sd-webui-infinite-image-browsing.git | 5c1b630d (Wed May 10 12:24:24 2023) | unknown sd-webui-lora-block-weight | https://github.com/hako-mikan/sd-webui-lora-block-weight.git | 61f895dc (Fri May 12 12:04:33 2023) | unknown stable-diffusion-webui-daam | https://github.com/kousw/stable-diffusion-webui-daam.git | 796acea1 (Sun Dec 18 13:36:12 2022) | unknown stable-diffusion-webui-images-browser | https://github.com/AlUlkesh/stable-diffusion-webui-images-browser.git | 7da8aec6 (Thu May 11 05:53:55 2023) | unknown stable-diffusion-webui-randomize | https://github.com/innightwolfsleep/stable-diffusion-webui-randomize.git | c04c7611 (Tue Jan 31 14:54:33 2023) | unknown stable-diffusion-webui-sonar | https://github.com/Kahsolt/stable-diffusion-webui-sonar.git | e9e16c99 (Tue May 9 05:50:47 2023) | unknown stable-diffusion-webui-tokenizer | https://github.com/AUTOMATIC1111/stable-diffusion-webui-tokenizer.git | ac6d541c (Sat Dec 10 12:58:31 2022) | unknown stable-diffusion-webui-wd14-tagger | https://github.com/toriato/stable-diffusion-webui-wd14-tagger.git | 3ba3a735 (Sat Mar 25 20:32:37 2023) | unknown LDSR | built-in |   |   Lora | built-in |   |   ScuNET | built-in |   |   SwinIR | built-in |   |   prompt-bracket-checker | built-in

Console logs

venv "C:\DEV_FAST\Novel\stable-diffusion-webui\venv\Scripts\Python.exe"
Python 3.10.7 (tags/v3.10.7:6cc6b13, Sep  5 2022, 14:08:36) [MSC v.1933 64 bit (AMD64)]
Version: v1.2.1
Commit hash: 89f9faa63388756314e8a1d96cf86bf5e0663045
Installing requirements
Installing requirements for scikit_learn

Launching Web UI with arguments:
No module 'xformers'. Proceeding without it.
[AddNet] Updating model hashes...
100%|███████████████████████████████████████████████████████████████████████████████| 72/72 [00:00<00:00, 73782.04it/s]
[AddNet] Updating model hashes...
100%|███████████████████████████████████████████████████████████████████████████████| 72/72 [00:00<00:00, 36891.02it/s]
ControlNet v1.1.150
ControlNet v1.1.150
Image Browser: ImageReward is not installed, cannot be used.
Checkpoint D\clam_v11Sfw.ckpt [0c3e69ecb6] not found; loading fallback 0.3(D_clam_v11Sfw) + 0.7(D_N3E).ckpt [70fc780a31]
Loading weights [70fc780a31] from C:\DEV_FAST\Novel\stable-diffusion-webui\models\Stable-diffusion\0.3(D_clam_v11Sfw) + 0.7(D_N3E).ckpt
Creating model from config: C:\DEV_FAST\Novel\stable-diffusion-webui\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Loading VAE weights specified in settings: C:\DEV_FAST\Novel\stable-diffusion-webui\models\VAE\animefull-latest.vae.pt
Running on local URL:  http://127.0.0.1:7860

To create a public link, set `share=True` in `launch()`.
Startup time: 14.6s (import torch: 3.3s, import gradio: 0.8s, import ldm: 0.4s, other imports: 0.9s, load scripts: 2.9s, create ui: 6.1s, gradio launch: 0.2s).
Applying cross attention optimization (Doggettx).
Textual inversion embeddings loaded(168): _ignored
Model loaded in 7.3s (load weights from disk: 2.2s, create model: 0.4s, apply weights to model: 1.0s, apply half(): 0.9s, load VAE: 0.8s, move model to device: 1.1s, load textual inversion embeddings: 0.9s).
Loading weights [cf89c41509] from C:\DEV_FAST\Novel\stable-diffusion-webui\models\Stable-diffusion\0.9(0.3(D_clam_v11Sfw) + 0.7(D_N3E)) + 0.1(D_atd_3000).ckpt
Loading VAE weights specified in settings: C:\DEV_FAST\Novel\stable-diffusion-webui\models\VAE\animefull-latest.vae.pt
Applying cross attention optimization (Doggettx).
Weights loaded in 4.4s (load weights from disk: 2.7s, apply weights to model: 0.4s, load VAE: 0.5s, move model to device: 0.7s).
Loading weights [70fc780a31] from C:\DEV_FAST\Novel\stable-diffusion-webui\models\Stable-diffusion\0.3(D_clam_v11Sfw) + 0.7(D_N3E).ckpt
Loading VAE weights specified in settings: C:\DEV_FAST\Novel\stable-diffusion-webui\models\VAE\animefull-latest.vae.pt
Applying cross attention optimization (Doggettx).
Weights loaded in 3.0s (load weights from disk: 1.4s, apply weights to model: 0.5s, load VAE: 0.5s, move model to device: 0.6s).
Loading weights [cf89c41509] from C:\DEV_FAST\Novel\stable-diffusion-webui\models\Stable-diffusion\0.9(0.3(D_clam_v11Sfw) + 0.7(D_N3E)) + 0.1(D_atd_3000).ckpt
Loading VAE weights specified in settings: C:\DEV_FAST\Novel\stable-diffusion-webui\models\VAE\animefull-latest.vae.pt
Applying cross attention optimization (Doggettx).
Weights loaded in 3.1s (load weights from disk: 1.4s, apply weights to model: 0.5s, load VAE: 0.5s, move model to device: 0.7s).

Additional information

No response

JeremyDF93 commented 1 year ago

This is fixed in the dev branch cb3f8ff

Kadah commented 1 year ago

Duplicate of https://github.com/AUTOMATIC1111/stable-diffusion-webui/issues/10346 and some others.

pjpmccarthy52 commented 1 year ago

I'm running an Apple M1 and have had success relocating models using the command line option: --ckpt-dir /Volumes/Raid5/sd-models/

I was previously using a link. This seems cleaner.

akx commented 1 year ago

10286 is in master (version 1.3.0), so this should be fixed now.