Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -1,4 +1,5 @@
|
|
1 |
import random
|
|
|
2 |
|
3 |
import gradio as gr
|
4 |
import numpy as np
|
@@ -45,7 +46,7 @@ MAX_SEED = np.iinfo(np.int32).max
|
|
45 |
MAX_IMAGE_SIZE = 1024
|
46 |
NUM_INFERENCE_STEPS = 4
|
47 |
|
48 |
-
|
49 |
def infer(prompt, seed, randomize_seed):
|
50 |
|
51 |
if randomize_seed:
|
|
|
1 |
import random
|
2 |
+
import spaces
|
3 |
|
4 |
import gradio as gr
|
5 |
import numpy as np
|
|
|
46 |
MAX_IMAGE_SIZE = 1024
|
47 |
NUM_INFERENCE_STEPS = 4
|
48 |
|
49 |
+
@spaces.GPU
|
50 |
def infer(prompt, seed, randomize_seed):
|
51 |
|
52 |
if randomize_seed:
|