Mage-Flow: An Efficient Native-Resolution Foundation Model for Image Generation and Editing
Reading guide · Based on sections of the original paper
Why read this
Practitioners serving or fine-tuning high-resolution diffusion models should read it for a drop-in fast tokenizer and measured training-throughput engineering, not for a new modeling paradigm.
What the authors found
- Against FLUX.2-VAE, the authors report about 12.3× lower encoding and 22.3× lower decoding compute (kMACs/px). Reconstruction stays close: on CLIC 2020 at about 2K, PSNR is 36.61 vs 36.88, and on FFHQ at 1024², it is 40.67 vs 40.47. In appendix measurements on an A100, latency at 4096² is 149.6/375.0 ms vs 47.3/183.9 s. Evaluation
- On one 8×B200 node with 50,000-token packed samples, per-step training time improves 2.48× over the FLUX.2-VAE baseline. Swapping the VAE alone gives 1.41×; fusing the DiT blocks gives the largest further gain. MFU rises from 13.88% to 29.28%, and peak memory falls from 175.45 to 141.44 GB. Training Infrastructure
- On GEdit-Bench, scored by a GPT-4.1 judge, the 4-step Turbo editor scores 8.271 (EN) and 8.264 (CN). This exceeds its 30-step parent and Qwen-Image-Edit-2511, FireRed, and LongCat. However, JoyAI-Image-Edit (16B) scores slightly higher on English, at 8.276. Instruction-based image editing
Main limitation
The editing gains are driven by semantic consistency. Perceptual quality on GEdit lags larger editors: for example, Turbo scores 7.970 vs FireRed's 8.245 on English. The authors also concede that text-editing layout preservation and complex text replacement still need improvement. Instruction-based image editing
Where to start
Evaluation · Table 2 swaps Mage-VAE and FLUX.2-VAE under fixed backbones, including FLUX.2-Klein-4B. It shows whether the tokenizer can substitute for FLUX.2-VAE without retraining.
Abstract
Large-scale visual generators are increasingly capable but costly to train, fine-tune, and deploy. We introduce Mage-Flow, a compact 4B-scale generative stack for efficient text-to-image generation and instruction-based image editing. The stack is built from two co-designed components: Mage-VAE, a lightweight high-fidelity latent tokenizer, and a Native-Resolution Multimodal Diffusion Transformer trained with rectified flow matching. Mage-VAE uses one-step diffusion-style encoding and decoding with anchor-latent regularization, preserving the reconstruction quality of strong public VAEs while reducing tokenization cost by more than an order of magnitude. Together with native-resolution packing and stack-level CUDA kernel fusion, the stack supports flexible-resolution training and improves end-to-end training throughput by about $2.5\times$. Built on this foundation, we develop a complete model family with Base, RL-aligned, and Turbo variants for both generation and editing. Diffusion-NFT improves prompt following, text rendering, aesthetic quality, and editing fidelity, while few-step distillation with adversarial perceptual guidance produces 4-step Turbo models for low-latency inference. Despite its compact scale, Mage-Flow and Mage-Flow-Edit achieves competitive performance across standard generation and editing benchmarks. More importantly, the Turbo variants make high-resolution generation and editing practical for interactive use: at $1024^2$ resolution on a single NVIDIA A100 GPU, Mage-Flow-Turbo generates an image in 0.59s, and Mage-Flow-Edit-Turbo edits an image in 1.02s, while maintaining a small memory footprint. These results show that careful tokenizer--backbone--system co-design can deliver strong high-resolution generation and editing within an efficient 4B model family.