Model reference · open weights

pixtral

LLMs mistral-experimental Vision + text 1 build Open weights 137k dl/mo

pixtral is an open-weight language model from mistral-experimental. pixtral-12b (BF16) weighs 25.4 GB; the smallest configuration that runs it is RTX 5090 32 GB.

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

  • Pixtral is a 12.7B parameter image-text-to-text model developed by mistral-experimental.
  • It supports a context length of 1,024,000 tokens and is released under the Apache-2.0 license.
  • The model is designed to process multiple images and text inputs, allowing for interleaved image and text content within chat templates.

Summary of the mistral-experimental/pixtral-12b model card, 2026-10-01

What it is

Released bymistral-experimental
Released2024-09-13
Parameters12.7B
VRAM25.4 GB for the weights

What it runs on

Memory and cards for pixtral-12b (BF16)

25.4 GBweights, file size
164 MBcache per 1K tokens
2.1 GBruntime overhead, at least
1,024,000 tokenscontext max
CardRequests at onceContext maxMemory
8K each32K each
RTX 3060 12 GB … RTX 4090 24 GB
4 smaller cards
RTX 5090 32 GB221K31.0 GB
L40S 48 GB12398K44.0 GB
A100 80 GB379302K78.2 GB
H100 80 GB348277K78.1 GB
RTX PRO 6000 Blackwell 96 GB4611370K93.8 GB
DGX Spark (GB10) 128 GB unified5614451K107 GB
H200 141 GB7919633K138 GB
B200 180 GB10726856K176 GB
Memory needed at each load
Requests at once8K tokens each32K tokens each
128.8 GB32.8 GB
534.1 GB54.3 GB
838.2 GB70.4 GB
1648.9 GB113 GB
3270.4 GB199 GB
64113 GB371 GB

One card, with vLLM's small-card settings.

From the model card

What mistral-experimental says about pixtral

Read the model card

Transformers compatible pixtral checkpoints. Make sure to install from source or wait for v4.45!

Usage example

from PIL import Image
from transformers import AutoProcessor, LlavaForConditionalGeneration
model_id = "mistral-community/pixtral-12b"
model = LlavaForConditionalGeneration.from_pretrained(model_id)
processor = AutoProcessor.from_pretrained(model_id)

IMG_URLS = [
"https://picsum.photos/id/237/400/300",
"https://picsum.photos/id/231/200/300",
"https://picsum.photos/id/27/500/500",
"https://picsum.photos/id/17/150/600",
]
PROMPT = "[INST]Describe the images.\n[IMG][IMG][IMG][IMG][/INST]"

inputs = processor(text=PROMPT, images=IMG_URLS, return_tensors="pt").to("cuda")
generate_ids = model.generate(**inputs, max_new_tokens=500)
output = processor.batch_decode(generate_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]

You should get an output similar to the below:


"""
Describe the images.
Sure, let's break down each image description:

1. **Image 1:**
   - **Description:** A black dog with a glossy coat is sitting on a wooden floor. The dog has a focused expression and is looking directly at the camera.
   - **Details:** The wooden floor has a rustic appearance with visible wood grain patterns. The dog's eyes are a striking color, possibly brown or amber, which contrasts with its black fur.

2. **Image 2:**
   - **Description:** A scenic view of a mountainous landscape with a winding road cutting through it. The road is surrounded by lush green vegetation and leads to a distant valley.
   - **Details:** The mountains are rugged with steep slopes, and the sky is clear, indicating good weather. The winding road adds a sense of depth and perspective to the image.

3. **Image 3:**
   - **Description:** A beach scene with waves crashing against the shore. There are several people in the water and on the beach, enjoying the waves and the sunset.
   - **Details:** The waves are powerful, creating a dynamic and lively atmosphere. The sky is painted with hues of orange and pink from the setting sun, adding a warm glow to the scene.

4. **Image 4:**
   - **Description:** A garden path leading to a large tree with a bench underneath it. The path is bordered by well-maintained grass and flowers.
   - **Details:** The path is made of small stones or gravel, and the tree provides a shaded area with the bench invitingly placed beneath it. The surrounding area is lush and green, suggesting a well-kept garden.

Each image captures a different scene, from a close-up of a dog to expansive natural landscapes, showcasing various elements of nature and human interaction with it.
"""

Usage with chat template

You can also use a chat template to format your chat history for Pixtral. Make sure that the images argument to the processor contains the images in the order that they appear in the chat, so that the model understands where each image is supposed to go.

Here's an example with text and multiple images interleaved in the same message:

from PIL import Image
from transformers import AutoProcessor, LlavaForConditionalGeneration
model_id = "mistral-community/pixtral-12b"
model = LlavaForConditionalGeneration.from_pretrained(model_id)
processor = AutoProcessor.from_pretrained(model_id)

url_dog = "https://picsum.photos/id/237/200/300"
url_mountain = "https://picsum.photos/seed/picsum/200/300"

chat = [
    {
      "role": "user", "content": [
        {"type": "text", "content": "Can this animal"},
        {"type": "image"},
        {"type": "text", "content": "live here?"},
        {"type": "image"}
      ]
    }
]

prompt = processor.apply_chat_template(chat)
inputs = processor(text=prompt, images=[url_dog, url_mountain], return_tensors="pt").to(model.device)
generate_ids = model.generate(**inputs, max_new_tokens=500)
output = processor.batch_decode(generate_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]

From transformers>=v4.48, you can also pass image url or local path to the conversation history, and let the chat template handle the rest. Chat template will load the image for you and return inputs in torch.Tensor which you can pass directly to model.generate().

chat = [
    {
      "role": "user", "content": [
        {"type": "text", "content": "Can this animal"},
        {"type": "image", "url": url_dog},
        {"type": "text", "content": "live here?"},
        {"type": "image", "url" : url_mountain}
      ]
    }
]

inputs = processor.apply_chat_template(chat, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors"pt").to(model.device)
generate_ids = model.generate(**inputs, max_new_tokens=500)
output = processor.batch_decode(generate_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]

You should get something like this:

Can this animallive here?Certainly! Here are some details about the images you provided:

### First Image
- **Description**: The image shows a black dog lying on a wooden surface. The dog has a curious expression with its head tilted slightly to one side.
- **Details**: The dog appears to be a young puppy with soft, shiny fur. Its eyes are wide and alert, and it has a playful demeanor.
- **Context**: This image could be used to illustrate a pet-friendly environment or to showcase the dog's personality.

### Second Image
- **Description**: The image depicts a serene landscape with a snow-covered hill in the foreground. The sky is painted with soft hues of pink, orange, and purple, indicating a sunrise or sunset.
- **Details**: The hill is covered in a blanket of pristine white snow, and the horizon meets the sky in a gentle curve. The scene is calm and peaceful.
- **Context**: This image could be used to represent tranquility, natural beauty, or a winter wonderland.

### Combined Context
If you're asking whether the dog can "live here," referring to the snowy landscape, it would depend on the breed and its to

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