Spaces:
Running
on
Zero
Running
on
Zero
Update app_v2v.py
Browse files- app_v2v.py +4 -8
app_v2v.py
CHANGED
@@ -3,7 +3,7 @@ from diffusers_helper.hf_login import login
|
|
3 |
import os
|
4 |
|
5 |
os.environ['HF_HOME'] = os.path.abspath(os.path.realpath(os.path.join(os.path.dirname(__file__), './hf_download')))
|
6 |
-
|
7 |
import gradio as gr
|
8 |
import torch
|
9 |
import traceback
|
@@ -520,7 +520,8 @@ def worker(input_video, prompt, n_prompt, seed, batch, resolution, total_second_
|
|
520 |
|
521 |
stream.output_queue.push(('end', None))
|
522 |
return
|
523 |
-
|
|
|
524 |
def process(input_video, prompt, n_prompt, seed, batch, resolution, total_second_length, latent_window_size, steps, cfg, gs, rs, gpu_memory_preservation, use_teacache, no_resize, mp4_crf, num_clean_frames, vae_batch):
|
525 |
global stream, high_vram
|
526 |
# 20250506 pftq: Updated assertion for video input
|
@@ -643,9 +644,4 @@ with block:
|
|
643 |
start_button.click(fn=process, inputs=ips, outputs=[result_video, preview_image, progress_desc, progress_bar, start_button, end_button])
|
644 |
end_button.click(fn=end_process)
|
645 |
|
646 |
-
block.launch(
|
647 |
-
server_name=args.server,
|
648 |
-
server_port=args.port,
|
649 |
-
share=args.share,
|
650 |
-
inbrowser=args.inbrowser,
|
651 |
-
)
|
|
|
3 |
import os
|
4 |
|
5 |
os.environ['HF_HOME'] = os.path.abspath(os.path.realpath(os.path.join(os.path.dirname(__file__), './hf_download')))
|
6 |
+
import spaces
|
7 |
import gradio as gr
|
8 |
import torch
|
9 |
import traceback
|
|
|
520 |
|
521 |
stream.output_queue.push(('end', None))
|
522 |
return
|
523 |
+
|
524 |
+
@spaces.GPU()
|
525 |
def process(input_video, prompt, n_prompt, seed, batch, resolution, total_second_length, latent_window_size, steps, cfg, gs, rs, gpu_memory_preservation, use_teacache, no_resize, mp4_crf, num_clean_frames, vae_batch):
|
526 |
global stream, high_vram
|
527 |
# 20250506 pftq: Updated assertion for video input
|
|
|
644 |
start_button.click(fn=process, inputs=ips, outputs=[result_video, preview_image, progress_desc, progress_bar, start_button, end_button])
|
645 |
end_button.click(fn=end_process)
|
646 |
|
647 |
+
block.launch(ssr_mode=False)
|
|
|
|
|
|
|
|
|
|