Skip to main content

Text-to-Image · Diffusion Transformer

Self-hosting PixArt: the VRAM bill is not the 0.6B DiT, it is the 4.3B T5

PixArt-α, δ and Σ are three generations of DiT text-to-image models from the same team (Huawei Noah's Ark Lab × DLUT × HKU × HKUST). Every backbone is 0.6B parameters — an order of magnitude under SDXL's 2.6B and SD Cascade's 5.1B. The memory goes to the text encoder.

PixArt replaced the UNet with a pure Transformer backbone, and that single choice makes it feel nothing like the Stable Diffusion family in deployment. PixArt-α (arXiv 2310.00426, ICLR 2024 Spotlight) trained in 675 A100 GPU days — 10.8% of Stable Diffusion v1.5's 6,250 GPU days — cutting training cost from roughly $320,000 to roughly $26,000 and CO2 by about 90%. That arithmetic is what made it famous. PixArt-δ (arXiv 2401.05252) added LCM distillation and ControlNet; PixArt-Σ (arXiv 2403.04692) swapped in the SDXL VAE, raised the usable T5 token budget from 120 to 300, and introduced an attention module that compresses both keys and values so a 0.6B backbone can emit 2K and 4K directly.

So when you self-host PixArt, the backbone is almost free: 0.6B in fp16 is about 1.2GB of weights. What sits on your card is the frozen T5 v1.1-XXL text encoder — 4.3B parameters, roughly 9GB in fp16, the overwhelming majority of the pipeline. The official PixArt-α repo states it plainly: the native .pth inference path wants 23GB of VRAM by default, the diffusers path needs 11GB, and with memory optimizations you can go under 8GB. The diffusers documentation spells out that route: load T5 in 8-bit with bitsandbytes, run encode_prompt on its own, free the text encoder, then load the transformer with text_encoder=None. That keeps 1024px generation under 8GB; load_in_4bit takes it under 7GB.

Be clear about where this family stands today. Weights in the PixArt-alpha HuggingFace org were last updated in May 2024, and the research line moved on: core PixArt authors including Junsong Chen and Enze Xie went on to build SANA at NVlabs, with SANA-1.5 and SANA-Sprint landing in March 2025. PixArt remains an excellent asset anyway — Apache-2.0 code, a 0.6B footprint that makes fine-tuning and ablation cheap enough to run on a whim, and native 2K output that essentially nothing else at this parameter count offers. For wallpapers, posters and bulk asset pipelines, its per-image cost is very hard to beat.

01 —

PixArt variants and what each one costs in VRAM

Every backbone is 0.6B — the differences are resolution tier, VAE, T5 token length and distillation

VersionParametersVRAMContextNotes
PixArt-Sigma-XL-2-1024-MS0.6B backbone + T5-XXL 4.3B + SDXL VAE~11GB fp16 pipeline weights, ~17GB observed peak at 1024px; under 8GB with 8-bit T5, under 7GB with 4-bit300 T5 tokensThe mainstream checkpoint and the most downloaded PixArt weight on HuggingFace. Defaults are 20 steps and guidance_scale 4.5, and negative_prompt should be an empty string, not the long SD-style negative prompt you are used to.
PixArt-Sigma-XL-2-2K-MS0.6B backbone (identical parameter count to the 1024 tier)Same weights as the 1024 tier, but 2048x2048 attention activations are far heavier — start at 24GB300 T5 tokensNative 2048x2048 posters and wallpapers. The pipeline switches to ASPECT_RATIO_2048_BIN when transformer.config.sample_size == 256. Note that its HuggingFace README is empty, so the model card will not answer anything for you.
PixArt-Sigma-XL-2-512-MS0.6B backboneUnder 7GB on the 4-bit T5 path; unquantized it is still dominated by T5's ~9GB300 T5 tokensThe iteration and LoRA starting tier. PixArt-Sigma-XL-2-256x256 exists too, for the cheapest possible smoke tests.
PixArt-XL-2-1024-MS (PixArt-α)0.6B backbone + T5-XXL 4.3B + sd-vae-ft-ema 80M23GB on the native .pth path, ~11GB via diffusers fp16, under 8GB optimized120 T5 tokensThe previous generation. It carries the SD1.5-era VAE and truncates prompts at 120 tokens, which is the most direct reason to move to Sigma.
PixArt-LCM-XL-2-1024-MS (PixArt-δ)0.6B backbone, LCM distilledSame tier as α-1024120 T5 tokensThe official figure: 1024x1024 in 0.5 seconds on an A100 at 4 steps. The default choice for bulk generation pipelines. The same generation also ships PixArt-ControlNet at 0.9B (512 and 1024) with a 30M HED encoder.
PixArt-Alpha-DMD-XL-2-512x5120.6B backbone, DMD distilled512 tier, the lightest of the family120 T5 tokensOne-step generation via distribution matching distillation, released in diffusers format only. Good for live previews and interactive sketching.

02 —

Pick a card by workload — real NexGPU rates

A 0.6B backbone cannot fill a big card, so do not pay for VRAM you will never touch

  • Full fp16 pipeline at 1024px with no quantization at all

    Tesla V100 32GB$0.188/GPU-hr

    The official snippets already use torch.float16 and Volta handles fp16 fine; 32GB swallows T5-XXL plus the 0.6B backbone in one load, covering both the ~17GB observed peak and the 23GB the native .pth path asks for — at the cheapest rate on the platform.

  • Native 2K output, ControlNet guidance, long batch runs

    RTX 4090 24GB$0.540/GPU-hr

    Ada is friendly to fp16, bf16 and bitsandbytes alike; 2048x2048 activations are much heavier than the 1024 tier, so 24GB plus an 8-bit T5 is the safe combination, with far more throughput per hour than older silicon.

  • LoRA or full fine-tuning of the 0.6B DiT without pre-extracting T5 features

    RTX A6000 48GB$0.817/GPU-hr

    PixArt-Σ can train without prior feature extraction, but the price is keeping T5's ~9GB resident during training on top of optimizer states and activations — 48GB means you never have to rewrite your training loop to save memory.

  • Sub-second LCM / DMD batch generation pipelines

    A100 PCIE 80GB$0.824/GPU-hr

    That published '0.5 seconds per 1024x1024 image' number was measured on an A100, so running the same card means your throughput estimates reconcile against the paper instead of needing a fresh baseline.

03 —

Four steps to a running PixArt-Σ

One trap up front: the resolution repos ship only the transformer — T5 and the VAE live somewhere else

  1. 01

    Start an instance on a prebuilt PyTorch image

    Pick a card in the NexGPU console and boot one of the 2,000+ prebuilt images with PyTorch already in place, skipping CUDA and driver setup entirely. The official PixArt README is still pinned to torch 2.0.1 + cu11.7 + Python 3.9, and copying that conda block onto a modern driver rarely ends well. Confirm the card and its memory first.

    nvidia-smi --query-gpu=name,memory.total --format=csv
  2. 02

    Install dependencies, including the two invisible ones clean_caption needs

    The diffusers PixArt pipeline defaults to clean_caption=True, which requires beautifulsoup4 and ftfy. If they are missing it does not raise — it silently falls back to encoding the raw prompt, and your outputs quietly shift. sentencepiece is mandatory for the T5 tokenizer, and bitsandbytes is there for the 8-bit path below.

    pip install -U "diffusers>=0.31.0" transformers accelerate safetensors sentencepiece bitsandbytes beautifulsoup4 ftfy
  3. 03

    Two-stage load: transformer separately, T5 and VAE from the shared repo

    This is where PixArt-Σ deployments most often break. Every resolution repo other than 1024-MS contains only a transformer subfolder; you must combine it with PixArt-alpha/pixart_sigma_sdxlvae_T5_diffusers to get a complete pipeline. Also note the config declares Transformer2DModel while the real class is PixArtTransformer2DModel — the diffusers docs state outright that this mismatch can be ignored, so do not go editing configs.

    python -c "import torch;from diffusers import Transformer2DModel, PixArtSigmaPipeline;t=Transformer2DModel.from_pretrained('PixArt-alpha/PixArt-Sigma-XL-2-1024-MS',subfolder='transformer',torch_dtype=torch.float16,use_safetensors=True);p=PixArtSigmaPipeline.from_pretrained('PixArt-alpha/pixart_sigma_sdxlvae_T5_diffusers',transformer=t,torch_dtype=torch.float16,use_safetensors=True).to('cuda');p('A small cactus with a happy face in the Sahara desert.').images[0].save('out.png')"
  4. 04

    When VRAM is tight, cut the T5 — never the backbone

    Load T5 in 8-bit, call encode_prompt on its own to capture prompt_embeds and the attention masks, del the text encoder, run gc.collect() plus torch.cuda.empty_cache(), then load the pipeline with text_encoder=None to produce latents and decode through the VAE separately. That sequence, straight from the diffusers docs, keeps 1024px generation under 8GB, and load_in_4bit takes it under 7GB. The tradeoff is real: 8-bit text embeddings lose information, and the docs explicitly recommend comparing against full precision. Also avoid Pascal cards such as the Tesla P40 on this path — bnb 4-bit is known to misbehave there.

    text_encoder = T5EncoderModel.from_pretrained("PixArt-alpha/PixArt-Sigma-XL-2-1024-MS", subfolder="text_encoder", load_in_8bit=True, device_map="auto")

A cost estimate you can actually audit

Start from the one hard published number: PixArt-δ-LCM produces a 1024x1024 image in 0.5 seconds on an A100 at 4 steps. NexGPU's A100 PCIE 80GB is $0.824/GPU-hr, which is $0.824 / 3600 = about $0.000229 per second. Ten thousand images means 10,000 x 0.5 = 5,000 seconds = 1.39 hours, so compute is 1.39 x $0.824 = about $1.15. Add half an hour for pulling weights, installing dependencies and warm-up and the whole job is roughly 1.9 hours x $0.824 = about $1.57 — on the order of one hundredth of a cent per image. Switch to standard PixArt-Σ at 20 steps with CFG and each image costs 40 transformer forward passes, ten times the 4 forwards of the CFG-free LCM path, so wall time and spend scale roughly in that proportion. At that point an RTX 4090 24GB at $0.540/GPU-hr is usually the better buy, because a 0.6B backbone will never fill 80GB. On storage: T5-XXL in fp16 is about 9GB, plus the VAE and transformer, so a 20GB volume at the $0.414/GB-month median is 20 x 0.414 = $8.28/month. Compute billing stops the moment the instance stops; the volume keeps billing until you destroy it. Egress at the $0.0081/GB median for 10,000 images at roughly 1MB each is 10GB, or 10 x 0.0081 = about $0.08. No minimum, no setup fee, no quota request anywhere in that chain.

04 —

FAQ

How much VRAM does PixArt actually need? Will it run on an 8GB card?

The official PixArt-α repo gives three figures: 23GB by default on the native .pth inference path, 11GB via diffusers, and under 8GB with memory optimizations. The diffusers documentation goes further — load T5 in 8-bit through bitsandbytes and free components between stages, and 1024px generation stays under 8GB; 4-bit takes it under 7GB. So 8GB works, at the cost of degraded text embeddings and the extra latency of loading and unloading in stages. If you would rather not fight for megabytes, NexGPU's Tesla V100 32GB is $0.188/GPU-hr and runs the full unquantized fp16 pipeline outright.

What is the difference between PixArt-Σ and PixArt-α, and should I just start with Sigma?

Three concrete changes: the VAE moves from the SD1.5-era sd-vae-ft-ema to the SDXL VAE, the usable T5 token budget goes from 120 to 300 so long prompts stop getting truncated, and a new attention module compressing keys and values lets the 0.6B backbone emit 2K and 4K directly. Backbone parameter count is 0.6B in both generations, so the VRAM math is nearly identical. Unless you are reproducing the α paper or depend on α's LCM and ControlNet ecosystem, go straight to PixArt-Sigma-XL-2-1024-MS. If you want to benchmark both, NexGPU bills per second — spin up one instance each, run them, stop them, and the bill is measured in minutes.

Has PixArt been superseded by SANA? Is it still worth deploying?

The research line did move on: weights in the PixArt-alpha HuggingFace org were last updated in May 2024, and core PixArt authors including Junsong Chen and Enze Xie went on to build SANA at NVlabs, releasing SANA-1.5 and SANA-Sprint in March 2025 with a claim that SANA-0.6B is 39.5x faster than FLUX-dev. PixArt is still a very usable base though — Apache-2.0 code, open weights, a simple architecture, and native 2K output that essentially nothing else at 0.6B matches, which makes it ideal for DiT teaching, ablations and cheap bulk generation. To compare PixArt against SANA head to head, NexGPU carries 75 GPU models across 1,175 verified rentable nodes, so running both pipelines in one evening is trivial.

Can a 24GB RTX 4090 handle PixArt-Σ at 2K?

Yes, but understand the resolution binning first. The pipeline selects a bin from transformer.config.sample_size: 256 maps to ASPECT_RATIO_2048_BIN, 128 to 1024, 64 to 512 and 32 to 256. That means you must use the PixArt-Sigma-XL-2-2K-MS weights — asking a 512 checkpoint for 2048 just silently bins down to 512 and upscales. The 2048x2048 activation cost is much higher than the 1024 tier, so 24GB with an 8-bit T5 is the safe pairing. NexGPU's RTX 4090 24GB is $0.540/GPU-hr, and if it feels tight the RTX A6000 48GB is $0.817/GPU-hr — stopping one instance and starting another carries no switching fee.

Can I use PixArt commercially? What is the license?

Two separate answers. The code in the PixArt-alpha and PixArt-sigma GitHub repositories is Apache License 2.0, which places no restriction on commercial use. The weights on HuggingFace — PixArt-XL-2-1024-MS, PixArt-Sigma-XL-2-1024-MS and siblings — carry the CreativeML Open RAIL++-M license, an open license with a use-restriction appendix you should read before shipping anything. The model cards also list known limits: no legible text rendering, unreliable fingers and fine anatomy, weak compositionality, lossy autoencoding. Rent an hour on NexGPU and test those boundaries yourself before committing a production pipeline to them.

Loading PixArt-Σ from the official code fails with a missing text_encoder or vae. What now?

That is by design, not a bug. Every resolution repo other than PixArt-Sigma-XL-2-1024-MS contains only a transformer subfolder; T5 and the SDXL VAE live together in the roughly 4.5B PixArt-alpha/pixart_sigma_sdxlvae_T5_diffusers repository. The correct pattern is Transformer2DModel.from_pretrained(..., subfolder='transformer') first, then pass it as the transformer= argument to a PixArtSigmaPipeline built on the shared repo. Related: the config names Transformer2DModel while the actual class is PixArtTransformer2DModel, and the diffusers docs say to ignore that mismatch. NexGPU gives you SSH, Jupyter, a web terminal, a REST API and a CLI, with bilingual support over Telegram and no ticket queue, so getting stuck on details like this does not cost you a day.

Start building on NexGPU

Enterprise R&D team or solo developer — either way, your first job can be running in minutes.

Sign up to browse live network pricing. No payment method required.