Editorial

Qwen-Image-2.1 VRAM: 7B Model, 31 GiB to Load

Qwen-Image-2.1's 7B DiT ships with an 8.8B text encoder: 30.8 GiB at BF16, 9.3 GiB as Q4 GGUF. GPU fit, settings and license.

JJyoti Ranjan SwainUpdated
Qwen-Image-2.1 VRAM: a 7B DiT plus an 8.8B text encoder, 30.8 GiB at BF16 and 9.3 GiB as Q4 GGUF

Qwen-Image-2.1 came out on 20 September 2026 as a "7B" image model that generates and edits pictures, including transparent PNGs, in one set of weights. The 7B is real, but it counts only the image generator. Your prompt goes through a separate Qwen3-VL 8B text encoder first, and that encoder is bigger than the generator. The official repo is 30.8 GiB of weights.

Below: what each part costs in VRAM, which quantized files fit 8, 12, 16 and 24 GB cards, and a license change that matters more than any of it if you plan to sell what you make.

Table of contents

What the 7B leaves out

Qwen's model card describes "7B parameters in its visual generation component (32 Single-Stream DiT layers)". The pipeline in model_index.json has four pieces, and only one of them is that component:

PartClassParametersJob
Text encoderQwen3VLForConditionalGeneration8.77BReads the prompt and any reference images
Transformer (DiT)QwenImage21Transformer2DModelabout 7.12BDenoises the image latent, 40 steps by default
VAEAutoencoderKLQwenImage210.34BTurns the latent into pixels, 16x upscale
SchedulerFlowMatchEulerDiscreteSchedulernoneStep timing

The encoder count comes from its safetensors index (total_parameters: 8,767,123,696). The DiT figure is its 14.23 GB of BF16 weights divided by 2 bytes. A "7B model" is really a 16B-parameter pipeline, with about 16.2B parameters on hand to make one image.

Official repo size

The Qwen/Qwen-Image-2.1 repo stores the encoder and DiT in BF16 and the VAE in FP32:

PartStored asSize
Text encoder (4 shards)BF1616.33 GiB
DiT (2 shards)BF1613.25 GiB
VAEFP321.26 GiB
Total30.84 GiB

Qwen-Image-2.1 BF16 weights by part: text encoder 16.33 GiB, DiT 13.25 GiB, VAE 1.26 GiB, 30.84 GiB in total

The model card's quick start loads everything with .to("cuda"), which needs a 40 GB-class card before a single activation is allocated. Its memory line, pipe.enable_model_cpu_offload(), moves each part onto the GPU only while it runs. The encoder finishes before denoising starts, so with offloading the peak is the largest single part.

That part is the encoder at 16.33 GiB, not the DiT. A 16 GB card has about 14.9 GiB in the units these files use, so BF16 with offloading still doesn't fit. On a 24 GB card it does.

Quantized files by GPU size

Hardly anyone runs the official BF16 files. In the two weeks since launch, ComfyUI's repack (Comfy-Org/Qwen-Image-2.1) and Unsloth's GGUF upload each have several times the downloads of the base repo. These are the common combinations, using the file sizes listed on Hugging Face:

SetupDiTText encoderVAE (BF16)Weights total
Official BF1613.2516.331.26 (FP32)30.84 GiB
ComfyUI INT8 + INT8 encoder6.768.710.6316.10 GiB
GGUF Q8_0 + Q8_0 encoder7.128.110.6315.86 GiB
ComfyUI INT8 + W4A8 encoder6.765.880.6313.27 GiB
GGUF Q4_K_M + UD-Q4_K_XL encoder3.914.800.639.34 GiB

Qwen-Image-2.1 weight totals vs GPU size: Q4 GGUF 9.3 GiB fits 12 GB, INT8 16.1 GiB needs 24 GB, BF16 30.8 GiB

These are weights only. Activations come on top and grow with resolution, so leave a few GiB free. Unsloth's guide gives the starting points below and says they are estimates, not tested minimums:

  • 12 to 16 GB VRAM: GGUF Q4_K_M at 1024 x 1024, batch 1
  • 24 GB VRAM: INT8 or FP8 at 512 x 512, or GGUF Q4_K_M at 1024 x 1024
  • 6 GB VRAM: FP8 with offloading, which Unsloth says runs under 2x slower
  • Mac or CPU only: GGUF Q4_K_M with the Q4_K_XL encoder in 12 to 16 GB of RAM

On an 8 GB card the Q4 pair is 9.34 GiB, so you will be offloading the encoder whatever you do. On 12 GB, try the Q4 GGUF pair first. On 24 GB I would start with the INT8 DiT, since Unsloth's own quant test gave INT8 a mean LPIPS of 0.064 against 0.112 for FP8 at almost the same file size.

The arithmetic is parameters times bytes per parameter for any model. Our AI VRAM Calculator does it for LLMs with KV cache on top, and our local LLM VRAM guide explains each term if you are sizing a card for both chat and images.

Resolution and attention cost

The VAE config sets scale_factor_spatial: 16, and the DiT uses patch_size: 1, so each image token covers a 16 x 16 pixel block:

ResolutionImage tokensRelative attention work
1024 x 10244,0961x
2048 x 2048 (native 1:1)16,384about 16x
2752 x 1536 (native 16:9)16,512about 16x

Doubling the side quadruples the tokens, and self-attention cost grows with the square of the token count. Every native preset in the model card sits around 16,400 tokens. Unsloth and the ComfyUI community both start people at 1024 x 1024 even though the model is sold on 2K output. Generate at 1024, keep the seeds you like, and rerun only those at full size.

For editing, Qwen's blog says reference images and instructions are encoded once in the first step and reused through a prefix KV cache. Up to 10 reference images are supported. Each adds tokens to that cache, so a 10-image try-on uses more memory than a plain prompt at the same output size.

Running it locally

With 12 to 16 GB of VRAM, stable-diffusion.cpp plus Unsloth's GGUFs is the lightest path. You need three files: the DiT GGUF, the BF16 VAE, and the Qwen3-VL encoder GGUF.

bash
# Files (Hugging Face):
#   unsloth/Qwen-Image-2.1-GGUF        -> qwen-image-2.1-Q4_K_M.gguf          (3.91 GiB)
#   unsloth/Qwen-Image-2.1-FP8         -> vae/qwen_image_2.1_vae_bf16.safetensors (0.63 GiB)
#   unsloth/Qwen3-VL-8B-Instruct-GGUF  -> Qwen3-VL-8B-Instruct-UD-Q4_K_XL.gguf (4.80 GiB)

sd-cli --diffusion-model qwen-image-2.1-Q4_K_M.gguf \
  --vae qwen_image_2.1_vae_bf16.safetensors \
  --llm Qwen3-VL-8B-Instruct-UD-Q4_K_XL.gguf \
  -p "a cartoon sloth mascot waving, flat vector illustration" \
  --steps 20 --cfg-scale 6.0 --sampling-method euler \
  -W 1024 -H 1024 --diffusion-fa -o out.png

On 24 GB with diffusers, use the official pipeline with offloading and keep guidance at 1.0:

python
import torch
from diffusers import QwenImage21Pipeline

pipe = QwenImage21Pipeline.from_pretrained(
    "Qwen/Qwen-Image-2.1", torch_dtype=torch.bfloat16
)
pipe.enable_model_cpu_offload()  # peak = largest part (the 16.3 GiB encoder)

image = pipe(
    prompt="This is an RGBA image with transparency. A paper lantern sticker. "
           "The image has alpha channel and the background is transparent.",
    width=1024, height=1024,
    num_inference_steps=40,
    generator=torch.Generator("cuda").manual_seed(42),
).images[0]
image.save("lantern.png")

The two recipes use different settings. Unsloth's guide lists 40 steps with CFG disabled (guidance 1.0) for diffusers, and 20 steps at CFG 6.0 for stable-diffusion.cpp. Copy a CFG of 6 into diffusers, or 1.0 into sd.cpp, and your outputs won't match anyone else's.

The transparent prompt is the format Qwen's card recommends. The model decides from the prompt text whether to return RGB or RGBA, so if you want transparency, ask for it in words. Our Image Prompt Generator can draft the descriptive part, and you add the RGBA sentences around it.

License, encoder size and app limits

The license changed. The first Qwen-Image (August 2025) and Qwen-Image-2512 are Apache 2.0. Qwen-Image-2.1 ships under the Qwen Research License, which grants use "FOR NON-COMMERCIAL PURPOSES ONLY" and defines non-commercial as "research or evaluation purposes only". Commercial use needs a separate licence from model-business@notice.qwencloud.com. If you make thumbnails for a monetised channel, product shots for a shop or client work, the model isn't cleared for that out of the box, and every quantized repo above inherits the same licence. Until Qwen grants you one, use it for experiments and keep commercial work on an Apache 2.0 model.

Quantize the encoder first. Most guides focus on the DiT quant, but the encoder is 53% of the BF16 download. Going from the BF16 encoder (16.33 GiB) to UD-Q4_K_XL (4.80 GiB) saves more memory than taking the DiT from BF16 all the way to Q4.

The Unsloth desktop app does only text-to-image for now. Its guide says this release supports text-to-image only in the app, although the same page also shows an edit tab. For multi-image editing and masks, diffusers or ComfyUI are the safer routes today.

FAQ

How much VRAM does Qwen-Image-2.1 need?

The full BF16 weights are 30.84 GiB. With CPU offload the peak is about 16.3 GiB (the text encoder). Q4 GGUF files total 9.34 GiB, and Unsloth suggests 12 to 16 GB of VRAM for 1024 x 1024.

Can Qwen-Image-2.1 run on an 8 GB GPU?

Yes, with offloading. The Q4 weights are 9.34 GiB, a bit more than 8 GB holds, so part of the model has to sit in system RAM. Expect it to be slower than on a 12 GB card.

Is Qwen-Image-2.1 free for commercial use?

No. It uses the Qwen Research License, which allows research and evaluation only. Earlier Qwen-Image releases were Apache 2.0.

What resolution should I start at?

1024 x 1024. It uses 4,096 image tokens, against about 16,400 for the native 2K presets, so it fits smaller cards and runs much faster. At full precision the whole pipeline is 30.84 GiB, and the INT8 or Q8 pair is about 16 GiB, so 24 GB cards get INT8 and 12 GB cards get Q4.

Sources

  • Hugging Face, Qwen/Qwen-Image-2.1 model card, model_index.json, transformer, VAE and text-encoder config.json, safetensors indexes and file listing: parameter counts, layer counts, 16x VAE scale, file sizes, aspect-ratio presets, quick-start code.
  • Qwen blog, "Qwen-Image-2.1: Compact, Efficient, and Unified Image Creation" (20 September 2026): 7B visual component, 32 DiT layers, prefix KV cache reuse, 10 reference images, transparency.
  • Qwen Research License Agreement, release date 20 September 2026 (LICENSE file in the model repo): non-commercial grant and commercial licence contact.
  • Unsloth Docs, "Qwen-Image-2.1: How to Run Locally": memory starting points, INT8 vs FP8 LPIPS table, recommended settings per backend, text-to-image-only note.
  • Hugging Face file listings for unsloth/Qwen-Image-2.1-GGUF, unsloth/Qwen-Image-2.1-FP8, unsloth/Qwen3-VL-8B-Instruct-GGUF and Comfy-Org/Qwen-Image-2.1: quantized file sizes and the stable-diffusion.cpp command.
  • Hugging Face model pages for Qwen/Qwen-Image and Qwen/Qwen-Image-2512: Apache 2.0 licence.
  • Combined totals, offload peaks and token counts are calculated by ToolMintX from the figures above.

Tools In This Article

Browser-based, no sign-up. Try them while the topic is fresh.

More From ToolMintX

Other Blog Posts