Repository navigation
vision: header probe, decode caps, EXIF orientation and pixel-bound parity (ported from Enntity) - #237
Conversation
bdc9c03 to
0ead7cb
Compare
a5a8ecc to
d4d678d
Compare
0ead7cb to
79e9093
Compare
d4d678d to
0c579fb
Compare
79e9093 to
63d7c29
Compare
0c579fb to
5b4db6d
Compare
63d7c29 to
339ea06
Compare
5b4db6d to
edc95ac
Compare
339ea06 to
eda90fe
Compare
edc95ac to
b66cf66
Compare
eda90fe to
13b85cc
Compare
b66cf66 to
8773f93
Compare
13b85cc to
b15cc3d
Compare
8773f93 to
b4d2a65
Compare
6e608da to
0fb157c
Compare
e535188 to
2d377ef
Compare
0fb157c to
d7601f1
Compare
24344b6 to
aaa4c7a
Compare
|
vision-fidelity on this PR: the "geometry failures" come from the benchmark's model, not from the engine. Run on T =
The uniform −15 on every rung comes from the calibration fixture: it's 224², whose expectation becomes 64 instead of 49. The two "integrity" deltas, 36 against an expected 72, are the 224² → 336² difference under the same rule (100 − 64).
The benchmark's own comment anticipated this: "if the engine ever switches to half-even this model must move with it". This PR now carries that change as a separate commit: Behaviour change to be aware of: after this PR, images whose side divided by 32 ends in .5, and images under 65536 px, get the same token grid the HF processor gives them. Main gives them a grid one unit off, or doesn't scale them up. The in-budget identity check (T vs P on the same images) shows exactly that: 1280×720 changes, while 640×480, 1024², red/blue, EXIF-6 and the 4 s clip don't. cc @tbraun96 (author of the geometry model). |
32651bb to
52dafcb
Compare
…n rounding, shortest_edge floor) that #237 moved the engine to
11e7dd2 to
0a313f9
Compare
b48119e to
f388f51
Compare
…n rounding, shortest_edge floor) that #237 moved the engine to
…be modules Ports Enntity/atlas 83389c7 9f65625 8f0a89b aa494cc d85c88d (vision preprocess revision, probe + qwen/glm sizing, video row ceiling, startup parity) on top of stack/vision-admission. Output changes vs parent: - Native decoder allocation is capped at 640 MiB (DECODE_MAX_ALLOC); decodes over 192 MiB (DECODE_LARGE) run two at a time behind decode_gated. - EXIF orientation is applied: header-declared sizes are swapped when the orientation flag rotates 90/270 degrees. - Header probing (sniff_format + limited_reader + check_decode_size) rejects malformed images and >16384px side declarations before pixel allocation. - Video media hold a conservative qwen_video_rows_ceiling reservation (reserve_video) reconciled to actual rows after decode. - startup_parity gains a 'vision max pixels' entry (aa494cc): ranks with different resolved encoder windows fail at boot, not inside a collective. - VisionConfig gains token_budgets/min_pixels/video_pixels; GLM sizing runs through glm_pixel_budget/glm_target_size (token-budget bounded). Co-authored-by: Enntity/atlas contributors
…test with the admission tests (500-LoC cap, no logic edits)
…n rounding, shortest_edge floor) that #237 moved the engine to
…b(super), remote_image paths)
…solve fns (as main carries)
0dfdc5b to
4b085d5
Compare
…t fit request_rows so the spent-budget 503 fires)
Stack: … ← #236 ← this.
Summary
83389c7e,9f656251,8f0a89b1,aa494ccb,d85c88d0, atd0cead1) with credit.DECODE_MAX_ALLOCis 640 MiB, with a two-at-onceDECODE_LARGEgate.vision max pixelsstartup-parity entry: ranks must agree on the bound.Test plan (vs parent #236)
probe15/15,vision_preprocess39/39,vision_limits15/15,qwen3vl3/3 (reiner, ffmpeg 7.0.2 static on PATH)video_decode_ffmpeg14/17: the same 3 frame-count tests fail identically on the parent's vision: VFR-accurate video frame timestamps, area-bounded decode scale, declared min/max pixels (ported from Enntity) #233 tree, so they're attributed thereTracking: #220.
Generated with Devin
Update 10-29 (pair-checked and fixed):
prepare.rsnow passesstate.vision_limits/state.vision_budget. Before, every caller passedAdmitCtx::default()(fixed in vision: admission budgets: per-request rows (400) and in-flight rows (503 + Retry-After) (ported from Enntity) #236). On the pair,d7601f1c5: 8 × 2048² images → 400vision_input_too_large(non-stream, stream and Anthropic); 1, 2 and 4 images are served; malformed or hostile headers are refused in under 20 ms.qwen_video_rows_ceiling→reserve_video→decode_gated(preprocess_video)→reconcile_videoare now wired, as upstreamd0cead1does. It's opt-in, like upstream: it engages only with--video-max-pixelsset, sinceFfmpegPolicy::max_total_decoded_pixelsdefaults toNone(upstreamserve_args.rs:1047,video_decode_ffmpeg.rs:117). Test:a_video_request_with_a_spent_in_flight_budget_is_refused_busy_before_decode.b4d2a6541,vision-fidelityshowed geometry matched 4/14 and integrity 8/10 against the parent's 14/14 and 10/10. That run used each arm's own binary as the client, so it's being re-run with one fixed client to name the cells. Don't merge until that's resolved.