TL;DR
This paper introduces SCFlow, a novel framework that implicitly disentangles style and content in images by learning to invertibly merge them using flow matching. Instead of explicitly separating attributes, SCFlow leverages the inherent invertibility of flow models to achieve disentanglement as an emergent property, bypassing the challenges of defining subjective boundaries.
What Problem Does This Paper Address?
Disentangling "style" and "content" in images is a long-standing challenge in computer vision. These attributes are often semantically intertwined and subjectively perceived, making it difficult to define clear, objective separation criteria. Existing methods often rely on explicit supervision or generative/discriminative objectives that struggle with this inherent ambiguity. This makes it hard to achieve truly independent control over style and content for tasks like image editing or generation. The paper asks: can we sidestep the difficulty of explicit disentanglement by learning to merge style and content in a way that is naturally invertible, allowing separation to emerge?
Methods
SCFlow employs a flow matching (FM) framework, which learns continuous, bidirectional mappings between probability distributions without relying on restrictive Gaussian priors common in diffusion models or normalizing flows. The core idea is to train a model to perform a blending process (merging style and content) from a disentangled distribution ($p_0$) to a mixed distribution ($p_1$). Crucially, the invertibility of the flow model means that this same learned mapping can be reversed to achieve disentanglement (separating style and content from the mixture).
The model is trained to approximate the velocity field of a stochastic differential equation that interpolates between the disentangled and mixed distributions. This is achieved by minimizing a loss function that encourages the model to predict the correct trajectory. A key innovation is the use of CLIP embeddings as the latent representation, providing a semantically rich space for manipulation and evaluation.
Datasets
The authors introduce a new, large-scale synthetic dataset specifically designed to facilitate learning disentanglement. This dataset consists of 510,000 samples, created by systematically pairing 51 artistic styles with 10,000 content samples in a fully combinatorial manner. This ensures that every style is applied to every content, enabling the model to learn invariant attributes by observing how style and content vary independently. This contrasts with existing datasets that often lack such systematic pairings.
Key Insights and Ideas
- Implicit Disentanglement through Invertible Merging: The most significant insight is that explicit disentanglement objectives are not strictly necessary. By learning to invertibly merge style and content, disentanglement can emerge naturally as a byproduct of the model's ability to reverse the process.
- Flow Matching for Arbitrary Distributions: FM proves to be a powerful tool for learning bidirectional mappings between complex, non-Gaussian distributions, overcoming limitations of other generative models.
- Structured Asymmetry for Learning Invariance: The curated dataset, with its asymmetric triplets (e.g., content with arbitrary style, style with arbitrary content), forces the model to learn representations that are invariant to irrelevant factors, thereby promoting disentanglement.
- CLIP Embeddings for Semantic Richness: Utilizing CLIP embeddings provides a semantically meaningful latent space that facilitates both manipulation and evaluation of disentangled representations.
Key Results
- Qualitative Results: SCFlow successfully merges style and content in forward inference, producing outputs that reflect the specified references. In reverse inference, it generates disentangled content and style representations that are free from stylistic influence and abstract high-level patterns, respectively. Visualizations show smooth and semantically meaningful interpolations in the learned latent space, outperforming CLIP.
- Quantitative Results:
- Content and Style Classification: SCFlow achieves the highest Normalized Mutual Information (NMI) scores for both content and style classification on a held-out dataset, significantly outperforming baselines like CLIP, DEADiff, and CSD.
- Fisher Discriminant Ratio (FDR): The model's embeddings exhibit the highest FDR for both content and style, indicating superior separability between classes. Style FDR is notably an order of magnitude higher than CLIP and DEADiff.
- Generalization: SCFlow demonstrates strong generalization to unseen content and styles, achieving competitive performance in WikiArt style retrieval and ImageNet content classification.
Limitations and Future Work
- Limitations: While SCFlow achieves strong results, the paper notes that its content classification performance on ImageNet is slightly lower than original CLIP, though it excels in style representation. The authors also mention that CSD, while strong in style NMI, struggles with content disentanglement.
- Future Work: The authors suggest that the flow matching framework has potential for extending to other modalities and broader applications. They highlight the underexplored use of flow matching for mapping between two real data distributions in both directions as a promising avenue for future research.
Summary updated