Spaces:
Runtime error
Runtime error
Get duration
Browse files
app.py
CHANGED
|
@@ -903,7 +903,7 @@ def get_duration(input_image, image_position, prompts, generation_mode, n_prompt
|
|
| 903 |
lora_file,
|
| 904 |
lora_multiplier,
|
| 905 |
fp8_optimization):
|
| 906 |
-
global total_second_length_debug_value
|
| 907 |
|
| 908 |
if total_second_length_debug_value is not None:
|
| 909 |
duration = min(total_second_length_debug_value * 60 * 10, 600)
|
|
@@ -1043,7 +1043,7 @@ def get_duration_video(input_video, prompts, n_prompt, seed, batch, resolution,
|
|
| 1043 |
lora_file,
|
| 1044 |
lora_multiplier,
|
| 1045 |
fp8_optimization):
|
| 1046 |
-
global total_second_length_debug_value
|
| 1047 |
if total_second_length_debug_value is not None:
|
| 1048 |
duration = min(total_second_length_debug_value * 60 * 10, 600)
|
| 1049 |
input_video_debug_value = prompt_debug_value = total_second_length_debug_value = None
|
|
@@ -1328,7 +1328,7 @@ with block:
|
|
| 1328 |
fn = process,
|
| 1329 |
inputs = ips,
|
| 1330 |
outputs = [result_video, preview_image, progress_desc, progress_bar, start_button, end_button],
|
| 1331 |
-
cache_examples =
|
| 1332 |
)
|
| 1333 |
|
| 1334 |
with gr.Row(elem_id="image_examples", visible=False):
|
|
|
|
| 903 |
lora_file,
|
| 904 |
lora_multiplier,
|
| 905 |
fp8_optimization):
|
| 906 |
+
global input_image_debug_value, prompt_debug_value, total_second_length_debug_value
|
| 907 |
|
| 908 |
if total_second_length_debug_value is not None:
|
| 909 |
duration = min(total_second_length_debug_value * 60 * 10, 600)
|
|
|
|
| 1043 |
lora_file,
|
| 1044 |
lora_multiplier,
|
| 1045 |
fp8_optimization):
|
| 1046 |
+
global input_video_debug_value, prompt_debug_value, total_second_length_debug_value
|
| 1047 |
if total_second_length_debug_value is not None:
|
| 1048 |
duration = min(total_second_length_debug_value * 60 * 10, 600)
|
| 1049 |
input_video_debug_value = prompt_debug_value = total_second_length_debug_value = None
|
|
|
|
| 1328 |
fn = process,
|
| 1329 |
inputs = ips,
|
| 1330 |
outputs = [result_video, preview_image, progress_desc, progress_bar, start_button, end_button],
|
| 1331 |
+
cache_examples = torch.cuda.device_count() > 0,
|
| 1332 |
)
|
| 1333 |
|
| 1334 |
with gr.Row(elem_id="image_examples", visible=False):
|