Spaces:
Sleeping
Sleeping
Sudhanshu Mittal Claude Opus 4.8 commited on
Commit ·
459951f
1
Parent(s): 56da3b2
Drop the Advanced panel from the demo UI
Browse filesRemoves the Seed and Eta controls. Both are still passed to the rollout script,
just fixed internally: eta stays at the deterministic-ODE default (0.0), and
each run draws a fresh random seed rather than exposing -1 / explicit-seed
semantics that only make sense if you are reproducing a run.
Behaviour is unchanged from the previous defaults. The NUM_VIDEOS rollouts still
diverge, since the sampler draws independent initial noise per batch element
regardless of the shared seed. Demo text updated to stop pointing at a panel
that no longer exists.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
app2.py
CHANGED
|
@@ -250,13 +250,12 @@ step emits several image frames, so the final clip is longer than the step count
|
|
| 250 |
*L1 sampler steps* controls the detail predictor, which integrates the flow-matching
|
| 251 |
ODE and benefits from more steps (sharper frames, slower). *L2 sampler steps* controls
|
| 252 |
the abstract predictor, which is **consistency-distilled** and so is designed to run in
|
| 253 |
-
very few steps — raising it buys little.
|
| 254 |
-
0 is the deterministic ODE, higher values turn it into an SDE.
|
| 255 |
|
| 256 |
**Randomness.** The {NUM_VIDEOS} rollouts share one context and one seed, but the
|
| 257 |
-
solver draws independent initial noise per batch element, so the futures diverge.
|
| 258 |
-
|
| 259 |
-
|
| 260 |
|
| 261 |
**Note.** The clip must be long enough for the L2 look-back window; very short clips
|
| 262 |
are rejected with an explicit error. Frame and step counts are kept modest to fit the
|
|
@@ -349,7 +348,7 @@ def _stream_rollout(cmd: list[str], say) -> str:
|
|
| 349 |
|
| 350 |
@spaces.GPU(duration=300)
|
| 351 |
def run_rollout(video_path: str, num_gen_steps: int, l1_steps: int, l2_steps: int,
|
| 352 |
-
|
| 353 |
if video_path is None:
|
| 354 |
raise gr.Error("Please upload a short mp4 clip first.")
|
| 355 |
|
|
@@ -357,10 +356,13 @@ def run_rollout(video_path: str, num_gen_steps: int, l1_steps: int, l2_steps: in
|
|
| 357 |
progress(frac, desc=msg)
|
| 358 |
|
| 359 |
try:
|
| 360 |
-
#
|
| 361 |
-
#
|
| 362 |
-
#
|
| 363 |
-
|
|
|
|
|
|
|
|
|
|
| 364 |
|
| 365 |
job = Path(tempfile.gettempdir()) / f"orbis2_{uuid.uuid4().hex[:8]}"
|
| 366 |
|
|
@@ -446,13 +448,6 @@ def build_demo():
|
|
| 446 |
label="L2 sampler steps",
|
| 447 |
info="Abstract predictor — distilled, needs very few")
|
| 448 |
|
| 449 |
-
with gr.Accordion("Advanced", open=False):
|
| 450 |
-
seed_in = gr.Number(value=-1, precision=0, label="Seed",
|
| 451 |
-
info="-1 draws a fresh seed each run")
|
| 452 |
-
eta = gr.Slider(0.0, 1.0, value=DEFAULT_ETA, step=0.05,
|
| 453 |
-
label="Eta (stochasticity)",
|
| 454 |
-
info="0 = deterministic ODE; >0 adds noise per step")
|
| 455 |
-
|
| 456 |
btn = gr.Button("Generate rollouts", variant="primary")
|
| 457 |
|
| 458 |
with gr.Column(scale=1):
|
|
@@ -461,7 +456,7 @@ def build_demo():
|
|
| 461 |
|
| 462 |
btn.click(
|
| 463 |
run_rollout,
|
| 464 |
-
inputs=[inp, n_steps_gen, l1_steps, l2_steps
|
| 465 |
outputs=outs,
|
| 466 |
concurrency_limit=1,
|
| 467 |
)
|
|
|
|
| 250 |
*L1 sampler steps* controls the detail predictor, which integrates the flow-matching
|
| 251 |
ODE and benefits from more steps (sharper frames, slower). *L2 sampler steps* controls
|
| 252 |
the abstract predictor, which is **consistency-distilled** and so is designed to run in
|
| 253 |
+
very few steps — raising it buys little.
|
|
|
|
| 254 |
|
| 255 |
**Randomness.** The {NUM_VIDEOS} rollouts share one context and one seed, but the
|
| 256 |
+
solver draws independent initial noise per batch element, so the futures diverge. Each
|
| 257 |
+
run draws a fresh seed, so generating again on the same clip gives you a new set of
|
| 258 |
+
futures.
|
| 259 |
|
| 260 |
**Note.** The clip must be long enough for the L2 look-back window; very short clips
|
| 261 |
are rejected with an explicit error. Frame and step counts are kept modest to fit the
|
|
|
|
| 348 |
|
| 349 |
@spaces.GPU(duration=300)
|
| 350 |
def run_rollout(video_path: str, num_gen_steps: int, l1_steps: int, l2_steps: int,
|
| 351 |
+
progress=gr.Progress()):
|
| 352 |
if video_path is None:
|
| 353 |
raise gr.Error("Please upload a short mp4 clip first.")
|
| 354 |
|
|
|
|
| 356 |
progress(frac, desc=msg)
|
| 357 |
|
| 358 |
try:
|
| 359 |
+
# Seed and eta are no longer exposed in the UI. Every run draws a fresh seed,
|
| 360 |
+
# so repeated runs on the same clip show different futures; the rollout script
|
| 361 |
+
# only seeds when seed > 0. eta stays at the deterministic-ODE default — within
|
| 362 |
+
# a batch each sample still draws its own noise, so the NUM_VIDEOS rollouts
|
| 363 |
+
# diverge regardless.
|
| 364 |
+
seed = random.randrange(1, 2**31 - 1)
|
| 365 |
+
eta = DEFAULT_ETA
|
| 366 |
|
| 367 |
job = Path(tempfile.gettempdir()) / f"orbis2_{uuid.uuid4().hex[:8]}"
|
| 368 |
|
|
|
|
| 448 |
label="L2 sampler steps",
|
| 449 |
info="Abstract predictor — distilled, needs very few")
|
| 450 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 451 |
btn = gr.Button("Generate rollouts", variant="primary")
|
| 452 |
|
| 453 |
with gr.Column(scale=1):
|
|
|
|
| 456 |
|
| 457 |
btn.click(
|
| 458 |
run_rollout,
|
| 459 |
+
inputs=[inp, n_steps_gen, l1_steps, l2_steps],
|
| 460 |
outputs=outs,
|
| 461 |
concurrency_limit=1,
|
| 462 |
)
|