Qwen3-VL grounding 2B

Click a block to read its description, or select it with Tab and Enter.

Qwen3-VL grounding 2BPoint. P = image patches; L = combined tokens (runtime axes). Model widths below are resolved.LibreYOLOQwen3-VL grounding 2BPoint. P = image patches; L = combined tokens (runtime axes). Model widths below are resolved.Image encoderImage processorNominal runner size 1024; native tiling/resizeConv3d patch embeddingpatch=16; output P × 1024Learned/interpolated 2D positionsP × 1024Vision blocks 0 to 5n=6; width 1024V0Vision blocks 6 to 11n=6; width 1024V1Vision blocks 12 to 17n=6; width 1024V2Vision blocks 18 to 23n=6; width 1024VV carries final visual features to the projector.Patch counts vary with processor output, not model size.V0/V1/V2 are the three intermediate visual taps.Projection and multimodal sequenceVVisual projector1024 channels become 2048 channelsVisual token sequencePatch grouping factor 2 per axisPrompt and image placeholdersClick instructionTokenizerRuntime text lengthToken embeddingVocabulary 151936; width 2048Replace image-token placeholdersL × 2048; image and text in one sequenceSV0Intermediate patch mergerPost-shuffle LayerNorm; output width 2048D0V1Intermediate patch mergerPost-shuffle LayerNorm; output width 2048D1V2Intermediate patch mergerPost-shuffle LayerNorm; output width 2048D2D0/D1/D2 add to visual positions in text layers 0/1/2.S denotes the multimodal token sequence.Language model and generated outputSText decoder layer 0Width 2048+D0Text decoder layer 1Width 2048+D1Text decoder layer 2Width 2048+D2Remaining text decoder layersn=25Final RMSNorm2048 channelsLanguage head Linear2048 to 151936Greedy token generationmax_new_tokens=128; do_sample=FalseOO is the generated reply; prompt tokens are removed.The adapter decodes O into task geometry below.Vision transformer layerInputS × 1024LayerNorm1024 channelsVision attention+LayerNorm1024 channelsVision MLP+OutputS × 1024S is the token count of this sublayer.Text decoder layerInputS × 2048RMSNorm2048 channelsCausal attention+RMSNorm2048 channelsGated MLP+OutputS × 2048S is the token count of this sublayer.Vision attentionInput width 1024; Q heads 16; K/V heads 16.Q Linear1024 to 1024Split heads64 per headK Linear1024 to 1024Split heads64 per headV Linear1024 to 1024Split heads64 per headRotary positioncos/sin half rotationRotary positioncos/sin half rotationQ × transpose(K)Scale by 1/sqrt(64)Softmax over keysWithin the image; padding maskAttention weights × V16 query heads, weighted valuesConcat headsOutput Linear1024 to 1024RoPE: x*cos + rotate_half(x)*sin.Distinct projections share the same normalized input.Text attentionInput width 2048; Q heads 16; K/V heads 8.Q Linear2048 to 2048Split heads128 per headK Linear2048 to 1024Split heads128 per headV Linear2048 to 1024Split heads128 per headRMSNorm128 per headRMSNorm128 per headRotary positioncos/sin half rotationRotary positioncos/sin half rotationAlign K heads8 to 16Align V heads8 to 16Q × transpose(K)Scale by 1/sqrt(128)Softmax over keysCausal mask; cached K/V optionalAttention weights × V16 query heads, weighted valuesConcat headsOutput Linear2048 to 2048RoPE: x*cos + rotate_half(x)*sin.Cached decode appends past K/V before head alignment.Vision MLPInputS × 1024Linear1024 to 4096gelu_pytorch_tanhDown Linear4096 to 1024OutputS × 1024Residual addition is in the enclosing layer diagram.S is the token count of this sublayer.Text MLPInputS × 2048Gate Linear2048 to 6144Up Linear2048 to 6144SiLUElementwise multiplyS × 6144Down Linear6144 to 2048OutputS × 2048Residual addition is in the enclosing layer diagram.S is the token count of this sublayer.Visual projectorLayerNorm1024 channels (main merger)Group spatial neighbors2 × 2; packed width 4096Linear4096 to 4096GELULinear4096 to 2048Deep-tap mergers normalize after grouping.Output width equals the language-model embedding.LibreYOLO output adapterODecode generated tokensRetain reply textExtract click coordinatesBare [x,y] or parsed pointAttach active query labelOne requested click targetScale to original image0 to1000 coordinatesValidate and filterConfidence / classes; at most one pointResults.pointsPixel coordinates + synthetic score1Scores are adapter placeholders, not calibrated confidence.Scope: native backend architecture from pinned config metadata; no pretrained execution. The image path is shown.Source: libreyolo/models/ground/qwen3vl.py; Transformers 5.16.1. Revision a4d0ecc9e17f.libreyolo.com