Abstract
Modern latent generative models, such as Stable Diffusion, rely on a compressed latent space to perform high-fidelity image synthesis. Traditionally, Variational Autoencoders (VAEs) have served as the standard for this compression. However, VAEs often struggle with "posterior collapse" and optimization instability due to the competing objectives of data reconstruction and Gaussian prior alignment. This paper introduces the Geometry-Preserving Encoder/Decoder (GPE), a framework that prioritizes the preservation of the data's intrinsic geometric structure. By utilizing a logarithmic Gromov-Monge loss and a sequential training strategy, GPE achieves significantly faster convergence—up to 900x on specific tasks—and superior reconstruction quality compared to traditional VAE baselines.
Introduction
Latent generative models operate by mapping high-dimensional data into a lower-dimensional latent space, where generative processes like diffusion or flow matching are applied. The efficacy of these models depends heavily on the quality of the latent representation. The industry-standard VAE attempts to force the latent distribution to match a simple Gaussian prior via KL-divergence. This constraint often "squishes" the natural manifold of the data, leading to a loss of critical features and making the decoder's task of reconstruction significantly more difficult.
GPE addresses these limitations by shifting the focus from distribution matching to geometry preservation. Instead of forcing a specific shape on the latent space, GPE ensures that the spatial relationships between data points are maintained, creating a more stable and efficient environment for generative modeling.
Methodology
The GPE framework is built upon three core technical innovations:
1. Geometry Preservation via Gromov-Monge Embedding
Rather than regularizing the latent space toward a Gaussian distribution, GPE employs a cost function based on the Gromov-Monge distance. This approach encourages the encoder to function as an "approximate global isometry." In practice, this means that if two images are distant in the original pixel space, their corresponding representations remain distant in the latent space. This preserves the topological structure of the data manifold.
2. Sequential Training Strategy
Standard VAEs train the encoder and decoder jointly, which can lead to an unstable optimization landscape as both components are "moving targets." GPE introduces a sequential training pipeline:
- The encoder is trained first to preserve geometry.
- Once the encoder is frozen, the decoder is trained for reconstruction. This decoupling simplifies the optimization process and allows the decoder to converge much faster against a stable latent representation.
3. Logarithmic Cost Function
To address the "exploding gradients" often encountered in manifold learning, the authors utilize a logarithmic formulation: log(1 + distance). Mathematically, this ensures that the Hessian (the matrix of second derivatives) remains bounded. This better-conditioned optimization problem allows for the use of more aggressive learning rates, drastically accelerating the training process without risking model collapse.
Experimental Results
The researchers evaluated GPE against standard VAEs using benchmarks including MNIST, CIFAR-10, CelebA, and CelebA-HQ (256 × 256).
Training Efficiency
The most striking result of GPE is its convergence speed. On the MNIST dataset, GPE reached target reconstruction loss levels 900 times faster than a VAE. On the more complex CelebA dataset, the speedup was approximately 3 times. When integrated with Conditional Flow Matching (CFM) on CIFAR-10, GPE reached its peak performance 15.6 hours earlier than VAE-based counterparts within a 24-hour training window.
Reconstruction and Generation Quality
GPE consistently outperformed VAEs in visual fidelity. While VAEs often produce blurry outputs due to the "averaging" effect of posterior collapse, GPE reconstructions remained sharp and faithful to the source material. Furthermore, GPE achieved lower Fréchet Inception Distance (FID) scores, indicating that the generated images were both higher in quality and more diverse than those produced by traditional latent models.
Discussion and Future Work
The success of GPE suggests that for latent generative models, preserving the data's geometric structure is more critical than adhering to a specific prior distribution. By stabilizing the latent space, GPE allows generative models to learn the underlying distribution more efficiently.
However, several avenues for future research remain. The current implementation focuses on image manifolds; extending these geometric principles to discrete data or transformer-based architectures in Large Language Models (LLMs) is a significant next step. Additionally, while Euclidean distance served as an effective metric in this study, exploring more sophisticated geometric kernels could further enhance the model's ability to capture complex data relationships in multi-modal settings.
Summary updated