Loop-Count Schedules in Looped Transformers: An Empirical Study
Abstract
Looped transformers apply one block of layers several times with shared weights, trading parameters for repeated computation. We study how the schedule of the loop iteration count R during training determines whether each extra pass acts as a full layer or as a small correction, using a controlled ladder of 46M-110M-parameter models trained on 2B tokens with learned residual gates on every loop pass and three schedules: R fixed to 2, R sampled uniformly from 1,...,6, and R sampled from 2,3,4. We find that the lower bound of the sampling range is the decisive choice. If the sampled range includes R=1, so that some training steps run the block only once and compute the loss on that single pass, the gates collapse to 0.1-0.5 and each additional pass becomes a small correction to the first; if the range starts at R=2, so that every training step runs the block at least twice, the gates stay at 0.6-0.9 and each pass keeps the strength of a full layer, while the model can still be run at any R from 2 up to twice the largest trained value with validation loss within a few hundredths of a nat of its best. The 2, 3, 4 schedule gives the best looped model, 2.909 nats against 2.951 for the parameter-matched plain model, and degrades by only 0.038 nats when run at twice its trained depth. We further show that under a fixed R the direction of the residual stream converges geometrically beyond the trained depth while the loss diverges, which refines a recent finding that static-depth training does not converge, and that reusing the first pass's keys and values on later passes costs 0.01-0.03 nats in every regime while making the per-token iteration uniformly contractive and halving the inference cache. The loop recovers about a third of what real depth provides at equal parameters. The code, trained weights, and per-token traces are released.
Create a lesson
Related papers
From Learning Rates to Rotational Schedules: Finite-Horizon Theory on the Sphere
Shared title terminology · Jacopo Graldi, Antonio Orvieto, Anastasia Koloskova
OnCache: Learning Dynamic Caching Schedules for Efficient Diffusion Inference
Shared title terminology · Zhikang Xie, Xichen Ye, Yifan Wu et al.
Joint Client Scheduling and Resource Allocation for Optimal Federated Learning over Wireless Networks
Shared title terminology · Ahmad Dabaja, Rachid El-Azouzi
Cross-Site Transformers Are Robust Heart Rate Estimators
Shared title terminology · Mason Kadem, Rong Zheng
SONATI: Spatio-temporal ocean neighbourhood asymmetric transformer for imputation of sparse, tabular data with uncertainty
Shared title terminology · Yvonne Jenniges, Boris Peter Koch, Maike Sonnewald et al.
Failure Modes and Data-Efficient Remedies for Transformer-Based Prediction of Viscoplastic Flows
Shared title terminology · Maedeh Saberi, Hugo Franca, Maziyar Jalaal et al.