Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -196,34 +196,33 @@ pipeline = XoraVideoPipeline(
|
|
196 |
).to(device)
|
197 |
|
198 |
# Preset options for resolution and frame configuration
|
|
|
199 |
preset_options = [
|
200 |
-
{"label": "1216x704,
|
201 |
-
{"label": "1088x704,
|
202 |
-
{"label": "1056x640,
|
203 |
-
{"label": "992x608,
|
204 |
-
{"label": "896x608,
|
205 |
-
{"label": "896x544,
|
206 |
-
{"label": "832x544,
|
207 |
-
{"label": "800x512,
|
208 |
-
{"label": "768x512,
|
209 |
-
{"label": "800x480,
|
210 |
-
{"label": "736x480,
|
211 |
-
{"label": "704x480,
|
212 |
-
{"label": "704x448,
|
213 |
-
{"label": "672x448,
|
214 |
-
{"label": "640x416,
|
215 |
-
{"label": "672x384,
|
216 |
-
{"label": "640x384,
|
217 |
-
{"label": "608x384,
|
218 |
-
{"label": "576x384,
|
219 |
-
{"label": "608x352,
|
220 |
-
{"label": "576x352,
|
221 |
-
{"label": "544x352,
|
222 |
-
{"label": "512x352,
|
223 |
-
{"label": "
|
224 |
-
{"label": "
|
225 |
-
{"label": "512x320, 249 frames", "width": 512, "height": 320, "num_frames": 249},
|
226 |
-
{"label": "512x320, 257 frames", "width": 512, "height": 320, "num_frames": 257},
|
227 |
]
|
228 |
|
229 |
def preset_changed(preset):
|
@@ -505,7 +504,7 @@ with gr.Blocks(theme=gr.themes.Soft()) as iface:
|
|
505 |
|
506 |
txt2vid_preset = gr.Dropdown(
|
507 |
choices=[p["label"] for p in preset_options],
|
508 |
-
value="
|
509 |
label="Step 2: ν΄μλ ν리μ
μ ν",
|
510 |
)
|
511 |
|
|
|
196 |
).to(device)
|
197 |
|
198 |
# Preset options for resolution and frame configuration
|
199 |
+
# Convert frames to seconds assuming 25 FPS
|
200 |
preset_options = [
|
201 |
+
{"label": "1216x704, 1.6μ΄", "width": 1216, "height": 704, "num_frames": 41},
|
202 |
+
{"label": "1088x704, 2.0μ΄", "width": 1088, "height": 704, "num_frames": 49},
|
203 |
+
{"label": "1056x640, 2.3μ΄", "width": 1056, "height": 640, "num_frames": 57},
|
204 |
+
{"label": "992x608, 2.6μ΄", "width": 992, "height": 608, "num_frames": 65},
|
205 |
+
{"label": "896x608, 2.9μ΄", "width": 896, "height": 608, "num_frames": 73},
|
206 |
+
{"label": "896x544, 3.2μ΄", "width": 896, "height": 544, "num_frames": 81},
|
207 |
+
{"label": "832x544, 3.6μ΄", "width": 832, "height": 544, "num_frames": 89},
|
208 |
+
{"label": "800x512, 3.9μ΄", "width": 800, "height": 512, "num_frames": 97},
|
209 |
+
{"label": "768x512, 3.9μ΄", "width": 768, "height": 512, "num_frames": 97},
|
210 |
+
{"label": "800x480, 4.2μ΄", "width": 800, "height": 480, "num_frames": 105},
|
211 |
+
{"label": "736x480, 4.5μ΄", "width": 736, "height": 480, "num_frames": 113},
|
212 |
+
{"label": "704x480, 4.8μ΄", "width": 704, "height": 480, "num_frames": 121},
|
213 |
+
{"label": "704x448, 5.2μ΄", "width": 704, "height": 448, "num_frames": 129},
|
214 |
+
{"label": "672x448, 5.5μ΄", "width": 672, "height": 448, "num_frames": 137},
|
215 |
+
{"label": "640x416, 6.1μ΄", "width": 640, "height": 416, "num_frames": 153},
|
216 |
+
{"label": "672x384, 6.4μ΄", "width": 672, "height": 384, "num_frames": 161},
|
217 |
+
{"label": "640x384, 6.8μ΄", "width": 640, "height": 384, "num_frames": 169},
|
218 |
+
{"label": "608x384, 7.1μ΄", "width": 608, "height": 384, "num_frames": 177},
|
219 |
+
{"label": "576x384, 7.4μ΄", "width": 576, "height": 384, "num_frames": 185},
|
220 |
+
{"label": "608x352, 7.7μ΄", "width": 608, "height": 352, "num_frames": 193},
|
221 |
+
{"label": "576x352, 8.0μ΄", "width": 576, "height": 352, "num_frames": 201},
|
222 |
+
{"label": "544x352, 8.4μ΄", "width": 544, "height": 352, "num_frames": 209},
|
223 |
+
{"label": "512x352, 9.3μ΄", "width": 512, "height": 352, "num_frames": 233},
|
224 |
+
{"label": "544x320, 9.6μ΄", "width": 544, "height": 320, "num_frames": 241},
|
225 |
+
{"label": "512x320, 10.3μ΄", "width": 512, "height": 320, "num_frames": 257},
|
|
|
|
|
226 |
]
|
227 |
|
228 |
def preset_changed(preset):
|
|
|
504 |
|
505 |
txt2vid_preset = gr.Dropdown(
|
506 |
choices=[p["label"] for p in preset_options],
|
507 |
+
value="512x320, 10.3μ΄",
|
508 |
label="Step 2: ν΄μλ ν리μ
μ ν",
|
509 |
)
|
510 |
|