Update app.py
Browse files
app.py
CHANGED
@@ -7,15 +7,15 @@ import os
|
|
7 |
#os.system("pip install git+https://github.com/fffiloni/diffusers")
|
8 |
|
9 |
from diffusers import DiffusionPipeline, DDIMScheduler
|
10 |
-
|
11 |
|
12 |
has_cuda = torch.cuda.is_available()
|
13 |
-
device = "cuda"
|
14 |
|
15 |
pipe = DiffusionPipeline.from_pretrained(
|
16 |
"CompVis/stable-diffusion-v1-4",
|
17 |
safety_checker=None,
|
18 |
-
custom_pipeline=
|
19 |
scheduler = DDIMScheduler(beta_start=0.00085, beta_end=0.012, beta_schedule="scaled_linear", clip_sample=False, set_alpha_to_one=False)
|
20 |
).to(device)
|
21 |
|
|
|
7 |
#os.system("pip install git+https://github.com/fffiloni/diffusers")
|
8 |
|
9 |
from diffusers import DiffusionPipeline, DDIMScheduler
|
10 |
+
from imagic import ImagicStableDiffusionPipeline
|
11 |
|
12 |
has_cuda = torch.cuda.is_available()
|
13 |
+
device = "cuda"
|
14 |
|
15 |
pipe = DiffusionPipeline.from_pretrained(
|
16 |
"CompVis/stable-diffusion-v1-4",
|
17 |
safety_checker=None,
|
18 |
+
custom_pipeline=ImagicStableDiffusionPipeline,
|
19 |
scheduler = DDIMScheduler(beta_start=0.00085, beta_end=0.012, beta_schedule="scaled_linear", clip_sample=False, set_alpha_to_one=False)
|
20 |
).to(device)
|
21 |
|