Stable Diffusion : Install2023/08/11 |
Install [Stable Diffusion] that is the Text-to-Image model of deep learning. |
|
[1] |
Install NVIDIA Graphic Driver for your Graphic Card, refer to here. |
[2] | |
[3] | Install other required packages. |
[root@dlp ~]# dnf -y install python3-pip git
|
[4] | Install and run [Stable Diffusion] with any user. |
[cent@dlp ~]$ nvidia-smi Fri Aug 11 17:06:23 2023 +---------------------------------------------------------------------------------------+ | NVIDIA-SMI 535.86.10 Driver Version: 535.86.10 CUDA Version: 12.2 | |-----------------------------------------+----------------------+----------------------+ | GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC | | Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. | | | | MIG M. | |=========================================+======================+======================| | 0 NVIDIA GeForce GTX 1060 6GB Off | 00000000:05:00.0 Off | N/A | | 0% 53C P5 18W / 120W | 0MiB / 6144MiB | 0% Default | | | | N/A | +-----------------------------------------+----------------------+----------------------+ +---------------------------------------------------------------------------------------+ | Processes: | | GPU GI CI PID Type Process name GPU Memory | | ID ID Usage | |=======================================================================================| | No running processes found | +---------------------------------------------------------------------------------------+[cent@dlp ~]$ nvcc --version nvcc: NVIDIA (R) Cuda compiler driver Copyright (c) 2005-2022 NVIDIA Corporation Built on Wed_Jun__8_16:49:14_PDT_2022 Cuda compilation tools, release 11.7, V11.7.99 Build cuda_11.7.r11.7/compiler.31442593_0[cent@dlp ~]$ git clone https://github.com/AUTOMATIC1111/stable-diffusion-webui Cloning into 'stable-diffusion-webui'... remote: Enumerating objects: 25475, done. remote: Counting objects: 100% (1028/1028), done. remote: Compressing objects: 100% (518/518), done. remote: Total 25475 (delta 682), reused 787 (delta 499), pack-reused 24447 Receiving objects: 100% (25475/25475), 31.58 MiB | 11.85 MiB/s, done. Resolving deltas: 100% (17802/17802), done.
[cent@dlp ~]$
cd stable-diffusion-webui
# lowvram ⇒ add it if your Graphic Card has few amount of memory # xformers ⇒ use library for performance improvement # listen ⇒ listen on 0.0.0.0 # - if not specify the option, listen on 127.0.0.1 [cent@dlp stable-diffusion-webui]$ python3 launch.py --lowvram --xformers --listen Python 3.9.17 (main, Jun 26 2023, 00:00:00) [GCC 11.4.1 20230605 (Red Hat 11.4.1-2)] Version: v1.5.1 Commit hash: 68f336bd994bed5442ad95bad6b6ad5564a5409a Installing torch and torchvision Defaulting to user installation because normal site-packages is not writeable ..... ..... Calculating sha256 for /home/cent/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors: Running on local URL: http://0.0.0.0:7860 To create a public link, set `share=True` in `launch()`. Startup time: 205.3s (launcher: 66.2s, import torch: 3.4s, import gradio: 1.0s, setup paths: 1.6s, other imports: 1.0s, setup codeformer: 0.1s, list SD models: 130.6s, load scripts: 0.6s, create ui: 0.7s, gradio launch: 0.1s). 6ce0161689b3853acaa03779ec93eafe75a02f4ced659bee03f50797806fa2fa Loading weights [6ce0161689] from /home/cent/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors Creating model from config: /home/cent/stable-diffusion-webui/configs/v1-inference.yaml LatentDiffusion: Running in eps-prediction mode DiffusionWrapper has 859.52 M params. |
[5] | Access to the port 7860 that was shown on your command line, then you can use [Stable Diffusion]. |
[6] | Input any text and click [Generate] button, then image will be generated. The example below is [sugar glider is flying]. |
|