Module vision_tower

Module vision_tower 

Source
Expand description

The vision tower a built model holds, whichever family bound it.

Atlas serves two structurally different towers: the Qwen3-VL-shaped VisionEncoder that six loaders bind, and GLM-5.3’s GlmVit. They agree on exactly three things, and those three are the whole interface the rest of the engine needs:

  • forward_batched(images) -> per-image (post_h, post_w, merged_p),
  • a packed [Σmerged_p, out_hidden_size] BF16 output buffer, image-ordered,
  • out_hidden_size itself.

So the enum lives here rather than a trait object: two variants, three methods, no dynamic dispatch on a path that already costs a GEMM, and — more to the point — no way for a third tower to be added without deciding out loud what its output contract is.

Enums§

VisionTower