1-bit LAMB (Error-Compensated LAMB-Preconditioned Large-Batch Compressed Optimization)
Algorithms AIMech:OneBitLambAdaptiveLayerwiseCompressedTraining DRAFT
Aliases: 1-bit LAMB, One-Bit LAMB, 1-bit LAMB Optimizer, Error-Compensated LAMB-Preconditioned Momentum SGD
A two-stage communication-efficient large-batch distributed optimization algorithm that runs uncompressed LAMB for T_w warmup steps while tracking an exponential moving average c_avg^{(l)} = beta_3 c_avg^{(l)} + (1 - beta_3) c_t^{(l)} of each layer's trust-ratio scaling coefficient and storing the warmup-end variance v_{T_w}^{(l)} as a frozen preconditioner, then transitions to two-pass error-compensated 1-bit momentum compression where each worker reconstructs the global layerwise gradient g_t^{(l)} = (m_t^{(l)} - beta_1 m_{t-1}^{(l)}) / (1 - beta_1) from compressed momentum to update a fresh variance estimate v_t^{(l)} and scales the frozen-preconditioned layer update by c_t^{(l)} = r_t^{(l)} c_avg^{(l)} using the double-clipped infinity-norm ratio r_t^{(l)} = clip(clip(||v_{T_w}^{(l)} / v_t^{(l)}||_inf, (1 - r_threshold) r_{t-1}^{(l)}, (1 + r_threshold) r_{t-1}^{(l)}), r_min, r_max).
Identity Notes & Concept Scope
Distinct from uncompressed LAMB (AIMech:LAMBLayerwiseAdaptiveMomentsBatchOptimization, You et al. 2020), which requires full-precision gradient allreduce and up-to-date uncompressed momentum and variance to compute layerwise trust ratios c_t^{(l)} = clip(||x_{t-1}^{(l)}|| / ||u_t^{(l)}||, c_min, c_max). Distinct from 1-bit Adam (AIMech:OneBitAdamErrorCompensatedPreconditionedMomentum, Tang et al. 2021), which freezes variance globally without layerwise scaling or fresh-variance tracking and suffers convergence degradation at large batch sizes (16K-64K), and from naive 'LAMB + basic 1-bit' (Section 3.4), which freezes both variance and c_t^{(l)} and degrades accuracy because LAMB's per-layer variance norms decay by up to two orders of magnitude during training.
Claims & Grounded Evidence
4 Claims
Mechanism
#r630-reconstructed-gradient-and-double-clipped-scaling-ratio
Because LAMB's per-layer variance norms v_t^{(l)} continue decreasing by up to two orders of magnitude throughout large-batch training (Figure 1b), simply freezing both v_{T_w}^{(l)} and LAMB's scaling coefficient c_t^{(l)} ('LAMB + basic 1-bit') degrades BERT validation loss (1.494 vs 1.451) and SQuAD/GLUE accuracy (Tables 2-3); 1-bit LAMB compensates for the frozen denominator sqrt(v_{T_w}^{(l)}) by reconstructing the global layer gradient g_t^{(l)} = (m_t^{(l)} - beta_1 m_{t-1}^{(l)}) / (1 - beta_1) from consecutive compressed momentums, updating a fresh variance v_t^{(l)} = beta_2 v_{t-1}^{(l)} + (1 - beta_2)(g_t^{(l)})^2, and multiplying the warmup moving average c_avg^{(l)} by the soft- and hard-clipped infinity-norm ratio r_t^{(l)} = clip(clip(||v_{T_w}^{(l)} / v_t^{(l)}||_inf, (1 - r_threshold) r_{t-1}^{(l)}, (1 + r_threshold) r_{t-1}^{(l)}), r_min, r_max) (Algorithm 1 Lines 15-21).
Mechanism
#r630-momentum-fusion-and-layerwise-momentum-scaling
To avoid issuing 302 separate per-layer compressed collectives in BERT-Large while preventing layers with small or large momentum magnitudes from suffering severe 1-bit quantization error when fused into a single 1D buffer, 1-bit LAMB computes a fixed per-layer momentum scale coefficient from the average momentum norm at the end of warmup, multiplies each layer's local momentum by its scale coefficient prior to fused 1-bit NCCL Alltoall/AllGather communication, and divides each layer's global compressed momentum by the same fixed coefficient afterward without perturbing error-compensation cancellation.
Scope
#r630-time-varying-error-compensation-convergence-rate
With time-varying effective layerwise learning rate gamma_t = gamma c_{t-1} in [gamma_min, gamma_max] and step-ratio-scaled error feedback m_{t+1/2}^{(i)} = C_omega[m_t^{(i)} + (c_{t-2} / c_{t-1}) delta_t^{(i)}], the global momentum satisfies m_t = beta_1 m_{t-1} + (1 - beta_1) g_bar_t + (gamma_{t-1} / gamma_t) delta_tilde_{t-1} - delta_tilde_t, and the virtual sequence y_t = x_t - (gamma_t m_t + gamma_{t-1} delta_tilde_t) / (1 - beta_1) satisfies y_{t+1} - y_t = -gamma_t g_bar_{t+1}; under Assumption 1 (L-Lipschitz gradients, variance sigma^2, and bounded compression error eps), Theorem 1 and Corollary 1 establish (V_max / T) sum_{t=0}^{T-1} E||grad f(x_t)||_V^2 = O(sigma / sqrt(n T) + eps^{2/3} / T^{2/3} + 1 / T).
Application
#r630-large-batch-bert-volume-reduction-and-speedup
Across BERT-Large pre-training with batch sizes from 8K to 64K on up to 256 V100 GPUs using the 3-phase NCCL Alltoall/AllGather compressed backend, 1-bit LAMB achieves 4.6x and 4.1x end-to-end communication volume reduction for sequence lengths 128 (16.7% warmup) and 512 (19.3% warmup), up to 4.5x compression-stage throughput speedup and 2.8x end-to-end speedup (cutting 256-GPU Ethernet total runtime from 731 minutes to 351 minutes), while matching uncompressed LAMB validation loss (1.443 vs 1.451), SQuAD 1.1 F1 (90.524 avg / 90.788 max), and GLUE average score (83.9 vs 83.9).
⚠️ Curated Limitations & Negative Results
- Introduces additional GPU memory overhead during the compression stage because each worker must store one persistent copy of the fresh variance v_t^{(l)} and one temporary copy of the previous step's compressed momentum m_{t-1}^{(l)} to reconstruct global gradients.
- Requires an uncompressed LAMB warmup phase (e.g., 16.7% of steps for sequence length 128 and 19.3% of steps for sequence length 512) until LAMB's layerwise scaling coefficients reach a stable plateau.
- Requires PyTorch distributed with NCCL >= v2.7 (for Alltoall support) or an MPI-based collective backend to execute the three-phase compressed allreduce.
Artificial Intelligence Ontology (AIO) Grounding
Mapped AIO Classes
| AIO Target Class | Mapping Relation | Mapping Rationale |
|---|---|---|
AIO:ArtificialNeuralNetwork
Artificial Neural Network
|
related_match | 1-bit LAMB is a large-batch communication-compressed adaptive optimizer for distributed pre-training of deep transformer neural networks. |
Evidence Sources & Primary Literature
3 Sources| Source ID | Publication / Document | Type / Access | Reference & Checksum |
|---|---|---|---|
r630-primary-pdf
|
Conglong Li, Ammar Ahmad Awan, Hanlin Tang, Samyam Rajbhandari, Yuxiong He
|
primary paper
full_text
|
ID: https://dblp.org/rec/conf/hipc/LiATRH22
sha256:7bb1c6dcab2a…
|
r630-arxiv-abs
|
Conglong Li, Ammar Ahmad Awan, Hanlin Tang, Samyam Rajbhandari, Yuxiong He
|
primary paper
abstract_only
|
ID: https://arxiv.org/abs/2104.06069
sha256:46028042ec6c…
|
r630-metadata-cr
|
Conglong Li, Ammar Ahmad Awan, Hanlin Tang, Samyam Rajbhandari, Yuxiong He
|
primary paper
abstract_only
|
ID: https://dblp.org/rec/conf/hipc/LiATRH22
sha256:32bca0f71b06…
|
Ontology & Grounding Topology
Open in interactive network graph →Curation Provenance
Curator: Antigravity
Method: ai_assisted
Model: Gemini
Created: 2026-10-19T11:53:00Z
Updated: 2026-10-19T11:53:00Z
Source File:
data/curated/OneBitLambAdaptiveLayerwiseCompressedTraining.yaml
· Schema:
curated_concept.yaml
Explore across X-Mech
Related computational & biological Mechs:
Embedding Map
Network Graph
ProteinTraitsMech (ESM-2 pLM)
DUFMech (Domain pLM)
TraitMech
CultureMech
All 14 X-Mech Repositories