Introduction
Matching probability distributions is a fundamental task in machine learning, underpinning applications from domain translation to generative modeling. Traditionally, Generative Adversarial Networks (GANs) have been favored for their architectural flexibility, allowing for cross-dimensional mappings and specific structural constraints. However, GANs are notoriously difficult to train due to the instability of their adversarial min-max optimization, often resulting in mode collapse.
In contrast, Continuous Normalizing Flows (CNFs) and diffusion models offer stable training through simple quadratic (L2) loss functions. Yet, these models are often rigid, typically requiring the source and target distributions to share the same dimensionality. This paper introduces Flow-based Distribution Matching (FDM), a framework that combines the stability of flow-based training with the architectural freedom of GANs.
Methodology: Flow-based Distribution Matching (FDM)
The FDM framework decouples the generation process from the flow trajectory by employing two distinct neural networks:
- Generator ($g$): A flexible network that maps the source distribution to the target. It is not restricted by the dimensionality of the source.
- Consistency Model ($f_t$): An auxiliary network that learns the continuous trajectory between distributions.
Instead of an adversarial game, FDM uses a joint optimization objective $\mathcal{L}_{FDM}$ consisting of two alternating L2 minimization steps:
- Consistency Loss: Ensures the auxiliary model $f_t$ maintains mathematical consistency along the flow trajectory over time.
- Generator Loss: Optimizes the generator $g$ such that its output aligns with the consistency model's prediction at the final time step.
By using the consistency model as a stable "teacher," FDM avoids the pitfalls of min-max optimization while theoretically guaranteeing that the generator will converge to the target distribution.
Experimental Results
The authors validated FDM on both synthetic 2D datasets and the MNIST handwritten digit dataset.
Synthetic 2D Mappings
The method was tested on complex 2D transformations, such as mapping multiple Gaussian clusters to the "2 Moons" distribution. As shown in the figures below, FDM successfully captures the non-linear structure of the target distributions, demonstrating its ability to handle multi-modal source distributions without mode collapse.
Latent-to-Image Generation on MNIST
To demonstrate the framework's ability to handle dimensionality changes, the authors trained a UNet-based generator to map a 256-dimensional noise vector to $28 \times 28$ pixel MNIST images. The consistency model effectively guided the generator to produce diverse and recognizable digits, proving that FDM can mimic GAN-like behavior in high-dimensional spaces while maintaining stable training.
Conclusion and Future Work
Flow-based Distribution Matching offers a promising alternative to adversarial training by leveraging the stability of consistency models. While currently demonstrated on toy and low-resolution datasets, the theoretical grounding and observed stability suggest significant potential for scaling to high-resolution image synthesis. Future research will focus on optimizing the alternating training dynamics for larger-scale applications and providing comprehensive quantitative benchmarks against state-of-the-art generative models.
Summary updated