A Flexible Diffusion Model

weitao Du, He Zhang, Tao Yang, Yuanqi Du

While standard diffusion models rely on hand-crafted, fixed noising schedules, recent research introduces FP-Diffusion, a framework that allows the model to learn the optimal forward noising process. By leveraging Riemannian and symplectic geometry, this approach enables diffusion models to adapt their noising paths to the underlying structure of the data, leading to better generative performance and a tighter theoretical connection to variational inference.

The Problem with Fixed Forward Processes

In the world of generative AI, diffusion models have become the gold standard. They work by taking data and gradually turning it into noise (the forward process) and then learning to reverse that process to create new samples (the backward process).

However, in almost all popular models (like DDPM or Stable Diffusion), the forward process is "hand-crafted." Researchers choose a fixed schedule—usually adding isotropic Gaussian noise—and leave it at that. If we think of the forward-backward pair as an encoder-decoder system (similar to a VAE), freezing the "encoder" (the forward process) is theoretically incomplete.

The core question this research addresses is: Can we parameterize the forward noising process so the model can automatically optimize it for the specific data it is learning?

The FP-Diffusion Framework

To solve this, the authors propose FP-Diffusion, a general framework for parameterizing the spatial components of the forward Stochastic Differential Equation (SDE). They draw on two deep mathematical concepts to achieve this flexibility:

  1. Riemannian Geometry: Instead of adding noise equally in all directions (isotropic), the framework uses a learned Riemannian metric to allow anisotropic noise. This means the model can learn to "blur" the data more in directions that do not matter and preserve structure where it does.
  2. Symplectic Geometry: They introduce a "drift" term based on symplectic forms (Hamiltonian dynamics). This allows the noising process to have a deterministic "swirl" that helps the distribution mix more efficiently without changing the final target distribution (the Gaussian prior).

The "Hard Constraint": A major challenge in changing the forward process is ensuring that it still ends up at a simple, searchable distribution like a standard Gaussian. The authors provide a theoretical guarantee that their specific parameterization always converges to a standard Gaussian, regardless of the learned parameters.

Training Strategy: Because optimizing both the forward and backward processes simultaneously is difficult, they propose a two-stage "Mix Training" strategy:

  • Stage 1: Jointly optimize the forward process parameters and the score-matching network.
  • Stage 2: Freeze the forward process and fine-tune the score network to perfection.

Key Insights and Results

By parameterizing the forward process, the authors can optimize the Evidence Lower Bound (ELBO) more effectively. They show that the "gap" in standard score-matching losses is actually a function of the forward process, meaning a better forward process leads to a better objective function.

Qualitative Efficiency: On synthetic 3D data (a 2D Gaussian distribution embedded in 3D space), the learned trajectories were visibly "straighter" and more vertically aligned with the data manifold compared to the curved paths of standard Variance Preserving (VP) models. This illustrates how FP-Diffusion learns to "blur" away from the low-dimensional data manifold more effectively, creating efficient paths for the generative process to follow.

Comparison of standard VP random paths (green) and the learned flexible random paths (white) in 3D space.

Benchmark Performance: The framework was evaluated on standard image datasets, demonstrating strong quantitative results:

  • CIFAR-10: The FP-Noise (Mix) model achieved a FID of 2.87, outperforming standard DDPM (3.17) and Improved-DDPM (2.90).
  • MNIST: For density estimation, the model achieved a Negative Log-Likelihood (NLL) of 1.01, which is competitive with state-of-the-art flow-based models like RealNVP and Glow.
Generated samples from the FP-Diffusion model on MNIST (left) and CIFAR-10 (right).

Furthermore, the authors show that their framework is a "super-set" that unifies existing models. By setting specific parameters to zero or identity, one can recover standard VP SDEs or even the more complex critically-damped Langevin diffusion.

Limitations and Future Directions

While highly promising, the framework does come with challenges:

  • Optimization Complexity: Efficiently optimizing these flexible SDEs remains difficult. The two-stage "Mix Training" is a necessary workaround for the inherent instability of joint optimization.
  • Computational Overhead: Parameterizing the noise and drift adds complexity to the model architecture, which could impact training time and memory usage for very high-resolution images.

Future work may involve applying this framework to non-Euclidean data (like graphs or manifolds) and exploring even more complex phase-space diffusions. Additionally, using a pre-trained score function to initialize the Riemannian metric could potentially speed up convergence, paving the way for even more efficient and adaptable diffusion models.

Summary updated

BibTeX
@inproceedings{du2023flexible,
  author = {weitao Du and He Zhang and Tao Yang and Yuanqi Du},
  title = {{A Flexible Diffusion Model}},
  booktitle = {International Conference on Machine Learning},
  year = {2023},
  url = {https://openreview.net/forum?id=NwICIHHpKf},
}
Figure