Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,8 @@ from PIL import Image
|
|
14 |
from io import BytesIO
|
15 |
from diffusers import StableDiffusionImg2ImgPipeline, AutoencoderKL, DiffusionPipeline
|
16 |
from diffusers.utils import load_image
|
17 |
-
from diffusers
|
|
|
18 |
|
19 |
DESCRIPTION = "# SDXL"
|
20 |
if not torch.cuda.is_available():
|
@@ -65,7 +66,7 @@ def generate(
|
|
65 |
if torch.cuda.is_available():
|
66 |
|
67 |
if not use_vae:
|
68 |
-
pipe = StableDiffusionImg2ImgPipeline.from_pretrained(model, torch_dtype=torch.float16, safety_checker=
|
69 |
|
70 |
if use_vae:
|
71 |
vae = AutoencoderKL.from_pretrained(vaecall, torch_dtype=torch.float16)
|
|
|
14 |
from io import BytesIO
|
15 |
from diffusers import StableDiffusionImg2ImgPipeline, AutoencoderKL, DiffusionPipeline
|
16 |
from diffusers.utils import load_image
|
17 |
+
from diffusers import StableDiffusionPipeline
|
18 |
+
from diffusers import logging
|
19 |
|
20 |
DESCRIPTION = "# SDXL"
|
21 |
if not torch.cuda.is_available():
|
|
|
66 |
if torch.cuda.is_available():
|
67 |
|
68 |
if not use_vae:
|
69 |
+
pipe = StableDiffusionImg2ImgPipeline.from_pretrained(model, torch_dtype=torch.float16, safety_checker=True)
|
70 |
|
71 |
if use_vae:
|
72 |
vae = AutoencoderKL.from_pretrained(vaecall, torch_dtype=torch.float16)
|