Make Optimization Once and for All with Fine-grained Guidance

Mingjia Shi, Ruihan Lin, Xuxi Chen, Yuhao Zhou, Zezhen Ding, Pingzhi Li, Tong Wang, Kai Wang, Zhangyang Wang, Jiheng Zhang, Tianlong Chen

TL;DR

Diff-L2O reimagines "Learning to Optimize" (L2O) by using diffusion models to map out the entire solution space rather than just learning local update rules. By treating optimization as a guided generative task, it achieves near-convergence in fewer than ten steps and slashes the training time for learned optimizers from hours to just a few minutes.

What Problem Does This Paper Address?

Traditional optimization algorithms like SGD or Adam are hand-crafted. The "Learning to Optimize" (L2O) field seeks to replace these with neural networks that "learn" how to navigate loss landscapes more efficiently. However, existing L2O methods face three major hurdles:

  1. Intricate Design: They often require complex architectures (like LSTMs) tailored to specific optimization processes.
  2. Poor Generalization: They tend to overfit to the specific trajectories seen during training, struggling when faced with unseen problems.
  3. High Training Costs: Training a learned optimizer typically takes hours of computation.

The authors argue that current methods are too focused on local, step-by-step updates. They propose a shift toward a "wider view" that models the distribution of potential solutions across the entire landscape.

Methods

The core innovation is Diff-L2O, a framework that applies conditional diffusion models to the optimization solution space.

  • Unified Trajectory Modeling: The authors use the Inertial System of Hessian-driven Damping (ISHD) to provide a general mathematical framework that encompasses most first-order optimization algorithms.
  • Diffusion as Optimization: Instead of predicting a gradient step ($\Delta x$), Diff-L2O uses a diffusion process to generate a solution $x$. It starts with random noise and iteratively refines it into a high-quality solution.
  • Fine-grained Guidance: The denoising process is conditioned on "guidance" information, including gradients, problem-specific parameters ($\theta$), and time-step embeddings.
  • The Oracle Network: To avoid training from scratch for every new problem, they introduce an "oracle" network that generates smart initial points, further accelerating the process.
  • Hybrid Approach: Recognizing that diffusion is great at global exploration but can be less precise near the optimum, they propose a hybrid strategy: use Diff-L2O for the first 50 iterations to "jump" near the solution, then switch to a traditional optimizer like Adam for fine-tuning.
Figure 1: Diff-L2O’s intuitions: wider views and better sam- pling diversity with artificial sampling on solution spaces.

Datasets

The researchers evaluated Diff-L2O on a mix of synthetic benchmarks and real-world tasks:

  • LASSO: A classic convex optimization problem (tested in 10-dim and 50-dim settings).
  • Rastrigin & Ackley Functions: Highly non-convex benchmarks famous for having many deceptive local minima (tested in 2-dim and 10-dim).
  • MNIST: Training a multi-layer perceptron (MLP) on the MNIST handwritten digit dataset to test performance on deep neural networks.

Key Insights and Ideas

  • Diversity Improves Generalization: The authors provide a PAC-Bayesian generalization bound proving that the diversity of samples generated by the diffusion process is a key driver of performance. By exploring a "wider view" of the solution space, the model learns the underlying structure of the problem rather than just memorizing paths.
  • Optimization as Generation: By framing optimization as a generative task, the model can bypass the "crawling" nature of gradient descent. It learns where solutions tend to be given certain problem features.
  • Extreme Training Efficiency: Because the model learns a distribution rather than a sequential policy, training is incredibly fast. Diff-L2O requires only about 2% of the training time compared to previous state-of-the-art L2O methods (e.g., 203 seconds for LASSO vs. 4 hours for L2O-DM).

Key Results

  • Rapid Convergence: On benchmarks like LASSO and Ackley, Diff-L2O reaches a near-optimal range in less than 10 steps, whereas baselines often require 100+ steps to reach similar loss levels.
  • Superior Performance: In high-dimensional non-convex tasks (Rastrigin 10-dim), Diff-L2O achieved a loss of 44.09 in 10 steps, while the best baseline (RNNProp) could only reach 56.68 after 100 steps.
  • The Power of "Combined": The hybrid approach (Diff-L2O + Adam) consistently outperformed all other methods, including pure Adam, by providing a massive head start in the early stages of optimization.
Figure 3: Ablation: compatibility of Diff-L2O with conven- tional optimizers.

Limitations and Future Work

  • Inference Latency: While training is fast, the diffusion sampling process itself requires multiple steps (100 in this paper), which might be slower than a single SGD step in some real-time applications.
  • Precision at the Limit: Vanilla Diff-L2O can sometimes plateau near the optimum, necessitating the hybrid approach for high-precision tasks.
  • Scalability to Large Models: While the paper shows results on a small MLP for MNIST, testing the framework on massive architectures like Transformers or Large Language Models remains a future challenge.

Summary updated

BibTeX
@misc{shi2025make,
  author = {Mingjia Shi and Ruihan Lin and Xuxi Chen and Yuhao Zhou and Zezhen Ding and Pingzhi Li and Tong Wang and Kai Wang and Zhangyang Wang and Jiheng Zhang and Tianlong Chen},
  title = {{Make Optimization Once and for All with Fine-grained Guidance}},
  year = {2025},
  eprint = {2503.11462},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2503.11462},
}
Figure