Efficient Long-Horizon Learning for Learned Optimization

Xiaolong Huang1,3, Benjamin Thérien1,4, James Harrison2, Eugene Belilovsky1,3

1Mila – Quebec AI Institute   2Google DeepMind   3Concordia University   4Université de Montréal

Paper Code (JAX) Code (PyTorch)

TL;DR: We introduce ELO, an efficient long-horizon meta-training algorithm for learned optimization.

Abstract

Learned optimization aims to improve upon hand-designed optimizers (e.g., Adam and Muon) by meta-learning small neural network optimizers over a distribution of tasks. While recent work has greatly advanced the architectural design and inductive biases of learned optimizers (LOs), their meta-training remains biased toward short-unroll learning on particular tasks, resulting in redundant computation and leaving LOs often unable to compete with hand-designed optimizers. We introduce Efficient Long-hOrizon (ELO) learning, an efficient meta-training algorithm that (1) reallocates wasted meta-training compute to longer failure regimes, achieving efficient long-horizon learning, and (2) enforces decoupled progressive expert supervision, providing stable meta-learning signals that additionally improve the generalization of LOs.

Our empirical study evaluates ELO for meta-training both element-wise and matrix-based LOs. Across downstream language modeling (GPT-2-124M/350M on FineWeb) and image classification (ViT-B/16, ResNet-50 on ImageNet-1K) tasks, ELO substantially improves the long-unroll performance and out-of-distribution generalization of the base LOs. In particular, ELO-Celo2 consistently outperforms well-tuned AdamW across all evaluated tasks, while remaining competitive with Muon on language modeling. Notably, all ELO baselines require less than 7 H100 GPU-hours for meta-training.

Key Features

Failure-aware resume buffer

Reallocates redundant meta-training compute toward longer failure regimes, scaling learned-optimizer meta-training to long inner problems.

Progressive teacher forcing

Enforces decoupled progressive expert supervision, providing stable meta-learning signals that additionally lead to generalizable LOs.

Outperforms hand-designed optimizers

ELO-Celo2 outperforms well-tuned AdamW across all benchmarks and remains competitive with Muon on language modeling.

Cheap to meta-train

Every ELO-LO is trained in under 7 GPU-hours.

ELO algorithm

Experiments

Meta-Training Efficiency

Given a fixed compute budget, ELO improves meta-training convergence, especially at unroll lengths beyond the meta-training inner horizon.

ELO meta-training efficiency
Meta evaluation loss on ImageNet-1K at resolution 32x32, using a three-layer MLP with width 128. Each optimizer is evaluated for 10K inner steps with batch size 4096.

Can ELO-LOs generalize to out-of-Distribution tasks?

Meta-trained only on 4 tiny vision-MLP tasks, we observe that ELO-LOs transfer far outside their meta-training distribution, with ELO-Celo2 outperforming other learned baselines and AdamW across FineWeb pretraining and vision classification tasks, and remaining competitive with Muon on GPT-2 (124M/350M) language modeling.

GPT-2 language modeling validation loss over training tokens
GPT-2 (350M) language-modeling validation loss on FineWeb.
Element-wise and matrix-based optimizer comparison and best validation loss
GPT-2 (124M) language-modeling validation loss on FineWeb.

Evaluation on ImageNet Benchmarks

Method ResNet-50 ViT-B/16 Avg.
IN-1KIN-RealIN-V2 IN-1KIN-RealIN-V2
AdamW75.8882.1963.4074.1680.8761.3972.98
small_fc65.3673.7053.4331.7736.7025.5747.75
CL-small_fc72.2579.5359.9367.4674.7454.9468.14
Celo274.0480.9161.9374.9781.1062.0272.50
ELO-small_fc (Ours)73.9281.0062.1175.1881.7061.9872.65
ELO-Celo2 (Ours)76.2982.9364.2976.3382.2163.1074.19

Best top1-validation accuracy on ImageNet-1K validation, ImageNet-ReaL, and ImageNet-V2 for ResNet-50 and ViT-B/16 trained from scratch. Each method is trained on ImageNet-1K at 224x224 resolution for 50K steps with batch size 2048. The best value in each column is in bold.

How to use ELO-trained LOs in PyTorch?

ELO optimizers ship in PyLO with CUDA-accelerated kernels. Install from source:

git clone https://github.com/Belilovsky-Lab/pylo
cd pylo
pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cu118
PYLO_CUDA=1 pip install --no-build-isolation .
python -m pylo.util.patch_mup

Drop ELO_CELO2_CUDA into a standard training loop like any other PyTorch optimizer:

import torch
from pylo.optim import ELO_CELO2_CUDA

model = torch.nn.Linear(10, 2)

num_steps = 1000
optimizer = ELO_CELO2_CUDA(model.parameters(), lr=3.16e-4, weight_decay=0.1, adam_lr_mult=20)
scheduler = torch.optim.lr_scheduler.CosineAnnealingLR(optimizer, T_max=num_steps, eta_min=3.16e-5)

for step in range(num_steps):
    optimizer.zero_grad()
    loss = loss_fn(model(input), target)
    loss.backward()
    optimizer.step()
    scheduler.step()

Citation

If you use ELO in your research, please cite our paper:

@article{huang2026efficient,
    title={Efficient Long-Horizon Learning for Learned Optimization},
    author={Huang, Xiaolong and Th{\'e}rien, Benjamin and Harrison, James and Belilovsky, Eugene},
    journal={arXiv preprint arXiv:2607.06772},
    year={2026}
}