Model reference · open weights

idefics2

LLMs HuggingFaceM4 Vision + text 1 build Open weights 114k dl/mo

idefics2 is an open-weight language model from HuggingFaceM4. idefics2-8b (FP32) weighs 16.8 GB; the smallest configuration that runs it is RTX 4090 24 GB.

For self-hosting, compare this build's requirements below with the GPU you plan to rent.

  • Idefics2 is an open multimodal model developed by HuggingFaceM4 that accepts arbitrary sequences of image and text inputs to produce text outputs.
  • It is designed for tasks such as visual question answering, image captioning, and document understanding, with enhanced capabilities in OCR and visual reasoning.
  • The model contains 8.4B parameters, supports a context length of 32,768 tokens, operates in English, and is released under the Apache 2.0 license.

Summary of the HuggingFaceM4/idefics2-8b model card, 2026-10-01

What it is

Released byHuggingFaceM4
Released2024-04-09
Parameters8.4B
VRAM16.8 GB for the weights

What it runs on

Memory and cards for idefics2-8b (FP32)

16.8 GBweights, file size
2.1 GBruntime overhead, at least
32,768 tokenscontext max

How much memory each request adds isn't estimated yet for this architecture. The weights need at least the cards below, plus room for the context.

CardWeights alone
RTX 3060 12 GB … RTX 4060 Ti 16 GB
2 smaller cards
does not fit
RTX 3090 24 GBfits
RTX 4090 24 GBfits
RTX 5090 32 GBfits
L40S 48 GBfits
A100 80 GBfits
H100 80 GBfits
RTX PRO 6000 Blackwell 96 GBfits
DGX Spark (GB10) 128 GB unifiedfits
H200 141 GBfits
B200 180 GBfits

From the model card

What HuggingFaceM4 says about idefics2

Read the model card

[!WARNING] Idefics2 will NOT work with Transformers version between 4.41.0 and 4.43.3 included. See the issue https://github.com/huggingface/transformers/issues/32271 and the fix https://github.com/huggingface/transformers/pull/32275

[!IMPORTANT] As of April 18th, 2024, Idefics2 is part of the 4.40.0 Transformers pypi release. Please upgrade your Transformers version (pip install transformers --upgrade).

Idefics2

Idefics2 is an open multimodal model that accepts arbitrary sequences of image and text inputs and produces text outputs. The model can answer questions about images, describe visual content, create stories grounded on multiple images, or simply behave as a pure language model without visual inputs. It improves upon Idefics1, significantly enhancing capabilities around OCR, document understanding and visual reasoning.

We release under the Apache 2.0 license 2 checkpoints:

  • idefics2-8b-base: the base model
  • idefics2-8b: the base model fine-tuned on a mixture of supervised and instruction datasets (text-only and multimodal datasets)
  • idefics2-8b-chatty: idefics2-8b further fine-tuned on long conversation

Model Summary

Uses

idefics2-8b-base and idefics2-8b can be used to perform inference on multimodal (image + text) tasks in which the input is composed of a text query along with one (or multiple) image(s). Text and images can be arbitrarily interleaved. That includes image captioning, visual question answering, etc. These model does not support image generation.

For optimal results, we recommend fine-tuning idefics2-8b on one's specific use-case and data. In fact, the instruction-fine-tuned model (idefics2-8b) is significantly better at following instructions from users and thus should be preferred when using the models out-of-the-box or as a starting point for fine-tuning.

idefics2-8b usually generates very short answers. For long generations, use idefics2-8b-chatty, which was further fine-tuned on long conversations.

As a starting point, we provide fine-tuning codes that can be adapted for one's particular scenario:

Technical summary

Idefics2 exhibits strong performance for a model of its size (8B parameters) when compared to other open multimodal models and is often competitive with closed-source systems. As such, it serves as a strong foundation for various use-case specific fine-tunings.

ModelOpen weightsSize# tokens per imageMMMU (val/test)MathVista (testmini)TextVQA (val)MMBench (test)VQAv2 (test-dev)DocVQA (test)
DeepSeek-VL✅7B57636.6/-36.164.473.2-49.6
LLaVa-NeXT-Mistral-7B✅7B288035.3/-37.765.768.782.2-
LLaVa-NeXT-13B✅13B288036.2/-35.367.170.082.8-
LLaVa-NeXT-34B✅34B288051.1/44.746.569.579.383.7-
MM1-Chat-7B❌7B72037.0/35.635.972.872.3--
MM1-Chat-30B❌30B72044.7/40.339.473.575.183.7
Gemini 1.0 Pro❌🤷‍♂️🤷‍♂️47.9/-45.274.6-71.288.1
Gemini 1.5 Pro❌🤷‍♂️🤷‍♂️58.5/-52.173.5-73.286.5
Claude 3 Haiku❌🤷‍♂️🤷‍♂️50.2/-46.4---88.8
Idefics1 instruct (32-shots)✅80B---39.3-68.8-
Idefics2 (w/o im. split)✅8B6443.5/37.951.670.476.880.867.3
Idefics2 (w/ im. split)✅8B32043.0/37.751.473.076.781.274.0

Idefics2 introduces several carefully abalated improvements over Idefics1:

  • We manipulate images in their native resolutions (up to 980 x 980) and native aspect ratios by following the NaViT strategy. That circumvent the need to resize images to fixed-size squares as it has been historically been done in the computer vision community. Additionally, we follow the strategy from SPHINX and (optionally) allow sub-image splitting and passing **

Quoted from the model card on Hugging Face. The full card is behind the Hugging Face link above.

© 2026 AxForge · EU-hosted AI infrastructure Pricing Docs Trust Privacy Terms