mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-06 00:08:52 +00:00
With pictures on (the default; the 0.1.75 engines honour --vision for the .strata tiers) the engine keeps the reader's weights and one picture free of experts
at the start (1137 MiB on the Windows 5070 12 GB: the floor 1536 becomes 2673 MiB). Measured there with CUDA 13.0: Balanced decodes 21.6 tok/s against 28.8
with pictures off and 27.3 on the released 0.1.74, Compact 93.9 against 111.5. The engine's own answer is --vision-reserve-mib N: 0 keeps nothing free, and
at the first picture the reader's weights go to the card if they fit, else the CPU encoder reads it.
qwen4_fit.vision_reserve_zero_why: the build is in VISION_RESERVE_ZERO_BUILDS (Compact, Balanced, Ultra), the backend is CUDA and the card holds less than the
Control's own vram_need_gib of the build WITH the picture reader (vision=True, the start's context, K/V format and drafter). qwen4_kind._with_vision_reserve
appends `--vision-reserve-mib 0` to the engine arguments of such a start when `--vision` is in them, the engine has it (ENGINE_FEATURE_MIN["vision"], 0.1.75), the
card is a discrete NVIDIA one (qwen4_family.card_is_unified: not GB10 and the like) and the person has not written `--vision-reserve-mib` or `--vision-device cpu`.
The flag is in the serve table (STRATA_SERVE_FLAGS, gated: only CUDA, pictures usable, engine >= 0.1.75), so a value the person writes passes the filter.
Not changed: full-fit cards, the Mac and every other backend (the new code returns at its first guard; the flag is unknown to the table there exactly as before),
unified memory, the UD / GGUF builds, a released engine, pictures off.
Test: tests/terminal/test_qwen4_vision_reserve.py. The Mac half compares the argv of every tier, pictures on and off, with and without a --vision-reserve-mib the
person wrote, through the Mac builders (metal_engine_args, extra_args, strata_engine_args) with tests/data/qwen4/mac_argv_ca1be5afc2.json, made by the same
function on ca1be5afc2 (the signed Mac Control) before this change.