Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -16,14 +16,14 @@ for model_id in model_ids:
|
|
16 |
import subprocess
|
17 |
|
18 |
def run_inference(prompt, video_path, condition, video_length):
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
command = f"python inference.py --prompt '{prompt}' --condition '{condition}' --video_path '{video_path}' --output_path '' --video_length {video_length} --smoother_steps 19 20"
|
23 |
subprocess.run(command, shell=True)
|
24 |
|
25 |
# Construct the video path
|
26 |
-
video_path_output = f"{prompt}.mp4"
|
27 |
return "done", video_path_output
|
28 |
|
29 |
|
|
|
16 |
import subprocess
|
17 |
|
18 |
def run_inference(prompt, video_path, condition, video_length):
|
19 |
+
|
20 |
+
output_path = 'output/'
|
21 |
+
os.makedirs(output_path, exist_ok=True)
|
22 |
+
command = f"python inference.py --prompt '{prompt}' --condition '{condition}' --video_path '{video_path}' --output_path '{output_path}' --video_length {video_length} --smoother_steps 19 20"
|
23 |
subprocess.run(command, shell=True)
|
24 |
|
25 |
# Construct the video path
|
26 |
+
video_path_output = os.path.join(output_path, f"{prompt}.mp4")
|
27 |
return "done", video_path_output
|
28 |
|
29 |
|