Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -285,20 +285,6 @@ def call_pipe(
|
|
| 285 |
|
| 286 |
def main():
|
| 287 |
# Define the interface inputs
|
| 288 |
-
prompt_textbox = gr.Textbox(label="Prompt", value="a subject ... ")
|
| 289 |
-
frame1 = gr.Image(label="Frame 1", type="pil")
|
| 290 |
-
frame2 = gr.Image(label="Frame 2", type="pil")
|
| 291 |
-
resolution = gr.Dropdown(
|
| 292 |
-
label="Resolution",
|
| 293 |
-
choices=["720x1280", "544x960", "1280x720", "960x544", "720x720"],
|
| 294 |
-
value="544x960"
|
| 295 |
-
)
|
| 296 |
-
guidance_scale = gr.Slider(minimum=0.1, maximum=20, step=0.1, label="Guidance Scale", value=6.0)
|
| 297 |
-
num_frames = gr.Slider(minimum=1, maximum=129, step=1, label="Number of Frames", value=49)
|
| 298 |
-
num_inference_steps = gr.Slider(minimum=1, maximum=100, step=1, label="Number of Inference Steps", value=30)
|
| 299 |
-
|
| 300 |
-
# Define the interface outputs
|
| 301 |
-
outputs = gr.Video(label="Generated Video")
|
| 302 |
|
| 303 |
with gr.Blocks() as demo:
|
| 304 |
gr.Markdown("# HunyuanVideo Keyframes Gen Control Lora")
|
|
@@ -309,19 +295,23 @@ def main():
|
|
| 309 |
|
| 310 |
with gr.Row():
|
| 311 |
with gr.Column():
|
| 312 |
-
prompt_textbox
|
| 313 |
-
resolution
|
|
|
|
|
|
|
|
|
|
|
|
|
| 314 |
with gr.Column():
|
| 315 |
-
guidance_scale
|
| 316 |
-
num_frames
|
| 317 |
-
|
| 318 |
with gr.Row():
|
| 319 |
-
frame1
|
| 320 |
-
frame2
|
| 321 |
|
| 322 |
with gr.Row():
|
| 323 |
-
num_inference_steps
|
| 324 |
-
outputs
|
| 325 |
|
| 326 |
generate_button = gr.Button("Generate Video")
|
| 327 |
generate_button.click(generate_video, inputs=[prompt_textbox, frame1, frame2, resolution, guidance_scale, num_frames, num_inference_steps], outputs=outputs)
|
|
|
|
| 285 |
|
| 286 |
def main():
|
| 287 |
# Define the interface inputs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 288 |
|
| 289 |
with gr.Blocks() as demo:
|
| 290 |
gr.Markdown("# HunyuanVideo Keyframes Gen Control Lora")
|
|
|
|
| 295 |
|
| 296 |
with gr.Row():
|
| 297 |
with gr.Column():
|
| 298 |
+
prompt_textbox = gr.Textbox(label="Prompt", value="a subject ... ")
|
| 299 |
+
resolution = gr.Dropdown(
|
| 300 |
+
label="Resolution",
|
| 301 |
+
choices=["720x1280", "544x960", "1280x720", "960x544", "720x720"],
|
| 302 |
+
value="544x960"
|
| 303 |
+
)
|
| 304 |
with gr.Column():
|
| 305 |
+
guidance_scale = gr.Slider(minimum=0.1, maximum=20, step=0.1, label="Guidance Scale", value=6.0)
|
| 306 |
+
num_frames = gr.Slider(minimum=1, maximum=129, step=1, label="Number of Frames", value=49)
|
| 307 |
+
|
| 308 |
with gr.Row():
|
| 309 |
+
frame1 = gr.Image(label="Frame 1", type="pil")
|
| 310 |
+
frame2 = gr.Image(label="Frame 2", type="pil")
|
| 311 |
|
| 312 |
with gr.Row():
|
| 313 |
+
num_inference_steps = gr.Slider(minimum=1, maximum=100, step=1, label="Number of Inference Steps", value=30)
|
| 314 |
+
outputs = gr.Video(label="Generated Video")
|
| 315 |
|
| 316 |
generate_button = gr.Button("Generate Video")
|
| 317 |
generate_button.click(generate_video, inputs=[prompt_textbox, frame1, frame2, resolution, guidance_scale, num_frames, num_inference_steps], outputs=outputs)
|