Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -3,12 +3,11 @@ import torch
|
|
3 |
import numpy as np
|
4 |
import modin.pandas as pd
|
5 |
from PIL import Image
|
6 |
-
from diffusers import DiffusionPipeline
|
7 |
|
8 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
9 |
-
|
10 |
-
|
11 |
-
pipe = DiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-2-1", safety_checker=None)
|
12 |
pipe = pipe.to(device)
|
13 |
|
14 |
def genie (prompt, negative_prompt, scale, steps, seed):
|
|
|
3 |
import numpy as np
|
4 |
import modin.pandas as pd
|
5 |
from PIL import Image
|
6 |
+
from diffusers import DiffusionPipeline
|
7 |
|
8 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
9 |
+
pipe.unet = torch.compile(pipe.unet, mode="reduce-overhead", fullgraph=True)
|
10 |
+
pipe = DiffusionPipeline.from_pretrained("stabilityai/stable-diffusion-xl-base-0.9", safety_checker=None)
|
|
|
11 |
pipe = pipe.to(device)
|
12 |
|
13 |
def genie (prompt, negative_prompt, scale, steps, seed):
|