Manuscript Offprint

arXiv:2610.32413

AlphaAnything: Extending Pretrained RGB Generators to RGBA

Qijie Wang, Zhixin Xu, Zhe Li, Haowei Zhu, Honghao Qiao, Bo Peng, Dawei Li, Bin Wang

Abstract

Existing RGBA generation methods commonly learn a transparency-specific representation through reconstruction, introducing an additional training stage and potentially altering the RGB decoding function inherited from pretrained models. We present ALPHAANYTHING, a lightweight framework that extends pretrained RGB generators to RGBA directly in their original latent space, without RGBA reconstruction pretraining. ALPHAANYTHING inserts LoRA modules into the generative transformer and attaches an alpha branch to the frozen RGB VAE decoder. Unidirectional RGB-to-alpha feature sharing allows opacity supervision to shape the generative latent while guaranteeing that, for any fixed latent, RGB decoding remains identical to that of the pretrained decoder. We further introduce Endpoint-Aware Alpha Loss (EA Loss), which derives opacity supervision from the complementary foreground–background weights used in compositing. It supports exact opacity endpoints and continuous partial transparency while emphasizing localized alpha errors. Experiments on text-to-RGBA and image-to-RGBA tasks across multiple pretrained RGB backbones demonstrate competitive generation quality, and controlled ablations validate the shared-latent training design and EA Loss.

1 INTRODUCTION

Pretrained image generators can synthesize high-quality visual content from text or image conditions (Rombach et al., 2022; Wu et al., 2025; 2026). Many downstream applications, however, require assets that can be directly layered and composited into new scenes, rather than RGB images tied to a fixed background (Fontanella et al., 2024; Yin et al., 2026). RGBA images support this use case by representing appearance and opacity separately: the RGB channels describe foreground color, while the alpha channel controls how the foreground is blended with its background (Xu et al., 2017; Zhang & Agrawala, 2024). A practical RGBA extension should therefore add transparency generation while reusing the conditioning and appearance priors of a pretrained RGB model.

Existing RGBA generation methods commonly introduce a transparency-specific representation through reconstruction training. LayerDiffuse learns a transparency encoder and decoder with reconstruction supervision (Zhang & Agrawala, 2024), while AlphaVAE and Qwen-Image-Layered train dedicated four-channel autoencoders (Wang et al., 2025b; Yin et al., 2026). Although effective, this strategy adds a separate representation-learning stage and couples subsequent generative training to the reconstructed RGBA latent space. Updating an RGB autoencoder for RGBA reconstruction can also change its pretrained RGB decoding function, with potential losses in color or high-frequency detail. Zippo (Xie et al., 2024) shows that a dedicated RGBA VAE is not strictly necessary by encoding replicated alpha with a pretrained RGB VAE, but it still models appearance and opacity with separate latent states. These observations motivate a simpler question: can a pretrained RGB generator learn opacity directly in its existing latent space, using generative supervision alone?

We answer this question with ALPHAANYTHING, a lightweight framework that augments a pretrained RGB generator with a shared-latent alpha pathway. We insert LoRA modules (Hu et al., 2022) into the generative transformer and attach a trainable alpha branch to the frozen RGB VAE decoder. During training, flow-matching supervision updates the transformer LoRA, while opacity supervision passes through the frozen decoder features to shape the same predicted

∗^{*}Equal contribution. Emails: qijiewang02@gmail.com, xuzhixin.66@bytedance.com.

†^{\dagger}Work done during an internship at ByteDance.

Text to RGBA

Figure

山海之间

山海之间

Avenorig

Avenorig

Avenorig

CELESTIAL

OBSERVATORY

Image to RGBA

CELESTIAL

OBSERVATORY

CELESTIAL

OBSERVATORY

COCKTAIL

MENU COCKTAIL

COCKTAIL

Spring

SALE

UP TO 35% OFF

Spring

Spring

Figure 1: Representative text- and image-to-RGBA results. Each prompt specifies an asset to generate or extract. For text-to-RGBA, independently generated layers are manually arranged into the displayed compositions.

latent. Within the decoder, information flows only from the RGB pathway to the alpha branch; the alpha state is never fed back into the RGB pathway. Consequently, for any fixed latent, the augmented decoder produces exactly the same RGB output as the original pretrained decoder, while predicting alpha from the RGB feature hierarchy. RGB and alpha are thus obtained from one latent and one augmented decoder traversal, without an RGBA autoencoder or a separate alpha latent.

Learning opacity also requires an objective that reflects its role in compositing. Alpha is not merely a bounded image channel: a = 0 and a = 1 denote exact transparency and opacity, intermediate values encode partial visibility, and (1−a,a)(1 - a, a) gives the complementary background–foreground mixing weights. We therefore introduce Endpoint-Aware Alpha Loss (EA Loss). EA Loss represents this compositing pair on the Bernoulli simplex and uses its Fisher–Rao coordinate (Miyamoto et al., 2024) to parameterize the full opacity range. An endpoint-compatible Fenchel–Young formulation represents exact endpoints with finite scores and retains corrective gradients when a prediction saturates at the wrong endpoint. The same complementary weights further separate background- and foreground-associated errors before root aggregation, increasing the relative contribution of localized defects such as thin structures, small holes, and background leakage. We characterize these properties theoretically and evaluate the complete objective against standard alpha L1L_{1} supervision.

The paper makes three contributions. (1) Shared-latent RGBA extension. We show that pretrained RGB generators can acquire text- and image-conditioned RGBA generation without RGBA reconstruction pretraining. A unidirectional RGB-to-alpha decoder branch lets opacity supervision shape the generative latent while preserving the pretrained RGB decoding function for every fixed latent. (2) Endpoint-aware opacity supervision. We derive EA Loss from the complementary compositing weights of alpha. The objective accommodates exact endpoints and continuous partial transparency while emphasizing spatially localized alpha errors, and we establish its key optimization and error-control properties. (3) Evaluation across tasks and backbones. We instantiate ALPHAANYTHING on multiple pretrained RGB generators and evaluate it in both text-to-RGBA and image-to-RGBA settings, where it achieves competitive generation quality without an RGBA autoencoder or a separate alpha latent.

References (100)

  • Learning with fenchel-young losses
  • Prismlayers: Open data for high-quality multi-layer transparent image generative models, 2025 (opens arXiv in a new tab)
  • Generating compositional scenes via text-to-image rgba instance generation (opens the publisher in a new tab)
  • CLIPScore: A reference-free evaluation metric for image captioning (opens the publisher in a new tab)
  • Gans trained by a two time-scale update rule converge to a local nash equilibrium
  • LoRA: Low-rank adaptation of large language models
  • Musiq: Multi-scale image quality transformer
  • Deep automatic natural image matting
  • Decoupled weight decay regularization
  • Longcat-image technical report, 2025 (opens arXiv in a new tab)
  • On closed-form expressions for the fisher–rao distance (opens the publisher in a new tab)
  • Scalable diffusion models with transformers
  • SDXL: Improving latent diffusion models for high-resolution image synthesis
  • Learning transferable visual models from natural language supervision
  • A perceptually motivated online benchmark for image matting (opens the publisher in a new tab)
  • High-resolution image synthesis with latent diffusion models
  • Laion-5b: An open large-scale dataset for training next generation image-text models (opens the publisher in a new tab)
  • The CIEDE2000 color-difference formula: Implementation notes, supplementary test data, and mathematical observations (opens the publisher in a new tab)
  • Sega: A stepwise evolution paradigm for content-aware layout generation with design prior
  • Alphavae: Unified end-to-end rgba image reconstruction and generation with alpha-aware representation learning, 2025b (opens arXiv in a new tab)
  • Qwen-Image Technical Report
  • Visual generation in the new era: An evolution from atomic mapping to agentic world modeling, 2026 (opens arXiv in a new tab)
  • Zippo: Zipping color and transparency distributions into a single diffusion model, 2024 (opens arXiv in a new tab)
  • Imagereward: Learning and evaluating human preferences for text-to-image generation (opens the publisher in a new tab)
  • Deep image matting
  • Qwen-image-layered: Towards inherent editability via layer decomposition
  • Omnialpha: Aligning transparency-aware generation via multi-task unified reinforcement learning, 2026 (opens arXiv in a new tab)
  • Transparent image layer diffusion using latent transparency (opens the publisher in a new tab)
  • The Unreasonable Effectiveness of Deep Features as a Perceptual Metric
  • We use $a = I_{\alpha}, u = \chi(a), r = p(s) - u$, and $N = HW$
  • Let $K = \partial\overline{z}_0 / \partial\widehat{z}_0$ be the diagonal clipping Jacobian and $J_s = \partial H_\phi(\overline{z}_0; D) / \partial\overline{z}_0$
  • The frozen decoder retains its derivatives with respect to its input, so the gradient in (15) propagates through the predicted velocity to the transformer LoRA parameters
  • Its second moment, using $\mathrm{Var}(Y) = a(1 - a)$, gives
  • The inverse $f(u)=\sin^2(\pi u/2)$ is a continuous bijection on $[0,1]$
  • At zero, expanding $\arcsin x = x + O(x^3)$ gives
  • The conjugate values and first derivatives agree at both joins, and $(\Omega^{*})'(s) = p(s)$
  • Every soft target has an exact fit at $s = 2u - 1$
  • The equivalent expression $\chi(a) = (2/\pi) \operatorname{atan2}(\sqrt{a}, \sqrt{1 - a})$ evaluates the target coordinate at both endpoints
  • For the actual roots in (9), let $M = N^{-1} \sum_i g(s_i, u_i)$
  • For $R_k > 0$, differentiation gives
  • Its local expression is a norm of affine or one-sided endpoint residuals, or is identically zero
  • This identity applies to both saturated and unsaturated scores and establishes the area dependence described in Section 3.3
  • The exact decomposition
  • All variants use the objective in (12), with the stated substitution for the alpha- $L_{1}$ ablation
  • The color-padding operation in Section 3.1 follows the multiscale convention of LayerDiffuse (Zhang & Agrawala, 2024)
  • The factor $\eta_{\ell}/r_{\ell}$ is the low-rank projection scaling; $1/\sqrt{m_{\ell}}$ normalizes the accumulated input by injection count; and the learned stage gate $\gamma_{\ell}$ controls its contribution
  • For AIM-500, we use the text prompts released with AlphaVAE
  • Each backbone keeps its native conditioning interface, latent layout, encoding, scaling, token packing, and sampler
  • Text-to-RGBA training uses 8,963 curated RGBA assets generated using an image generation model
  • For text-to-RGBA, explicit and implicit caption variants are selected with equal probability; within either form, the short caption is selected with probability 0.2
  • Neither set is used to train the ALPHAANYTHING models
  • The curation combines normalized exact-text matching, shared 12-word sequence checks, and manual review of TF-IDF nearest neighbors
  • Candidates must have a short side of at least 600 pixels, at least 0.7 megapixels, an aspect ratio between 0.45 and 2.20, and 2–24 annotated layout elements
  • 100 stylized design scenes and 100 photorealistic scenes
  • We use the same image generation and editing model to construct RGBA reference layers for both source pools
  • Descriptions capture the target's visible appearance and spatial relationships; instructions identify the same target and its intended semantic grouping
  • For AIM-500 (Li et al., 2021) and AlphaTest, we use the benchmark prompts provided by AlphaVAE
  • A photo depicts
  • The RGBA-Image comparison includes OmniAlpha, Qwen-Image-2.1, and the two ALPHAANYTHING backbones
  • Extract the object described by the text, preserving fine details and transparency:
  • $^{2}$ Alpha Grad measures squared differences between gradient magnitudes after independently min–max normalizing each alpha map
  • It uses the official AlexNet network with version 0.1 and bilinear antialiased resizing to a maximum image side of 512 pixels, without upscaling
  • The evaluation uses all 295 distinct source images in RGBA-Image, counting each input once regardless of how many target layers it has
  • LPIPS uses AlexNet v0.1 on floating-point reconstructions before PNG quantization, at the full evaluation resolution
  • The reported dataset score is
  • Unlike LPIPS in this experiment, $\Delta E_{00}$ is computed from the saved 8-bit RGB images
  • The original RGB image retains its generated background; RGBA outputs are displayed on white
  • Training uses this output directly, without the Fisher-coordinate mapping, Fenchel–Young gap, endpoint-group weighting, root aggregation, sigmoid, or output clipping
  • Counts include only the DiT LoRA modules and alpha branch
  • Inference adds only the alpha branch and its RGB-to-alpha feature injections to the backbone's denoising trajectory and decoder traversal, as specified in Appendix B.1
  • All four ALPHAANYTHING backbones obtain higher Aesthetic Score and ImageReward than the compared baselines
  • Both RGBA VAEs have higher LPIPS and CIEDE2000 errors than their corresponding original RGB VAEs
  • ><tr><td>RGB backbone</td><td>VAE</td><td>LPIPS ↓</td><td>$\Delta E_{00} \downarrow$</td></tr><tr><td rowspan=
  • Each target description is kept verbatim, while the surrounding instruction follows one of the four templates in Table 12: the standard OmniAlpha extraction template, a minimal request, a background-removal instruction, or explicit RGBA output requirements
  • Alpha Grad and Alpha Conn for the standard template are taken from the corresponding main-comparison runs
  • Each reported metric is averaged over 735 target layers
  • Table 13 reports the mean and sample standard deviation across the three runs on RGBA-Text, AlphaTest, and RGBA-Image
  • >RGBA-Text</td></tr><tr><td colspan=
  • >Method / backbone</td><td>FID $\downarrow$</td><td>CLIPScore $\uparrow$</td><td>Aesthetic $\uparrow$</td><td>ImageReward $\uparrow$</td></tr><tr><td colspan=
  • >Method / backbone</td><td>RGB L1 $\downarrow$</td><td>Soft IoU $\uparrow$</td><td>SAD $\downarrow$</td></tr><tr><td colspan=
  • Scores are first averaged over the three inference runs and, where applicable, the black/white backgrounds
  • >AlphaTest</td></tr><tr><td colspan=
  • >ALPHAANYTHING</td><td>FLUX.2[0.1070, 0.1260]</td><td>0.8270[0.8050, 0.8457]</td><td>52.6253[41.4052, 79.6911]</td></tr><tr><td>Qwen Image Edit[0.0698, 0.0796]</td><td>0.9236[0.9109, 0.9325]</td><td>29.3979[19.0433, 60.7663]</td></tr><tr><td colspan=
  • We report two complementary metrics: the win rate excluding ties
  • >ALPHAANYTHING backbone</td><td rowspan=
  • We profile four backbones using a single NVIDIA GPU per run, with the same GPU model across all measurements
  • >Backbone</td><td colspan=
  • The generation, extraction, and ablation comparisons follow the evaluation settings in Appendix B
  • Each case displays the shared content prompt above two rows: four baselines followed by all four ALPHAANYTHING settings
  • PAUSE AND PLAY
  • A folded fabric sample pouch hangs from the belt, and dark curls escape beneath a wool cap
  • Individual porous crumbs cast tiny local shadows, while isolated grains taper toward the ends
  • Each target description appears above the complete input, target RGBA layer, and prediction canvases; the shared extraction prefix is stated in the figure caption
  • THE KITCHEN
  • 25th Avenue
  • FRESH & ORGANIC
  • White “Club” lettering sits above a much larger bold “X9” at the center
  • 28TH June 2021
  • He wears cream-colored over-ear headphones, holding them with both hands, with one bent knee visible at the lower right
  • Purple and cool blue tones wash over the portrait

Couldn't load all references. Reload the page to try again.