2023年5月10日水曜日

GoogleColab で StableDiffusionWebUI が起動するか試す

GoogleColab で StableDiffusionUI を起動するか試す

概要

StableDiffusionUI が無料の GoogleColaboratory 上で動作するか試してみました

環境

  • GoogleColab (2023/05/03 時点)
  • stable-diffusion-webui 1.1.0

リポジトリの clone

!git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui
%cd stable-diffusion-webui

実行

!COMMANDLINE_ARGS="--share --gradio-debug --gradio-auth me:qwerty" REQS_FILE="requirements.txt" python launch.py

実行ログ

Python 3.10.11 (main, Apr  5 2023, 14:15:10) [GCC 9.4.0]
Commit hash: 5ab7f213bec2f816f9c5644becb32eb72c8ffb89
Installing gfpgan
Installing clip
Installing open_clip
Cloning Stable Diffusion into /content/stable-diffusion-webui/repositories/stable-diffusion-stability-ai...
Cloning Taming Transformers into /content/stable-diffusion-webui/repositories/taming-transformers...
Cloning K-diffusion into /content/stable-diffusion-webui/repositories/k-diffusion...
Cloning CodeFormer into /content/stable-diffusion-webui/repositories/CodeFormer...
Cloning BLIP into /content/stable-diffusion-webui/repositories/BLIP...
Installing requirements for CodeFormer
Installing requirements
Launching Web UI with arguments: --share --gradio-debug --gradio-auth me:qwerty
2023-05-03 07:06:08.915792: I tensorflow/core/platform/cpu_feature_guard.cc:182] This TensorFlow binary is optimized to use available CPU instructions in performance-critical operations.
To enable the following instructions: AVX2 AVX512F FMA, in other operations, rebuild TensorFlow with the appropriate compiler flags.
2023-05-03 07:06:09.904251: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT
No module 'xformers'. Proceeding without it.
Downloading: "https://huggingface.co/runwayml/stable-diffusion-v1-5/resolve/main/v1-5-pruned-emaonly.safetensors" to /content/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors

100% 3.97G/3.97G [00:23<00:00, 180MB/s]
Calculating sha256 for /content/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors: 6ce0161689b3853acaa03779ec93eafe75a02f4ced659bee03f50797806fa2fa
Loading weights [6ce0161689] from /content/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors
Creating model from config: /content/stable-diffusion-webui/configs/v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Downloading (…)olve/main/vocab.json: 100% 961k/961k [00:00<00:00, 11.8MB/s]
Downloading (…)olve/main/merges.txt: 100% 525k/525k [00:00<00:00, 3.19MB/s]
Downloading (…)cial_tokens_map.json: 100% 389/389 [00:00<00:00, 2.52MB/s]
Downloading (…)okenizer_config.json: 100% 905/905 [00:00<00:00, 5.12MB/s]
Downloading (…)lve/main/config.json: 100% 4.52k/4.52k [00:00<00:00, 21.7MB/s]
Applying cross attention optimization (Doggettx).
Textual inversion embeddings loaded(0): 
Model loaded in 30.9s (calculate hash: 14.0s, load weights from disk: 0.3s, create model: 2.3s, apply weights to model: 4.4s, apply half(): 1.4s, load VAE: 7.9s, move model to device: 0.6s).
Running on local URL:  http://127.0.0.1:7860
Running on public URL: https://xxx.gradio.live

This share link expires in 72 hours. For free permanent hosting and GPU upgrades (NEW!), check out Spaces: https://huggingface.co/spaces

結果

普通に起動しました

メモリ不足で起動しない場合は StableDiffusionUI-Voldemort V1.3.ipynb ではなく素の stable-diffusion-webui から起動するといいかもしれません

参考サイト

0 件のコメント:

コメントを投稿