readme.txt 1.24 KB
Newer Older
lijian6's avatar
lijian6 committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
1、 download models

# checkpoint version
git lfs install
git clone https://huggingface.co/CompVis/stable-diffusion-v-1-1-original
git clone https://huggingface.co/CompVis/stable-diffusion-v-1-2-original
git clone https://huggingface.co/CompVis/stable-diffusion-v-1-3-original
git clone https://huggingface.co/CompVis/stable-diffusion-v-1-4-original


# diffusers version
# git clone https://huggingface.co/CompVis/stable-diffusion-v1-1
# git clone https://huggingface.co/CompVis/stable-diffusion-v1-2
# git clone https://huggingface.co/CompVis/stable-diffusion-v1-3
# git clone https://huggingface.co/CompVis/stable-diffusion-v1-4
# git clone https://huggingface.co/runwayml/stable-diffusion-v1-5

# if you want to clone without large files – just their pointers
# prepend your git clone with the following env var:
# GIT_LFS_SKIP_SMUDGE=1


2、 link model

mkdir -p models/ldm/stable-diffusion-v1/
ln -s <path/to/model.ckpt> models/ldm/stable-diffusion-v1/model.ckpt


3、 download safety-checker

git clone https://huggingface.co/CompVis/stable-diffusion-safety-checker


3、 run example

(1) run with checkpoint model:
`python scripts/txt2img.py --prompt "a photograph of an astronaut riding a horse" --plms`

(2) run with diffusers pipeline:
python Diffusers.py