Instructions to use dmis-lab/Gemma3-4B-CVRR with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use dmis-lab/Gemma3-4B-CVRR with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("visual-question-answering", model="dmis-lab/Gemma3-4B-CVRR", trust_remote_code=True)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("dmis-lab/Gemma3-4B-CVRR", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Gemma3-4B-CVRR
Introduction
Latent visual reasoning is not just about storing visual information in hidden states. That information should matter for the model's answer. When an answer decoder can access the original multimodal context through a parallel path, the presence of informative latent states alone does not establish their use.
Our work, Reason Through the Latent! Making Latent Visual Reasoning Necessary, introduces Causal Visual Recurrent Reasoning (CVRR). CVRR separates visual access during reasoning from visual access during answering, focusing on three design principles:
ποΈ Preserving pretrained visual competence
Reasoning starts from the native image-conditioned question representation,
preserving visual information already integrated by the pretrained VLM.
π Refining reasoning with persistent visual evidence
A shared native decoder layer updates the question state while retaining access
to fixed visual evidence. The recurrent transition is adapted with LoRA and
answer-token supervision.
π Making the reasoning state the visual answer interface
The upper answer decoder receives the final recurrent question state, without
direct access to the original visual rows or original multimodal prefix caches.
The lower-layer prefix context used for answer generation follows a text-only path.
Model Checkpoints
Final Models
We release CVRR checkpoints based on the following pretrained vision-language backbones. Each repository contains the native backbone weights, the merged recurrent transition, and the custom inference code; no separate LoRA download is required.
- π€ Qwen2.5-VL-7B-CVRR
- π€ Qwen3-VL-8B-CVRR
- π€ Gemma3-4B-CVRR
- π€ Gemma3-12B-CVRR
- π€ Gemma4-12B-CVRR
- π€ InternVL3-9B-CVRR
This checkpoint is based on google/gemma-3-4b-it.
Loading
Download the complete repository and install its model-specific dependencies:
hf download dmis-lab/Gemma3-4B-CVRR --local-dir ./Gemma3-4B-CVRR
pip install -r ./Gemma3-4B-CVRR/requirements.txt
import torch
from PIL import Image
from transformers import AutoModelForImageTextToText
model = AutoModelForImageTextToText.from_pretrained(
"./Gemma3-4B-CVRR",
trust_remote_code=True,
dtype=torch.bfloat16,
device_map="cuda:0",
).eval()
image = Image.open("example.jpg").convert("RGB")
inputs = model.prepare_inputs(
image,
"What is the dominant color? A. Red B. Blue C. Green D. Yellow. Answer with the option letter.",
)
logits = model.next_token_logits(**inputs)
token_id = logits.argmax(dim=-1).item()
print(model.tokenizer.decode([token_id]))
This model exposes the strict first-answer-token readout used in our analyses. Multi-token generation is not currently supported by this loader.
Use one complete model replica per GPU. This custom Transformers loader does
not support automatic model sharding, generic save_pretrained() reserialization,
or direct loading through vLLM/SGLang. Preserve the downloaded directory and
pin the Hub revision for reproducible use.
License
Please follow the upstream model's terms and the included
NOTICE.txt and licenses/ attribution files.
The component licenses remain applicable to their respective materials.
Citation
@misc{park2026reasonlatentmakinglatent,
title={Reason Through the Latent! Making Latent Visual Reasoning Necessary},
author={Suhyeong Park and Junha Jung and Jaewoo Kang},
year={2026},
eprint={2609.06746},
archivePrefix={arXiv},
primaryClass={cs.AI},
url={https://arxiv.org/abs/2609.06746},
}
- Downloads last month
- -