Scalable Analog Training

Analog in-memory computing

Making Analog Training Scale

Co-Designing Mapping, Optimizer, and Converters

Zhaoxian Wu1 Tayfun Gokmen2 Omobayode Fagbohungbe2 T. Patrick Xiao3 Tianyi Chen1

1 Cornell Tech and Cornell University2 IBM T. J. Watson Research Center3 Sandia National Laboratories

arXiv preprint · September 2026

TL;DR

  • Keep matrix passes analog, gradient handling digital. Crossbars execute forward and backward matrix operations; digital circuitry forms weight gradients, runs the optimizer, and accumulates updates.
  • Co-design the interface. Weight mapping, logical-space optimization, and converter range alignment work together to preserve training fidelity under hardware constraints.
  • Evaluate scaling with realistic non-idealities. Preliminary AIHWKit simulations reach approximately 123.6M Transformer parameters, with a loss-scaling exponent close to the digital baseline and a remaining absolute loss gap.

This work presents the possibility to train a GPT2-like Transformers trained from scratch on analog in-memory computing hardware. The evaluations are based on IBM AIHWKit simulations include finite conversion resolution and range, input/output noise, and asymmetric, discrete device programming calibrated to ECRAM measurements.

123.6MLargest evaluated model
2.47BProcessed tokens
−0.231Analog loss-scaling exponent
−0.238Digital loss-scaling exponent

Explore the scaling figure

Three views · overlaid fits

Explore model size, token trajectories, and compute trajectories, with endpoint fits drawn directly on each plot. Inspect points for exact values; select a model to compare its analog and digital learning curves.

Five panels showing the manuscript’s analog and digital Transformer training results across model scales.
Preliminary scaling results under the Chinchilla-style training protocol. Parameter-scaling fits yield \(L\propto N^{-0.231}\) for analog training and \(L\propto N^{-0.238}\) for digital AdamW. One seed per condition.

How to read the result. Similar scaling exponents indicate comparable loss improvement with increasing model size over the evaluated range. Analog training still has a persistent validation-loss gap relative to the digital baseline.

Analog in-memory computing

Matrix multiplication is a central operation in neural networks. In conventional digital hardware, computing it requires moving weights from memory to a processor. Analog in-memory computing (AIMC) stores weights as conductances in non-volatile memory crossbars and performs the multiplication where those weights reside, reducing data movement and offering an energy-efficient way to execute matrix operations.

A crossbar computes through electrical currents: each conductance multiplies an applied input voltage, and currents add along the output lines. Digital-to-analog converters (DACs) encode the inputs, while analog-to-digital converters (ADCs) return the result to digital circuitry. The array supports both the forward matrix pass and the transposed matrix pass used in backpropagation.

Analog matrix–vector multiplication (MVM)

Crossbar computation

Hover or focus a conductance cell, output column, DAC, or ADC to see how voltages become a matrix–vector product. Click, tap, or press Enter to pin an explanation; Escape clears the pin.

DACs convert inputs to voltages. Each conductance cell multiplies a voltage by a weight, output currents sum along columns, and ADCs digitize the result: y = Ŵx. The backward pass uses the transpose: δin = Ŵᵀδout.

Why analog training is hard

Training requires more than fast matrix multiplication. Each iteration must propagate activations forward, propagate error signals backward, and use weight gradients to update the stored conductances. Small updates must remain effective over thousands of iterations as the weights and signal distributions evolve.

Two hardware constraints make this difficult. DACs and ADCs have finite precision and range, so quantization and clipping can distort the forward and backward signals. Weight programming introduces a second constraint: updates arrive as discrete pulses whose effects depend on the current conductance and can differ between increasing and decreasing directions. Together with read and write noise, these non-idealities perturb the learning signal and the update trajectory.

AIMC hardware non-ideality model

Switch between pulse updates and converter quantization. Compare a pulse sweep or alternating pulses, adjust the device response, and inspect the equations below the plot.

  • DAC / ADC quantization maps an input vector onto finite levels.
  • Weight updates arrive as finite, potentially asymmetric pulses.

Hardware errors propagate and accumulate across layers during both the forward and backward passes. As models grow in depth and width, these errors can increasingly distort gradients and weight updates, with effects that compound over the training trajectory. This scaling challenge has kept most existing demonstrations of analog training at relatively small model and dataset scales. Scaling therefore requires preserving gradient fidelity while keeping logical weights, physical conductances, and converter ranges compatible. The training-scale landscape below compares these prior demonstrations with this work.

The training-scale landscape

34 study entries · logarithmic axes

Hover or focus a point to inspect a study. Click or tap to keep its details open.

Prior studiesThis workCoincident points retain their reported coordinates.
Model and dataset scale of analog training studies. Counts describe distinct analog-mapped weights and the training subset or stream actually used. Image inputs use 16 × 16 patch equivalents; language inputs use token IDs; other inputs use scalar counts. These units are a scale proxy, not equal information content. Hardware and simulation evidence are identified in each study’s details.

The central question. How can analog training continue to scale with model and dataset size while preserving convergence under hardware non-idealities?

The mixed-signal architecture

The framework assigns each operation to the domain that best fits its numerical requirements. Analog arrays perform the forward matrix pass and the transpose operation in backpropagation. The precision-sensitive update path stays digital.

Mixed-precision (MP) training architecture

Explore the partition

Compare digital mixed precision, the analog MP baseline, and this work. Hover or focus a component to animate its signal paths; click or press Enter to pin its explanation. Escape clears the pin.

The analog MP baseline executes forward and backward matrix passes in a DAC–crossbar–ADC path, while digital circuitry accumulates gradients and residual updates. This work adds logical-space optimization, width-aware mapping, and converter alignment.

One training step, two domains

Analog crossbarDigital circuitry
Analog matrix execution

y = Wx

Inputs pass through DACs into the conductance array. The crossbar computes the matrix–vector product, and ADCs return a digital output. Mapping and converter range alignment preserve signal fidelity.

This partition follows the established mixed-precision architecture of Nandakumar et al. (2020): analog arrays execute forward and backward matrix passes, while digital circuitry computes and accumulates weight updates. Retaining digital weight-gradient (W-grad) computation, however, incurs dense arithmetic and storage overhead.

In principle, W-grad could instead use the parallel analog rank updates of Gokmen and Vlasov (2016). Activation and error signals drive outer-product updates directly on the crossbar, reducing the update complexity of a \(D\times D\) layer from \(O(D^2)\) to \(O(D)\). Nandakumar et al. point to device-endurance concerns with this approach. We examine the tradeoff from the perspective of scaling: can this computational saving preserve the gradient information needed for stable training as models grow?

Why weight-gradient accumulation should remain digital

We accept the arithmetic and storage cost of digital W-grad for two compounding reasons: gradient reduction is highly sensitive to precision loss, and fragmenting a batch update into frequent quantized transfers repeatedly introduces write-path error. The experiments below trace these mechanisms from signal precision to the realized array update.

W-grad is sensitive to precision loss

First, consider a purely digital Transformer training experiment (panel a). Quantizing weights or activations to FP8 barely changes final validation loss relative to FP16, while the same precision reduction in the gradient path severely impairs convergence. This control quantizes backward error signals and parameter gradients while arithmetic and reductions remain FP32. Gradient fidelity is therefore already critical before analog accumulation or device programming enters the picture.

Cancellation amplifies accumulation error

A weight gradient sums many signed contributions. For one coordinate, \(+10.0\) and \(-9.9\) leave a residual of only \(0.1\): small rounding errors in the large terms can overwhelm the useful update. The cancellation factor \(\kappa=\sum_b|g_b|/|\sum_b g_b|\) measures this imbalance. Its mean is far above one across all six measured Transformer projection types (panel b). Replaying the same contributions with rounding after every addition shows why this matters: relative gradient error grows with cancellation strength, with substantial error even in FP16 and much larger error in FP8 (panel c). Accurate accumulation must preserve the small signed residual throughout the reduction.

Consolidation avoids repeated quantized-transfer error

Digital accumulation also controls how often an update reaches the array. Panel d holds the total batch at 128 on a symmetric finite-state device. Each micro-batch gradient enters a digital residual and immediately requests a quantized full-rank transfer. Smaller micro-batches create more transfer events; each reintroduces pulse-count truncation and capping, update-management effects, and finite-state programming error. These discrepancies accumulate over the fixed batch. Larger micro-batches consolidate more contributions digitally and request fewer transfers, reducing the one-step realized-update error. The direct rank-update result is independent of the micro-batch partition in this test and is shown once.

Why the gradient path needs higher fidelity

Four experiments, one argument

Explore precision sensitivity, cancellation, accumulation error, and fragmented transfers. Select a label to view each experiment; hover, tap, or focus a bar or point for its values.

  1. Precision sensitivity: FP8 gradient-path representations impair convergence while weights and activations remain tolerant.
  2. Gradient cancellation: large opposing contributions leave a small signed residual.
  3. Accumulation error: rounding after each addition increasingly distorts that residual as cancellation grows.
  4. Transfer fragmentation: consolidating updates digitally reduces repeated quantized-transfer error.
Precision sensitivity: FP8 gradient representations raise validation loss, while weights and activations remain tolerant.
Gradient cancellation: arithmetic mean cancellation factors for query, key, value, attention output, and MLP up/down projections.
Accumulation error: FP32, FP16, and FP8 relative gradient errors increase with cancellation strength; the error axis is logarithmic.
Transfer fragmentation: larger MP micro-batches reduce one-step update error compared with frequent transfers and direct rank updates.

Four-seed means; whiskers and bands show the observed seed min–max range. View all four panels (SVG).

Design principle. Preserve the net gradient digitally and consolidate updates before programming the array. This protects the learning signal while analog forward and backward matrix passes retain their computational advantage.

Three parts of the co-design

Digital accumulation is the starting point. Scaling also requires the logical model, the physical array, and the converters to operate in compatible numerical ranges.

01

Weight mapping

Logical initialization should shrink with layer width, while the physical weight distribution should be centered on the device’s symmetric point and occupy a fixed fraction of its conductance range. A width-aware scale reconciles these requirements.

Logical weights
Std(W) ∝ D−1/2
Physical deviations
Std(Ŵ − Ŵ⋄) = τ/ω

To satisfy both, we design \(s\propto D^{-1/2}\):

W = s(Ŵ − Ŵ⋄), s = ωD−1/2 / τ ∝ D−1/2

\(W\) is the logical weight; \(\widehat W\) is the physical conductance and \(\widehat W^\diamond\) its device-specific symmetric point, where potentiation and depression have equal response magnitudes. \(D\) is the layer’s input width; the logical initialization target is \(D^{-1/2}\). The targets above are standard deviations: logical variance scales as \(D^{-1}\), while the physical pre-clipping target \(\tau/\omega\) is independent of width.

Centering the physical weight distribution at \(\widehat W^\diamond\) aligns the device’s symmetric point with logical zero. Near this point, potentiation and depression responses are similar, so update asymmetry is mild and causes less distortion of the intended training updates. For weights farther away, state-dependent asymmetry favors updates toward the symmetric point, creating a restoring tendency toward logical zero. Under noisy updates, this tendency induces an implicit penalty; for approximately linear response asymmetry, it resembles implicit weight decay, with a restoring component proportional to \(-W\) (Wu et al., 2025). Its effective strength depends on the device response and update statistics.

Logical and physical weight distributions

Explore the mapping scale

Tune \(\omega\) to change physical occupancy and \(D\) to change the logical initialization. The compensating scale keeps the two targets compatible.

The physical target has standard deviation \(\tau/\omega\), while logical initialization scales as \(D^{-1/2}\). The map uses \(s=\omega D^{-1/2}/\tau\).

02

Logical-space optimization

A digital optimizer, such as Adam or AdamW, generates the signed logical update \(\Delta W_k\). Keep its moments and preconditioners digital, then use a residual buffer and threshold-triggered pulsing to transfer that update into noisy, discrete physical writes.

Hk+½ = Hk + ΔWk
Nk = trunc(Hk+½ / (sΔwmin))
Hk+1 = Hk+½ − sNkΔwmin

\(\Delta W_k\) comes from the optimizer, such as Adam. \(H\) stores the untransferred residual in logical units; \(N\) counts signed physical pulses of nominal size \(\Delta w_{\min}\). Truncation is toward zero.

03

Converter alignment

Apply converter alignment (CA) in both the forward and transposed backward matrix passes: their activations and error signals can have different, evolving distributions. Align converter ranges to balance clipping against quantization error. Let \(C>0\) be the clipping rail for the unscaled input vector \(x\): the quantizer represents values within \([-C,C]\), and values outside this range are clipped to its endpoints.

Consider a \(D\)-dimension vector \(x\) whose elements are sampled from a distribution \(\mathcal V\). The rail optimization problem chooses a norm order \(p\) and multiplier \(A\) in \(C=A\lVert x\rVert_p\) to minimize expected reconstruction error per coordinate:

\[\begin{aligned} r_K(\mathcal V)&:=\inf_{p\in[1,\infty]}\inf_{A>0}R_K(p,A;\mathcal V),\\ R_K(p,A;\mathcal V)&:=\frac{1}{D}\,\mathbb E_{x\sim\mathcal V}\!\left[\left\lVert Q_{K,A\lVert x\rVert_p}(x)-x\right\rVert_2^2\right]. \end{aligned}\]

\(\mathcal V\) is the input distribution, \(D\) is the vector dimension, and \(Q_{K,C}\) is the coordinatewise uniform saturating quantizer with resolution parameter \(K\) and rail \(C\).

Max alignment is an inexpensive approximate solution: choose \((p,A)=(\infty,1)\), giving \(C=\lVert x\rVert_\infty\). This avoids repeated distribution fitting and rail optimization during training; it need not minimize distortion at finite precision.

\(C=\lVert x\rVert_\infty\)
u = DAC(x/C)
z = (Ŵ − Ŵ⋄)u + ξ
y = sC · ADC(z)

Prescale \(x\) digitally to a fixed DAC range \([-1,1]\), then restore \(sC\) after conversion. \(u\) is the DAC output; \(z\) is the physical crossbar current, including read noise \(\xi\). The physical ADC rail is chosen separately for this current.

Try converter alignment

Input quantization

Choose Gaussian or Laplacian inputs and a vector size, then compare max alignment, Optimal Rail, and ACIQ rails. Paired bars show each original and reconstructed coordinate; the error chart compares all methods on the same vector.

A narrow rail clips large coordinates; a wide rail spreads conversion levels apart. Max alignment sets C to the largest absolute input, eliminating input clipping. With JavaScript enabled, compare paired coordinate bars and method errors on Gaussian or Laplacian vectors of adjustable size.

The rail \(C\) describes the range of the unscaled digital input. Prescaling by \(1/C\) keeps the physical DAC range fixed.

Technical detail: ACIQ formulation and why we use max alignment

Analytical clipping for integer quantization

ACIQ selects a scalar rail under an assumed, centered population density \(f\). Its approximate mean squared error combines clipping beyond \([-C,C]\) with rounding error \(\Delta^2/12\), where \(\Delta=2C/K\):

\[\begin{aligned} C_{\mathrm{ACIQ}}&\in\operatorname*{arg\,min}_{C>0}\widetilde E_{f,K}(C),\\ \widetilde E_{f,K}(C)&=\int_{|z|>C}(|z|-C)^2f(z)\,dz+\frac{C^2}{3K^2}. \end{aligned}\]

For Gaussian inputs \(z\sim\mathcal N(0,\sigma^2)\), and Laplace inputs \(z\sim\operatorname{Laplace}(0,b_L)\), the clipping integrals give:

\[\begin{aligned} \widetilde E_{G,K}(C)&=(\sigma^2+C^2)\operatorname{erfc}\!\left(\frac{C}{\sqrt2\sigma}\right)\\ &\quad-\sqrt{\frac2\pi}\,C\sigma\,e^{-C^2/(2\sigma^2)}+\frac{C^2}{3K^2}. \end{aligned}\]
\[\widetilde E_{L,K}(C)=2b_L^2e^{-C/b_L}+\frac{C^2}{3K^2}.\]

Here \(\sigma\) is the Gaussian standard deviation, \(b_L=\mathbb E|z|\) is the centered Laplace scale, and \(\operatorname{erfc}\) is the complementary error function. Setting the derivative to zero gives \(C=t_G(K)\sigma\) or \(C=t_L(K)b_L\); these resolution-dependent multipliers can be precomputed.

Resolution convention. Original ACIQ uses \(2^b\) bins at \(b\) bits. The playground adapts its rounding term to the displayed endpoint quantizer, with \(K=2^b-1\) intervals, while keeping the same clipping integrals. These formulas are analytical approximations to population error, not the displayed vector’s exact MSE. Authors’ ACIQ formulation.

Why our training architecture uses max alignment

Adapt to changing distributions without choosing a prior. During training, forward activations and backward error signals evolve. A distribution-specific threshold can become suboptimal as its assumed law or scale changes, requiring repeated estimation and recalibration. \(C=\lVert x\rVert_\infty\) adapts directly to each vector with one maximum-absolute-value reduction and avoids input clipping. The concern is maintaining a suitable distribution model during training, rather than recomputing ACIQ’s scalar multiplier.

Approximate the norm–rail optimum with a simple rule. The manuscript optimizes \(C=A\lVert x\rVert_p\) through \(r_K(\mathcal V)\). For fixed dimension \(D\ge2\) and an absolutely continuous input law with finite second moment, it proves that max alignment approaches the best distortion in this family as precision increases:

\[\lim_{K\to\infty}\frac{R_K(\infty,1;\mathcal V)}{r_K(\mathcal V)}=1.\]

Check precision and width, not one sample. The manuscript compares calibrated norm–rail policies and fixed Gaussian/Laplace ACIQ thresholds across both precision and dimension. At \(D=48\), max alignment is within 10% of the calibrated distortion from four bits onward for both synthetic product laws; the curves nearly coincide at higher precision. The fixed ACIQ comparators show a remaining gap and sensitivity to the assumed prior.

Manuscript comparison of max alignment, calibrated norm–rail optimization, fixed RMS, and Gaussian/Laplace ACIQ thresholds over quantization precision and vector width.
Manuscript’s controlled reconstruction-distortion experiment. Precision scans use 100,000 vectors at \(D=48\); width scans use six bits. It evaluates original, fixed ACIQ thresholds with \(K_b=2^b-2\) endpoint intervals. The playground above instead refits ACIQ scales on one vector and uses \(2^b-1\) intervals. Open full-size figure.

These results support a low-overhead, distribution-agnostic training policy, without claiming universal finite-bit optimality. At six bits, the 10% criterion holds through \(D=1{,}024\), and the gap opens around \(D=2{,}048\), especially for Laplace inputs. ACIQ can be useful when its prior matches, particularly at low precision. This experiment isolates input quantization; it does not measure end-to-end training accuracy or energy.

Future Work

We believe analog training chips deserve a broader research effort connecting machine learning, optimization, computer architecture, circuits, and device physics. This work explores one way to make analog training scale, but many fundamental questions remain open. Several directions seem especially promising:

A principled approach to analog training

What numerical fidelity does learning actually require? A principled approach would connect hardware noise, finite precision, and imperfect weight updates to optimization and generalization, then use that understanding to guide algorithm and hardware design. Especially useful would be predictions of how these requirements change with model size and training duration, giving hardware designers targets grounded in learning behavior.

Related papers

Learning algorithms designed for analog hardware

Can we design optimizers, model architectures, and training recipes that work naturally with noisy computation and discrete updates? Promising questions include whether we can reduce the precision or storage needed for gradients and optimizer state, and whether alternatives to standard backpropagation offer a better balance of learning quality and hardware cost. Digital gradient handling is our current design choice; finding efficient alternatives remains an open research direction.

Related papers

Architecture research beyond a single crossbar

What should a complete analog training computer look like? There is a broad design space in how analog arrays, digital compute, memory, and communication work together. Exploring that space could reveal how to organize many tiles or chips, reuse training data, and place gradient and optimizer computation so that local analog efficiency translates into lower energy and faster training for the whole system.

Related papers

Devices and circuits guided by learning needs

Which physical improvements would most improve training? Connecting learning experiments to device and circuit design could help prioritize update symmetry, programming resolution, endurance, noise, and conversion cost. A promising goal is to identify which imperfections algorithms can tolerate or compensate for, and which require better hardware, then build and test chips around those requirements.

Related papers

Scaling up and finding useful applications

How far can analog training scale, and where would it be most valuable? Larger models and longer training runs could establish how model quality changes with hardware resources and energy. Fine-tuning, continual learning, and adaptation on edge devices offer complementary questions: can local weight updates make deployed systems more useful under tight power and memory budgets? Shared benchmarks and working chip demonstrations would help turn these possibilities into evidence.

Related papers

Looking ahead. Our architecture-level simulations are one starting point. We welcome work that develops the theory, explores different algorithms and architectures, and brings these ideas into measured hardware. The goal is to understand where analog training can deliver useful learning at a practical cost.

Resources

Manuscript on arXiv

Making Analog Training Scale: Co-Designing Mapping, Optimizer, and Converters.

arXiv:2609.36584
Research code on GitHub

Project repository for the training framework and reproduction materials.

IBM AIHWKit

The open-source simulation substrate used in this study.

AIHWKit beta fork

Our beta fork of AIHWKit, with experimental features that may not yet be incorporated into the official toolkit.

MixedPrecisionOptim

A plug-and-play optimizer package for mixed-precision analog training, supporting modern optimizers such as Adam and Muon.

BibTeX

@misc{wu2026makinganalogtrainingscale,
  title         = {Making Analog Training Scale: Co-Designing Mapping, Optimizer, and Converters},
  author        = {Wu, Zhaoxian and Gokmen, Tayfun and Fagbohungbe, Omobayode and Xiao, T. Patrick and Chen, Tianyi},
  year          = {2026},
  eprint        = {2609.36584},
  archivePrefix = {arXiv},
  primaryClass  = {cs.LG},
  url           = {https://arxiv.org/abs/2609.36584}
}