Self-hosting Qwen-Image-2.1 means downloading about 33 GB, not the roughly 14 GB that “7B” suggests, and the weights are free only for non-commercial use. The 33 GB figure rounds the sum of the component sizes in the Hugging Face file listing, which the memory section below breaks down; it matches the 33.1 GB download that the third-party Gufo image server’s documentation gives. The model’s official repository lists two checkpoints: the base model at 40 denoising steps and Qwen-Image-2.1-Turbo at 8. EcoHash’s benchmark on one RTX PRO 6000 measured 9.4 seconds per image of about 1 megapixel in BF16, with 36.8 GiB of peak GPU memory. This guide settles the checkpoint, the licence and the memory budget first, then covers the install, the routes for cards under 24 GB and the cost per 1,000 images.
Don't miss new tech stories on Google
Add Tech Insider once in the Google app and our stories appear in your news suggestions.
Base at 40 steps, Turbo at 8, or Alibaba’s hosted API
According to the repository, Turbo uses the same 7B visual generation architecture as the base model and supports text-to-image generation and image editing with 8 denoising steps. In the scripts below, only the repository id and the step count change between the two checkpoints.
| Checkpoint | Hugging Face repository | Released | Denoising steps | Suited to |
|---|---|---|---|---|
| Qwen-Image-2.1 (base) | Qwen/Qwen-Image-2.1 | September 20, 2026 | 40 | Maximum quality, final output, multi-image editing |
| Qwen-Image-2.1-Turbo | Qwen/Qwen-Image-2.1-Turbo | October 9, 2026 | 8 | Drafts, rapid iteration, batch jobs |
The 7B counts the visual generation component only, which the model card describes as 32 single-stream DiT layers. The card’s reasons to run it yourself are up to 10 reference images per edit, local edits specified by circles, painted annotations or separate masks, identity preservation for people and products, and native transparent (RGBA) output from text, alongside subject extraction from photographs.
On quality, as checked on November 12, 2026, gradually.ai lists the model at rank 14 of 21 in its arena, with an arena rating of 1,227 from 17,883 votes (the figures are on its Qwen-Image-2.1 and Turbo comparison page), and at rank 22 of 108 on GraduallyBench Image v2 with a score of 74 on a 0 to 100 scale. GraduallyBench is that site’s own benchmark. Read together, that is a capable open-weight model rather than a leaderboard leader, so judge it on your own prompts.
If you would rather not run a GPU, the repository’s October 9, 2026 entry announces that the Pro and Turbo APIs are live on Alibaba Cloud Model Studio, and Alibaba Cloud’s list of newly released Model Studio models shows qwen-image-2.1-pro on October 2, 2026. Our Qwen Image API setup guide covers the Model Studio account, API key and SDK steps for a hosted Qwen image API.
The weights are free to download, but the licence stops at commercial use
The weights ship under the Qwen Research License, which gradually.ai summarises as allowing non-commercial use while commercial projects need a separate licence. The LICENSE file on the Turbo repository is explicit:
You shall not use the Materials for any commercial purpose without obtaining a separate commercial license from us.
So “free” in this guide means free of per-image fees and free to download. It does not mean free to put into a paid product. The LICENSE defines non-commercial as for research or evaluation purposes only, so the self-hosted route is open for research and evaluation; check a personal project or prototype against the licence text before relying on it. For client work, a product feature or anything sold, the options are a commercial licence from Alibaba or the hosted API, and the break-even calculation in the cost section applies only after one of those is settled. Read the LICENSE file in the repository you pull from before you accept it. Our report on the release covers the licence fine print in more detail.
Where 33 GB comes from, and which cards can hold it
Running the model takes three pieces: the denoiser, the Qwen3-VL text encoder and the VAE. Codersera’s guide notes that the text encoder is often bigger than the denoiser. As checked on November 12, 2026, the Hugging Face file listing shows the Qwen3-VL text encoder at 17.5 GB, the transformer at about 14.2 GB and the VAE at 1.35 GB, which add up to about 33.1 GB. That matches the download of about 33.1 GB that the documentation of Gufo, a third-party image server, tells users to expect, and it is the figure this guide rounds to 33 GB.
Memory in use is higher than the weights alone. EcoHash ran one RTX PRO 6000 in BF16 at 40 steps with batch size 1 and recorded an average peak of 36.8 GiB at about 1 megapixel and 56.5 GiB at native 2048 x 2048. Those are GiB, so 36.8 GiB is about 39.5 GB. The figures are EcoHash’s, not ours, and the table below marks which rows are measured and which are estimates.
| Hardware | Route or result | Basis |
|---|---|---|
| RTX PRO 6000, about 1 MP, BF16, 40 steps, batch 1 | 9.4 s per image, 36.8 GiB average peak memory | Measured by EcoHash |
| Same card, native 2048 x 2048 | 52.0 s per image, 56.5 GiB peak memory | Measured by EcoHash |
| A 48 GB card or larger | BF16 on the GPU at about 1 MP; native 2048 x 2048 does not fit in 48 GB at the measured peak | Estimate from the two measured peaks, which were taken on a different card |
| A 32 GB card | BF16 with enable_model_cpu_offload(), or the ComfyUI INT8 files | Estimate: the BF16 weights are about 33.1 GB in total, above 32 GB, and the measured peak was 36.8 GiB; the offload call is from the model card |
| 16 to 24 GB | ComfyUI with the Comfy-Org INT8 files; in Diffusers, enable_model_cpu_offload() | Codersera calls the INT8 files the easiest local route on this class; EcoHash did not test quantization or CPU offload |
| 8 to 12 GB | Q4_K_M or Q5 GGUF through the leejet ComfyUI-GGUF node | Codersera’s suggestion; the text encoder files alone are 17.5 GB, so the encoder must be quantised or offloaded |
| No NVIDIA card | AMD Radeon through ROCm, PyTorch and Diffusers; Apple Silicon and Intel as listed in the Qwen README; Gufo’s OpenAI-compatible image server on AMD Strix Halo; or the hosted API | Qwen README and Gufo documentation as of November 12, 2026; Gufo download 33.1 GB; no speed figures for these routes |
Going from about 1 megapixel to 2048 x 2048 is roughly four times the pixels. Time rose 5.5 times (52.021 s against 9.378 s) and peak memory 1.54 times (56.5 against 36.8 GiB), so size the card for the resolution you will really use. EcoHash says it did not test batching, reduced-step schedules, quantization, CPU offload or other inference runtimes, so its figures say nothing about the routes in the next two sections.
On maximum size: as of November 12, 2026, the repository says Qwen-Image-2.1 natively supports 2K resolution and lists recommended sizes by aspect ratio. Its longest edge among those presets is 2752 pixels, which is a preset, not a stated maximum output size. Gufo’s documentation allows up to 4096 pixels per side.
From an empty environment to a first image
The model card’s install line pins torch at 2.4.0 or newer and transformers at 5.17 or newer, installs Diffusers from its GitHub source, and adds accelerate and pillow. The repository says “Diffusers supports Qwen-Image-2.1 from Day 0 via QwenImage21Pipeline”. Because the card installs Diffusers from source, a PyPI release may not contain that class, and the transformers pin suggests the Qwen3-VL encoder needs a recent release. Both are inferences from the pins.
By hand, the steps are: create an environment, install the pinned packages, confirm that PyTorch sees the GPU, clone the repository for its README and examples, and download the weights.
# 1. Create and activate an environment (conda shown; the script below uses venv instead)
conda create -n qwen-image pip
conda activate qwen-image
# 2. Install the pins from the model card
pip install "torch>=2.4.0"
pip install "transformers>=5.17"
pip install git+https://github.com/huggingface/diffusers
pip install accelerate pillow huggingface_hub
# 3. Check that PyTorch sees the GPU
python -c "import torch; print(torch.cuda.is_available())"
# 4. Clone the repository for its README and examples
git clone https://github.com/QwenLM/Qwen-Image-2.1
cd Qwen-Image-2.1
# 5. Log in if you want an authenticated download, then fetch the weights
huggingface-cli login
huggingface-cli download Qwen/Qwen-Image-2.1 --local-dir "$HOME/models/qwen-image-2.1"
The script below does the same environment, install and download steps in one run, with a venv. It checks that the driver sees the card first, stops on the first error and tells you where, and the download resumes when you rerun it. Pass the Turbo repository id as the third argument and a different weights directory to fetch the Turbo checkpoint.
#!/usr/bin/env bash
# usage: setup_qwen_image.sh VENV_DIR WEIGHTS_DIR [REPO_ID]
set -euo pipefail
trap 'echo "setup stopped at line $LINENO; rerun to resume the download" >&2' ERR
venv_dir="${1:?usage: setup_qwen_image.sh VENV_DIR WEIGHTS_DIR [REPO_ID]}"
weights_dir="${2:?usage: setup_qwen_image.sh VENV_DIR WEIGHTS_DIR [REPO_ID]}"
repo_id="${3:-Qwen/Qwen-Image-2.1}"
# The driver must see the card before anything else is installed
nvidia-smi --query-gpu=name,memory.total --format=csv
python3 -m venv "$venv_dir"
"$venv_dir/bin/pip" install --upgrade pip
"$venv_dir/bin/pip" install "torch>=2.4.0" "transformers>=5.17" accelerate pillow huggingface_hub
"$venv_dir/bin/pip" install "git+https://github.com/huggingface/diffusers"
"$venv_dir/bin/python" -c "import torch; print('cuda available:', torch.cuda.is_available())"
mkdir -p "$weights_dir"
"$venv_dir/bin/python" - "$repo_id" "$weights_dir" <<'PY'
import sys
from huggingface_hub import snapshot_download
snapshot_download(repo_id=sys.argv[1], local_dir=sys.argv[2])
PY
du -sh "$weights_dir"
Then a text-to-image script. The prompt and step count are the only generation arguments it passes; resolution and the other options are on the model card. Without --offload the whole pipeline goes onto the GPU.
# generate.py
import argparse
import time
import torch
from diffusers import QwenImage21Pipeline
parser = argparse.ArgumentParser()
parser.add_argument("weights_dir")
parser.add_argument("output")
parser.add_argument("--steps", type=int, required=True)
parser.add_argument("--offload", action="store_true")
args = parser.parse_args()
pipe = QwenImage21Pipeline.from_pretrained(args.weights_dir, torch_dtype=torch.bfloat16)
if args.offload:
pipe.enable_model_cpu_offload()
else:
pipe.to("cuda")
prompt = "A weathered brass telescope on a wooden ship deck at sunset, warm golden light, photorealistic"
start = time.perf_counter()
image = pipe(
prompt=prompt,
num_inference_steps=args.steps,
).images[0]
elapsed = time.perf_counter() - start
image.save(args.output)
print(f"seconds for this image: {elapsed:.1f}")
print(f"peak allocated GPU memory: {torch.cuda.max_memory_allocated() / 2**30:.1f} GiB")
bash setup_qwen_image.sh "$HOME/venvs/qwen-image" "$HOME/models/qwen-image-2.1"
"$HOME/venvs/qwen-image/bin/python" generate.py "$HOME/models/qwen-image-2.1" first.png --steps 40
# Turbo: same script, other repository id and weights directory, 8 steps
bash setup_qwen_image.sh "$HOME/venvs/qwen-image" "$HOME/models/qwen-image-2.1-turbo" Qwen/Qwen-Image-2.1-Turbo
"$HOME/venvs/qwen-image/bin/python" generate.py "$HOME/models/qwen-image-2.1-turbo" first-turbo.png --steps 8
The last two lines of the script print the seconds taken and the peak allocated GPU memory, the same kind of figures EcoHash reports, so you can set your card’s numbers against the 9.4 seconds and 36.8 GiB above when your resolution and step count match theirs. For editing with reference images, the shape of the call is below, continuing from the pipeline loaded in generate.py. The model supports up to 10 reference images per edit; take the exact argument names, and those for the RGBA cut-out and for mask and annotation edits, from the examples on the model card rather than from older tutorials.
from PIL import Image
prompt = "Place the product from the first image on the wooden table in the second image"
reference_images = [Image.open("product.png"), Image.open("table.png")]
edited = pipe(
prompt=prompt,
image=reference_images,
num_inference_steps=40,
).images[0]
edited.save("edited.png")
For a batch of prompts, loop over a list with the pipeline already loaded. This version assumes the Turbo weights and 8 steps, and it makes one image per call, the batch size 1 setting EcoHash measured.
from pathlib import Path
prompts = [
"A weathered brass telescope on a wooden ship deck at sunset, warm golden light, photorealistic",
"A lighthouse on a cliff in a storm, dramatic clouds, photorealistic",
]
output_dir = Path("batch_out")
output_dir.mkdir(exist_ok=True)
for i, prompt in enumerate(prompts):
image = pipe(prompt=prompt, num_inference_steps=8).images[0]
image.save(output_dir / f"image_{i}.png")
Under 24 GB: CPU offload, ComfyUI INT8, or a GGUF with leejet’s node
The model card’s memory-saving option is one call after loading in bfloat16. The peak-memory line from the script above shows whether it fits your card.
pipe = QwenImage21Pipeline.from_pretrained("Qwen/Qwen-Image-2.1", torch_dtype=torch.bfloat16)
pipe.enable_model_cpu_offload()
On a 16 to 24 GB card Codersera calls ComfyUI with the Comfy-Org INT8 files the easiest local route; if ComfyUI is new to you, our ComfyUI tutorial is the place to start. The ComfyUI documentation says the published pipeline uses about 40 to 50 steps with the euler sampler and that the base template starts lower, at 25 steps; Codersera adds that the template uses CFG 1. Raise the template’s step count before you compare its output with the Diffusers script.
For 8 to 12 GB cards, Codersera suggests a Q4_K_M or Q5 GGUF through the leejet ComfyUI-GGUF node. Unsloth publishes the quantisation as unsloth/Qwen-Image-2.1-GGUF. Its README says the GGUF is the denoiser only, so it needs the VAE and the Qwen3-VL text encoder alongside it, and a GGUF of a DiT needs a loader built for quantized DiT pipelines, such as stable-diffusion.cpp or ComfyUI-GGUF, rather than a standard llama.cpp runtime. The original city96 ComfyUI-GGUF node does not recognise this architecture, and Codersera reports users seeing an “Unknown model architecture!” error, so install the leejet version. Because the GGUF covers the denoiser, the encoder still has to fit or be offloaded, and its files alone are 17.5 GB, more than an 8 GB card can hold.
Readers without an NVIDIA card have several documented routes. As of November 12, 2026, the Qwen README says “Get ready to run Qwen-Image 2.1 on AMD Radeon GPU” with ROCm, PyTorch and Diffusers, and it also lists Apple Silicon (LightX2V-Mac-App) and Intel support. Gufo separately documents an OpenAI-compatible image server for Qwen-Image-2.1 on AMD Strix Halo, with the 33.1 GB download noted above.
Cost per 1,000 images, and when owning a card beats the API
EcoHash’s timings convert directly into throughput. 3,600 seconds divided by 9.378 seconds is about 384 images an hour at about 1 megapixel, so 1,000 images take 2.6 GPU-hours. At native 2048 x 2048, 3,600 divided by 52.021 is about 69 images an hour and 1,000 images take 14.5 GPU-hours. The table prices those hours at $1, $2 and $4 per GPU-hour. Those are assumed rental rates, not prices from any provider, so work from your own quote.
| Case | Seconds per image | Images per hour | GPU-hours per 1,000 | At $1 per hour | At $2 per hour | At $4 per hour |
|---|---|---|---|---|---|---|
| About 1 MP, base, 40 steps (EcoHash timing) | 9.4 | about 384 | 2.6 | $2.61 | $5.21 | $10.42 |
| Native 2048 x 2048, base, 40 steps (EcoHash timing) | 52.0 | about 69 | 14.5 | $14.45 | $28.90 | $57.80 |
| About 1 MP, Turbo, best case (estimate) | about 1.9 | about 1,900 | 0.52 | $0.52 | $1.04 | $2.08 |
The Turbo row is a floor, not a measurement. 8 steps is one fifth of 40, so denoising work drops by 5 times, and 9.378 seconds divided by 5 gives about 1.9 seconds. That holds only if time scales linearly with steps. The text encoder and the VAE run once per image whatever the step count, so the real gain is below 5 times. EcoHash did not test reduced-step schedules or batching, so every figure here is for batch size 1.
Electricity is small beside those rates. Energy per run is watts x seconds / 3,600,000 kWh. At an assumed 600 W and $0.15 per kWh, 1,000 images at the unrounded 9.378 seconds use about 1.56 kWh and cost about $0.23.
Owning a card turns the comparison into one break-even: images needed = card price / (API price per image minus power cost per image). With a hypothetical $3,000 card, a hypothetical API price of $0.04 per image and electricity ignored, that is 75,000 images, or 15 months at 5,000 images a month. Both prices are hypothetical, so put in your own quotes, including your hosted rate from Alibaba Cloud Model Studio.
The break-even applies only where the licence lets you run the model. For commercial output, either the cost of a commercial licence from Alibaba goes onto the card side of the sum, or the hosted API is the route and the volume comparison never starts. For research or evaluation use, the rental table and the formula decide whether to buy, rent or call the API.
Symptoms on day one, and the route that fits your card
| Symptom | Likely cause | Fix |
|---|---|---|
| ComfyUI reports “Unknown model architecture!” on a GGUF | The original city96 ComfyUI-GGUF node does not recognise this architecture | Use the leejet ComfyUI-GGUF node (Codersera) |
| Python cannot find QwenImage21Pipeline in diffusers | Diffusers came from PyPI, not source (inferred from the model card’s install line) | Reinstall from the GitHub source |
| The text encoder fails to load | transformers older than 5.17 (inferred from the pin) | Upgrade transformers to 5.17 or newer |
| Out of memory on a 24 GB card | BF16 weights are about 33.1 GB in total; EcoHash measured a 36.8 GiB peak on a larger card | Run with --offload, or use the ComfyUI INT8 files |
| ComfyUI images look weaker than the Diffusers script’s | The template starts at 25 steps with CFG 1; the published pipeline uses about 40 to 50 steps | Raise the steps before judging quality |
On a card of 48 GB or more and for research or evaluation, run the base checkpoint in BF16 through Diffusers for final images and Turbo for iteration. On 16 to 24 GB, take the ComfyUI route with INT8 files and use Turbo for drafts; on 8 to 12 GB, the leejet GGUF route is the one Codersera suggests, with the encoder offloaded or quantised. With no NVIDIA card, start from the AMD Radeon route in the Qwen README, or the hosted API. If the work is commercial, a commercial licence or the hosted Pro and Turbo APIs are the routes that fit. Training your own LoRA is a separate job, and our guide to training a custom image LoRA covers that workflow.





