A New First-Order Meta-Learning Algorithm with Convergence Guarantees

El Mahdi Chayti, Martin JaggiarXiv 2024 · DOI

Abstract

Meta-learning, or "learning to learn," enables AI systems to adapt to new tasks with minimal data. However, researchers typically face a trade-off between the mathematically rigorous but memory-intensive Model-Agnostic Meta-Learning (MAML) and faster "first-order" shortcuts that lack convergence guarantees. This paper introduces FO-B-MAML (First-Order Bi-Level MAML), an algorithm that bridges this gap. FO-B-MAML offers the computational efficiency of first-order methods while maintaining the mathematical rigor of full bi-level optimization. By employing a perturbation trick and finite differences, the authors achieve high-precision meta-gradients with significantly reduced memory overhead and provable convergence.

Introduction

Standard meta-learning frameworks like MAML involve a bi-level optimization process: an inner loop for task-specific adaptation and an outer loop for updating the model's global initialization. Calculating the optimal update for the initialization requires second-order derivatives (Hessians), which present two major challenges. First, storing and computing Hessians is prohibitively expensive for large-scale neural networks. Second, common "shortcuts" like First-Order MAML (FO-MAML) or Reptile, which ignore these second-order terms, introduce an irreducible bias that prevents convergence to the true optimal solution.

Methodology: FO-B-MAML

The authors propose FO-B-MAML to address these limitations. Rather than differentiating through the entire optimization path, FO-B-MAML treats the inner loop as a standalone optimization problem. The core innovation, formalized in Proposition 1, demonstrates that the true meta-gradient can be expressed as the derivative of a perturbed version of the inner optimization problem.

To approximate this gradient without second-order computations, the algorithm uses a finite difference method:

  1. Solve the standard inner optimization problem to find parameters.
  2. Solve a slightly perturbed version of the same problem (using a scalar parameter $\nu$).
  3. Estimate the meta-gradient based on the difference between these two solutions.

This approach is strictly first-order as it only requires the outputs of the optimization. Crucially, the bias in this estimate is controllable and can be made arbitrarily small by increasing the precision of the inner loop solver.

Table 1: Comparison of FO-B-MAML with existing meta-learning algorithms in terms of compute, memory, and bias.

As shown in Table 1, FO-B-MAML achieves the memory efficiency of first-order methods while maintaining a controllable bias ($\sqrt{\delta}$), unlike FO-MAML/Reptile which suffers from a constant bias.

Theoretical Insights: Generalized Smoothness

A significant theoretical contribution of this work is the debunking of the "smoothness myth" in meta-learning. Most optimization proofs assume a constant smoothness (where the gradient change is bounded). The authors prove that the MAML objective violates this assumption; instead, its smoothness constant grows with the norm of the gradient.

This discovery provides a formal theoretical justification for the empirical success of gradient clipping and normalized gradient descent (e.g., Adam) in meta-learning. These techniques are mathematically better suited for the "generalized smoothness" landscape of MAML objectives.

Results and Discussion

The algorithm was validated using a synthetic linear regression problem, allowing for exact comparison against the ground-truth meta-gradient.

  • Accuracy: FO-B-MAML's meta-gradient estimates were significantly more accurate than those of FO-MAML and Reptile, especially as the number of inner steps increased.
  • Performance: FO-B-MAML performed comparably to iMAML, a popular second-order method, but without the need for Hessian-vector products. It proved particularly robust in low-compute scenarios where iMAML's conjugate gradient steps are limited.

Conclusion and Future Work

While FO-B-MAML avoids the memory burden of second-order methods, it requires solving the inner optimization problem twice per task (the "Double Work" factor). Future research may explore using automatic differentiation specifically for the perturbation parameter $\nu$ to further improve efficiency. Additionally, extending these theoretical guarantees to large-scale benchmarks like Mini-ImageNet remains a priority for future practical validation.

Summary updated

BibTeX
@misc{chayti2024new,
  author = {El Mahdi Chayti and Martin Jaggi},
  title = {{A New First-Order Meta-Learning Algorithm with Convergence Guarantees}},
  year = {2024},
  eprint = {2409.03682},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2409.03682},
}
Figure