Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,6 @@
|
|
1 |
import gradio as gr
|
2 |
import spaces
|
3 |
-
import
|
4 |
|
5 |
@spaces.GPU(duration=60)
|
6 |
def generate_image(prompt, negative_prompt="", seed=-1, width=512, height=512, guidance_scale=7.5, num_inference_steps=50):
|
@@ -33,7 +33,7 @@ with gr.Blocks() as demo:
|
|
33 |
|
34 |
# Set up the function call using the loaded Flux model interface
|
35 |
generate_button.click(
|
36 |
-
flux_demo,
|
37 |
inputs=[prompt, negative_prompt, seed, width, height, guidance_scale, num_inference_steps],
|
38 |
outputs=[image_output, seed_output]
|
39 |
)
|
|
|
1 |
import gradio as gr
|
2 |
import spaces
|
3 |
+
from huggingface_hub import HfApi
|
4 |
|
5 |
@spaces.GPU(duration=60)
|
6 |
def generate_image(prompt, negative_prompt="", seed=-1, width=512, height=512, guidance_scale=7.5, num_inference_steps=50):
|
|
|
33 |
|
34 |
# Set up the function call using the loaded Flux model interface
|
35 |
generate_button.click(
|
36 |
+
flux_demo.predict,
|
37 |
inputs=[prompt, negative_prompt, seed, width, height, guidance_scale, num_inference_steps],
|
38 |
outputs=[image_output, seed_output]
|
39 |
)
|