Spaces:
Running on Zero
Running on Zero
Commit History
2 days ago
-
fix: the decoder choices are named by what they do: "Auto", "Steadier (diffusion decoder)" and "Sharper (standard decoder)", in the choice, its line, the Upscale lock line, the Done card and the backend's refusals; the values sent stay auto, diffusion and conv (#27)
Unverified signatureOn the Space the same seed and prompt through both decoders gave the same scene: the diffusion decoder a little softer and steadier from frame to frame (fine detail 10.3 against 11.6, shimmer 1.47 against 1.88), the standard decoder sharper frame by frame with about 28% more shimmer (evidence/space/matrix/ab_decoder). The page called the softer one "Best quality" and the sharper one "Fast". Now the choices read "Auto" (still the vendor's default), "Steadier (diffusion decoder)" ("A little softer, steadier from frame to frame; takes a few seconds longer.") and "Sharper (standard decoder)" ("Sharper frame by frame, with a little more shimmer; faster."). Auto's line is true on every machine: "Diffusion decoder on an NVIDIA GPU that can run it, standard decoder elsewhere." Off CUDA, Auto always takes the standard decoder (pipelines.StageRunner._single_stage_decoder), so the old "where this machine can run it" was untrue on a Mac, and round 4 asked for the NVIDIA wording. The Upscale line …1c8a58d -
fix: the GPU reservation follows each run's size and length, from the Space's measurements with a 1.3 margin, so a default run needs 120 s of quota to start instead of 360, and on the Space a run past the measured envelope is refused before any GPU time (#21)
Unverified signatureEvery run reserved 180 s (LTX25_GPU_DURATION_SECONDS) x1.5 with Upscale, +60 s with an adapter and +180 s with Enhance, whatever it rendered; ZeroGPU wants twice that free on xlarge, so a visitor with less than 360 s of quota could not start a 25-second default run, and nothing stopped a run too large to finish inside its reservation. zerogpu.estimate_duration now reads the request as the run will use it (a sound-only mode's pinned 256 x 256, no Upscale where the mode skips it, the duration head's longest pick, the length a recording or a clip set at the gate and the longest the app allows until it has, the tail of the schedule a clip variation runs) and models its window from the Space's measurements (six deploy-2 runs up to 1920 x 1088 at 10 s and the 24 deploy-1 calls): 25 s before the first step, steps x t(N1) with t(N) = 0.46 + 1.81e-4 N + 1.94e-9 N^2, then 1.0 s + 1.3e-7 s per returned pixel-frame; Upscale adds 3 s + 3 x t(N2) and its larger post; Enhance 60 s; any adapters 30 s…ac68de5
3 days ago
-
fix: the Space harness judges what a mode promises over the files a call returns, so a video-with-sound run passes with its mp4 carrying both tracks and the wav beside it judged as the sound on its own
Unverified signatureSince 20155a1 (F30) a mode that exports video and audio returns two files: the mp4 with both tracks, and output.wav, the same sound on its own. The harness still judged every returned file against the mode's whole export list (verify_streams.verify(mode, file) for each file), as when the mp4 came back in both outputs, so the wav "lacked" a video stream. On 2026-11-16 the Space returned m05_text_to_audio_video correctly (h264 704x480, 121 frames, AAC stereo 48 kHz, plus the wav), the harness called it a MISMATCH, and the plan stopped. Every call that returns video with sound would have done the same: modes 05, 06, 07 and 11, both Upscale calls, the enhancer, the model-chosen length and the operator's audio. What each output holds now comes from the registry (returned_files, from the mode's exports). The video output must carry every track the mode exports and is judged as before, strictly, with the geometry. Beside it, a mode that also exports audio returns its sound on its own. That f…a40a311 -
fix: the Space harness measures an audio track's onsets and band levels, so noise at a normal level no longer reads as sound
Unverified signatureEach audio track was measured by its level, peak, clipping, silence, spectral flatness, centroid and band shares. Noise at -19 dBFS has a perfectly ordinary level, so the one figure people read first said nothing was wrong. Two more measurements sit beside it now, numpy only: an onset count (rises of the 10 ms level by 8 dB or more over the lowest level of the preceding 50 ms, at least 100 ms apart; steady noise has none, speech, hits and chimes many) and each band's energy as a level in dBFS. The line printed per call shows flatness, onsets and band shares with the level. They are measurements, never verdicts: only digital silence fails a call. The test puts white noise and a steady tone at the same -19 dBFS beside twenty 120 ms tone bursts: the noise has flatness above 0.8, no onsets and three quarters of its energy above 6 kHz; the tone has flatness below 0.05 and no onsets; the bursts have exactly twenty.fee4645 -
fix: the Space harness gates a chained input when its file exists, runs the app's gate as the Space does, and can carry the lead's matrix over several days
Unverified signatureTwo harness tests were red. The dry run handed generate.prepare_request a made-up path for an input an earlier call produces, and since the app opens every video before dispatch that path was refused: the harness's validation was wrong. A call with a chained input is now marked "checked when it exists" in the dry run, and the app's gate runs on the real file, before anything is sent, once the producer has run; every call whose inputs exist still goes through prepare_request, and a bad real file is still refused offline. The example plan test wrote 0.34 s of audio for every wav, so any set length was refused: its fixture now has the lengths, rates and channels of the lead's files, and the plan was stale too. The gate runs as the Space runs it. Stage 2 and the diffusion decoder are refused off CUDA, so on a machine with LTX25_DEVICE=cpu or mps the gate would have applied that machine's limits to a Space plan; device.current() now answers with the Space's own resolution (ZeroGPU, CUDA) w…6ae3c5a -
fix: the Space harness records the app's new picture check as it returns it, and sends the real decoder field by name
Unverified signatureThe harness's one picture-check wrapper now calls outputs.assess_picture and records its PictureCheck verbatim in verify.json: the measurements, the conditions that fired (flat, veiled, static) and the notes. It still holds none of the check's thresholds; a fired condition is shown in the summary and never fails a call. decoder is now a real appended field, so the appended-field test uses a hypothetical key for the pass-through and sends decoder="conv" by name beside it. The picture tests compare verify.json with assess_picture's own result and pin that the script calls it from one place only.a63770b -
feat: the Space harness runs a plan of calls by field name inside a hard daily GPU budget, and keeps the evidence of every call
Unverified signaturescripts/space_matrix.py could only loop the eleven modes at 256x256x9 with one prompt and six settable fields, could not apply a LoRA, fed each conditioned mode the harness's own earlier output (so "follows its input" proved nothing), priced an enhanced call at half what the app reserves, kept its ledger inside whichever checkout ran it, and never saw the queue's progress events. A plan (--plan FILE) is a list of calls: a label, a mode, any /on_generate field by its key (a field appended to ui/fields.py is passed through once the spec has it), media as files under --assets-dir, optional LoRAs and an expectation. An input comes from an earlier call only when the plan says {"from_call": ...}, and the record says "chained". --plan default is the old loop with its chains written out, --mode builds one call from flags, --only picks labels. Every call is checked offline by the app's own generate.prepare_request (limits, required inputs, the length an audio mode takes from its audio) and aga…d043b52
-
feat: prompt enhancement ships — a real toggle, in the web process, at zero GPU cost
Unverified signatureThe build refused this twice, and both reasons were wrong. ⛔ "The pack ships it as absent, so `enable_prompt_enhancement=True` fails on our subset." `model_index.json` does carry `prompt_enhancer: [None, None]`, and that is not what it means. Upstream types the component `Gemma4ForConditionalGeneration | None` (pipeline_ltx2.py:249) and lists it in `_optional_components` (:235) — a plain transformers class. The empty slot is there because the component is CONSTRUCTED, not resolved from the snapshot. So it is an ordinary runtime `from_pretrained` into the HF cache, and nothing in model_files.py / preflight.py / preload_from_hub needs to know it exists. ⛔ "ZeroGPU charges it twice at the packing peak, ~20.6 GB." A placement artefact, not a property of the model. Packing runs once per container, at `demo.launch()`, over tensors registered while the module scope ran. A model loaded lazily inside a request handler, on the CPU, is in neither window. It is charged once, as a download. ✅ An…2f36d8a
-
fix: motion is reported, never refused — the temporal gate demoted after it destroyed a real render
Unverified signatureMIN_MEAN_FRAME_DELTA = 0.5 refused image_to_audio_video at 512x960x121: structure 0.9974, high-freq 0.0559, block std 81.6, luma band 238.0 — a coherent photographic scene, a red balloon over a lake at dawn — thrown away for mean |Δ| 0.4071. It is near-static because it is conditioned on a still image of that scene, which is the mode working as designed. The gate never had the margin it appeared to have. Measured with the runner's own decoder on the post-int8-fix m2 runs, the only banked artifacts whose frames have been looked at and are photographs: 0.3859, 0.4071, 0.4168 — against the operator's colour static at 0.403. A legitimate render sits BELOW the failure the threshold was calibrated against. The two populations overlap, and no threshold on this axis separates them, because a temporal measure cannot tell a still scene from a dead one: both measure near zero, and what distinguishes them lives inside the frames rather than between them. So mean |Δ| WARNS. It is still measured, …8c042d4 -
feat: measure whether there is a picture in the frames — structure, not distinctness
Unverified signatureEvery content check this project had could be passed by structureless garbage, and one artifact proved it: 121 of 121 distinct frames, the geometry the request asked for, non-zero bytes, a full luma range — and it was colour static. space_matrix scored artifacts like it as PASS, and the app inspected the frames not at all (generate.py:597 checks only frames-non-empty; generate.py:690 and outputs.py check only that a path exists and is not 0 bytes). The reason no arrangement of those numbers could ever have worked is that distinctness, byte count, geometry and brightness range are properties of NOISE. Noise has all of them in abundance. What noise does not have is structure at a scale above one pixel. Two ratios say it, both divided by the frame's own luma std so they describe shape rather than contrast — a dim shot and a bright shot of the same scene land in the same place: SR = std(8x8 box means) / std(pixels) real 0.918..0.994, failure 0.530 HF = std(laplacian4) / std(p…e54477c
-
docs: 11 of 11 on the Space, and what that still does not claim
Unverified signatureThe two video-INPUT modes were re-run at Space sha 287ba9c carrying d2eb6f2 and both pass, so follow-up #1 closes: 19.95s / 63,438 B / -19.5 dBFS for video_to_audio, 13.67s / 33,812 B / 9 distinct frames / mean |d| 17.277 for video_to_video. Both land inside the 13.67-21.59s band every successful generation occupies, against the 3.53-9.13s the failures took. The uint8 choice is recorded as the part that was load-bearing on the metered side rather than locally: upstream re-compresses a single-frame condition at the model CRF and rejects a non-uint8 array while doing it, so a float payload would have passed the offline gate and failed only on the Space. Fixture provenance is recorded with the result, because without it the numbers prove much less. The runner chains fixtures forward, and by the end of the matrix video.mp4 had drifted to audio_to_video's near-static 7,619 B output at mean |d| 0.905. Conditioning on that would have been unreadable in either direction. The fixture was rebu…17b589c -
docs: the fork-boundary fix is a pair, and half of it is a regression
Unverified signatureThree corrections to SPACE_MODE_MATRIX.md, plus four stale claims elsewhere. The fix for the fork boundary was recorded as one method: a `__reduce__` on LTXStudioError. Reading `spaces` rather than trying it shows that is wrong in both directions, and neither half works alone. `__reduce__` alone does nothing. ExceptionResult (types.py:28-31) carries only `traceback`, `error_cls` and `gradio_error`, and `exception_result` populates the third only when `isinstance(exc, gr.Error)`. Our exception object is therefore never transmitted at all, nothing is ever pickled, and `__reduce__` is never consulted. That also settles the open question of whether restoring picklability would restore the message: it would not, and no live run is needed to know it. A `gr.Error` subclass alone is worse than the status quo. It makes the object eligible for `gradio_error`, which must then cross a multiprocessing.Queue that our classes cannot pickle onto. `spaces` anticipates this at wrappers.py:272-275 and…f927c4e -
fix: the quota ceiling only ever saw its own invocation
Unverified signatureThe cumulative counter lived entirely in one process's memory, so every invocation started at zero and every invocation independently announced that it fit. Five real invocations reported 43.1, 88.8, 97.0, 16.2 and 100.9 GPU-s and none of them knew the others had happened; five at 1900 each would each have printed FITS while spending 9500 of a 2400/day budget. That is the failure class this project treats as the worse one. An inert LEVER merely does nothing; an inert REPORT tells the operator they are safe. PersistentQuota is a JSON ledger keyed to the UTC day, at a FIXED path under outputs/ (already gitignored). Fixed deliberately: putting it under --fixture-dir or --download-dir would reintroduce the defect, because two invocations pointed at different directories would each keep their own total and each announce FITS. --quota-ledger moves it on purpose instead of by accident. It is not keyed on the Space, because the allowance is per ACCOUNT and two Spaces on one token share one b…62d612f -
scripts: a Space matrix runner that bounds its spend and refuses to cross it
Unverified signatureTen of the eleven modes have never run on the Space. This runs them, and it is built around the three ways that exercise can lie: A cost figure that reads as billing. There is no readable ZeroGPU quota endpoint, so billed seconds can only be bounded. Every figure printed is wall clock times the xlarge multiplier and carries "<=" and "UPPER BOUND" at every site -- a bound that loses its label becomes a measurement the moment it is quoted, which this build has already spent a day undoing once. A run that produced nothing and reads as success. `handlers.on_generate` converts every failure into (None, None, markdown), which over the wire is success-SHAPED. A missing artifact for a track the REGISTRY says the mode exports now raises, naming the mode and quoting the Space's own status text verbatim. An artifact that is present, well-formed and empty. H9 passed every structural check 50 dB below its siblings. So artifacts are decoded, not opened: video must have its frame count, distinct f…f7e7379