FluxSpace: Disentangled Semantic Editing in Rectified Flow Models

Yusuf Dalva, Kavana Venkatesh, Pinar YanardagCVPR 2025 · DOI

Introduction

Generative models have achieved remarkable success in producing high-quality images. However, precise semantic editing remains a significant challenge. In traditional GAN-based models, latent spaces often exhibit linear structures that allow for attribute manipulation. In contrast, modern diffusion and rectified flow models, such as Flux, operate through complex sequential processes where attributes are often "entangled." Attempting to modify a single feature (e.g., adding eyeglasses) frequently leads to unintended changes in the subject's identity or the background.

FluxSpace introduces a training-free, inference-time framework designed to navigate the internal representation space of rectified flow transformers. By leveraging orthogonal projections, FluxSpace enables "disentangled" edits—allowing for precise modifications without compromising the integrity of the original scene.

Methodology

The FluxSpace framework operates on the semantic representation space derived from the joint transformer blocks of the Flux model. The approach is categorized into three primary components:

  1. Fine-Grained Semantic Editing: For specific attribute additions (e.g., beards or smiles), FluxSpace employs a linear editing scheme. It calculates the vector difference between an "edit" prompt and a "null" prompt. To prevent entanglement, the method uses orthogonal projection to isolate the edit's semantic direction from existing image features.
  2. Coarse-Level Style Editing: Global transformations, such as changing a subject's gender or applying a "Comics Style," are achieved by manipulating the pooled CLIP embeddings that modulate the transformer layers.
  3. Self-Supervised Masking: To ensure spatial precision, the system generates masks based on internal attention maps (Query-Key interactions). This ensures that localized edits, like adding a smile, are confined to the relevant regions (e.g., the mouth).
Diverse editing results across various domains using FluxSpace.

Experimental Evaluation

The authors evaluated FluxSpace across diverse domains, including human portraits, animals, vehicles, and complex urban environments.

Quantitative Performance

FluxSpace was benchmarked against state-of-the-art methods like TurboEdit and LEDITS++. Using metrics such as CLIP-I (identity preservation) and DINO (structural consistency), FluxSpace demonstrated superior performance. For instance, in the "Eyeglasses" task, it achieved a CLIP-I score of 0.9417 and a DINO score of 0.9402, outperforming all baselines in content preservation.

User Study

A preference study involving 50 participants yielded a score of 4.19/5.0 for FluxSpace, significantly higher than the next best competitor (3.34). This highlights the method's ability to produce edits that are both semantically accurate and visually consistent with the original image.

Discussion and Key Insights

A critical finding of this research is that transformer-based models offer a cleaner space for semantic manipulation compared to traditional UNet architectures. The incremental nature of content addition in transformer layers allows for more effective vector-based editing. Furthermore, the use of orthogonality is a key innovation; by projecting edit directions to be orthogonal to the image's "prior," the method successfully "peels away" desired changes from the original content.

Conclusion and Limitations

FluxSpace provides a robust, zero-training solution for high-precision image editing in rectified flow models. While highly effective, the method's performance is currently bounded by the quality of the inversion process for real images. Future work will focus on improving inversion techniques and reducing hyperparameter sensitivity to further automate the editing pipeline.

Summary updated

BibTeX
@inproceedings{dalva2025fluxspace,
  author = {Yusuf Dalva and Kavana Venkatesh and Pinar Yanardag},
  title = {{FluxSpace: Disentangled Semantic Editing in Rectified Flow Models}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2025},
  doi = {10.1109/cvpr52734.2025.01221},
}
Figure