Dynamic Flows on Curved Space Generated by Labeled Data

Xinru Hua, Truyen Nguyen, Tam Le, Jose H. Blanchet, Viet Anh Nguyen

Abstract

Deep learning models typically require vast amounts of labeled data to achieve high performance, a requirement that is often unmet in specialized domains. This paper introduces a novel data augmentation framework that addresses data scarcity by "flowing" labeled samples from a feature-rich source domain to a data-poor target domain. By lifting data into a feature-Gaussian space and utilizing Riemannian gradient flows on curved manifolds, the proposed method minimizes the Maximum Mean Discrepancy (MMD) to generate high-fidelity synthetic samples. Experimental results across various benchmarks, including Tiny ImageNet, demonstrate that this approach significantly improves performance in one-shot and five-shot transfer learning scenarios while maintaining high computational efficiency.

Introduction

In many real-world machine learning applications, practitioners face a significant distribution shift between a well-documented source domain and a sparse target domain. While traditional data augmentation techniques—such as rotation, scaling, or noise injection—provide some relief, they often fail to capture the underlying structural differences between domains. Furthermore, generative models like GANs or VAEs typically require substantial data to learn a stable distribution, making them impractical for extreme few-shot scenarios where only a single sample per class may be available.

This paper proposes a principled approach to data synthesis: transforming source data points mathematically so they align with the target distribution while strictly preserving their original labels. The core innovation lies in treating this transformation as a dynamic flow on a curved Riemannian manifold, allowing for more precise and efficient data migration than standard Euclidean methods.

Methodology

Label Lifting and the Gaussian Manifold

To handle categorical labels within a geometric framework, the authors employ "label lifting." Since categorical labels lack a natural distance metric, each label is mapped into a higher-dimensional space where it is represented by a Gaussian distribution, defined by a mean and a covariance matrix.

Unlike standard feature spaces, the space of Gaussian distributions is not flat; it is a curved Riemannian manifold governed by the Bures metric. By accounting for this curvature, the method can find more efficient paths for data transformation that respect the intrinsic geometry of the data distributions.

Riemannian Gradient Flow

The transformation process is formulated as a minimization of the Squared Maximum Mean Discrepancy (MMD), a metric that quantifies the distance between the source and target distributions. The authors derive an explicit Riemannian gradient for the MMD loss, allowing source samples to "flow" along the steepest descent path on the curved manifold toward the target distribution.

To implement this flow computationally, the authors use a discretized Forward Euler scheme. They also introduce a stochastic component—a noisy version of the algorithm—to help the flow escape local optima and ensure convergence toward a global minimum. Once the flow reaches the target distribution, the transformed points are projected back into the original feature-label space to serve as augmented training data.

Experimental Evaluation

Datasets and Scalability

The researchers evaluated the framework on several high-dimensional benchmarks:

  • MNIST Variants: MNIST (M), Fashion-MNIST (F), and Kuzushiji-MNIST (K).
  • Natural Images: SVHN (Street View House Numbers) and Tiny ImageNet (TIN).
  • Synthetic Data: Mixtures of Gaussians used to visualize the splitting and merging of distributions.

Notably, the inclusion of Tiny ImageNet (3 x 64 x 64) demonstrates the method's scalability to complex image data, surpassing the dimensionality limits of previous gradient flow research.

Performance and Efficiency

In one-shot transfer learning tasks, the "flowed" samples consistently improved classifier accuracy across all tested pairs. For instance, in Fashion-MNIST to MNIST transfers, the method outperformed state-of-the-art baselines, including Mixup and traditional image rotations.

Beyond accuracy, the method offers significant computational advantages. On a standard CPU, the proposed approach completed steps in approximately 0.5 seconds, compared to 74 seconds for the primary baseline (Alvarez-Melis and Fusi, 2021). This speed is achieved by providing an explicit formula for the gradient, which bypasses the need for expensive automatic differentiation through complex manifold operations.

Discussion and Key Insights

The Importance of Geometry

The primary insight of this work is that geometry matters. By acknowledging the curvature of the Gaussian manifold, the flow finds more accurate paths for data transformation than Euclidean-based methods. This geometric awareness ensures that the relationship between features and labels is preserved throughout the transformation, a common failure point in simpler domain adaptation techniques.

Bypassing Generative Training

Unlike GAN-based approaches, this method does not require training a generative model. It directly manipulates existing data points, making it uniquely suited for scenarios where target data is extremely scarce. Qualitative results confirm that the flow successfully transforms source images into recognizable target-style images while maintaining the semantic integrity of the original labels.

Conclusion and Future Work

This paper presents a robust framework for data augmentation via Riemannian gradient flows. By leveraging the geometric properties of Gaussian manifolds, the authors provide a fast, scalable, and effective solution for few-shot transfer learning.

Future research may explore more complex manifold structures beyond Gaussians to better represent non-convex class distributions. Additionally, extending theoretical convergence proofs to a wider variety of kernels could further solidify the mathematical foundation of this dynamic flow approach.

Summary updated

Abstract

The scarcity of labeled data is a long-standing challenge for many machine learning tasks. We propose our gradient flow method to leverage the existing dataset (i.e., source) to generate new samples that are close to the dataset of interest (i.e., target). We lift both datasets to the space of probability distributions on the feature-Gaussian manifold, and then develop a gradient flow method that minimizes the maximum mean discrepancy loss. To perform the gradient flow of distributions on the curved feature-Gaussian space, we unravel the Riemannian structure of the space and compute explicitly the Riemannian gradient of the loss function induced by the optimal transport metric. For practical applications, we also propose a discretized flow, and provide conditional results guaranteeing the global convergence of the flow to the optimum. We illustrate the results of our proposed gradient flow method on several real-world datasets and show our method can improve the accuracy of classification models in transfer learning settings.
BibTeX
@inproceedings{hua2023dynamic,
  author = {Xinru Hua and Truyen Nguyen and Tam Le and Jose H. Blanchet and Viet Anh Nguyen},
  title = {{Dynamic Flows on Curved Space Generated by Labeled Data}},
  booktitle = {International Joint Conference on Artificial Intelligence},
  year = {2023},
  doi = {10.24963/ijcai.2023/423},
}
Figure