Spaces:
Running
on
Zero
Running
on
Zero
Update app.py
Browse files
app.py
CHANGED
@@ -40,7 +40,7 @@ from transformers import CLIPFeatureExtractor
|
|
40 |
feature_extractor = CLIPFeatureExtractor.from_pretrained("openai/clip-vit-base-patch32")
|
41 |
|
42 |
# Function
|
43 |
-
@spaces.GPU(duration=
|
44 |
def generate_image(prompt, base="Realistic", motion="", step=8, progress=gr.Progress()):
|
45 |
global step_loaded
|
46 |
global base_loaded
|
@@ -162,7 +162,7 @@ with gr.Blocks(css="style.css") as demo:
|
|
162 |
fn=generate_image,
|
163 |
inputs=[prompt],
|
164 |
outputs=[video],
|
165 |
-
cache_examples=
|
166 |
)
|
167 |
|
168 |
demo.queue().launch()
|
|
|
40 |
feature_extractor = CLIPFeatureExtractor.from_pretrained("openai/clip-vit-base-patch32")
|
41 |
|
42 |
# Function
|
43 |
+
@spaces.GPU(duration=30,queue=False)
|
44 |
def generate_image(prompt, base="Realistic", motion="", step=8, progress=gr.Progress()):
|
45 |
global step_loaded
|
46 |
global base_loaded
|
|
|
162 |
fn=generate_image,
|
163 |
inputs=[prompt],
|
164 |
outputs=[video],
|
165 |
+
cache_examples="lazy",
|
166 |
)
|
167 |
|
168 |
demo.queue().launch()
|