Chips that compute inside memory cut the energy spent moving numbers between memory and processor. They do this by storing a network's weights as electrical conductances and letting the circuit's physics perform matrix multiplication. Such chips are natural candidates for federated learning, where many small devices train on their own private data and send only model updates to a server. The same updates are known to leak that data: an attacker who holds the model and one update can often reconstruct the training images. This proposal asks a concrete question about analog in-memory training clients. When the attacker knows exactly how the chip works, how much of the private data survives the chip's built-in coarseness? That coarseness has three sources: low-resolution readout converters, noisy device writes, and threshold-triggered weight programming.
Our main claim is that the coarseness comes in two kinds with very different privacy value. The readout converter's quantization is fixed by the circuit design and is therefore public, so an informed attacker can model it and undo most of its protective effect. The stochastic, threshold-gated programming step is different. Here a device is only rewritten once an accumulated update crosses a threshold, and the write itself lands imprecisely. This step discards information that no attacker model can restore. One hardware parameter, the programming threshold, controls three things at once: how many costly write pulses the chip issues (energy), how coarse the transmitted update is (quantization loss), and how much data can be recovered (leakage). We propose to measure this three-way frontier for the first time. We will also test whether it beats software defenses at matched accuracy.
Core Claim and What Is New
Prior work connects these directions only in pairs. On the privacy side, Mixed Quantization Enabled Federated Learning to Tackle Gradient Inversion Attacks and Mixed Precision Quantization to Tackle Gradient Leakage Attacks in Federated Learning quantize gradients to 8 or 16 bits in software on digital hardware. Their security rests on keeping per-layer scaling factors secret, which forces an attacker to search $m^L$ configurations ($m$ quantization modes across $L$ layers). Neither was tested against an attacker who differentiates through the quantizer. On the hardware side, RAOQ and MemTorch treat the readout converter purely as an accuracy problem. RAOQ counters it with distribution reshaping. MemTorch documents an accuracy cliff below 4–5 converter bits. Mixed-Precision Deep Learning Based on Computational Memory supplies the training scheme we build on. In that scheme, the analog array runs forward and backward passes, a digital register accumulates small updates, and a single "blind" programming pulse fires when the register crosses a threshold. It reports 97.73% MNIST accuracy with a 172× energy gain but never considers who sees the resulting updates.
The new element is to treat the whole path from private image to transmitted update as one physical channel, and to attack it with a hardware-informed adversary. We then separate the part of the channel that is deterministic and public from the part that is stochastic. The prediction is sharp and falsifiable. Against a hardware-aware attacker, reconstruction quality should depend weakly on converter bit-width and strongly on the pulse threshold and write noise.
For one weight, write the accumulated digital update as $\chi$, the programming threshold as $\epsilon$, and the device's per-pulse conductance change as $\epsilon(1+\eta)$, where $\eta$ is random write noise. The update the chip applies, and therefore what the server sees, is then
$$\Delta w = \mathrm{sign}(\chi)\,\epsilon\,(1+\eta)\,\mathbb{1}[|\chi|\ge\epsilon],$$
with the remainder $\chi - \mathrm{sign}(\chi)\epsilon$ kept on the client. Raising $\epsilon$ means fewer pulses, a sparser and coarser update, and more information held back locally. The open question is whether the accuracy cost of this setting stays small before the leakage falls. That is what the frontier measures.
Research Program
The first component is a simulated federated client doing in-situ analog training. MemTorch models finite conductance states, device variability, stuck-at faults and converter resolution, but supports only inference. We will extend its device models to the backward pass and to the digital-accumulator/blind-pulse update, following Nandakumar et al. As a second update rule we will add Tiki-Taka. Towards Exact Gradient-based Training on Analog In-memory Computing proves that Tiki-Taka behaves as a low-pass filter through an auxiliary array. Filtering across steps plausibly smears per-sample information, which gives us a second, independent hardware mechanism to probe.
The second component is the attacker. We start from the cosine-similarity inversion of Inverting Gradients, which matches the direction of the gradient under a total-variation image prior, and from the original gradient-matching loss of Deep Leakage from Gradients. We make the attack hardware-aware in three steps. The known converter ladder is passed through with a straight-through estimator, meaning the rounding is treated as the identity when differentiating. Write noise is marginalized by averaging the matching loss over sampled noise draws. The local training steps are unrolled through the simulated threshold rule, with a continuous relaxation of the indicator.
We also test the secrecy assumption behind mixed-quantization defenses directly. On a real chip the converter reference ranges come from a small set fixed by circuit design, so the attacker enumerates that set rather than $m^L$ arbitrary configurations.
The third component is accounting. For every client configuration we record test accuracy, reconstruction quality, and energy proxies. The energy proxies are the number of programming pulses and the number and bit-width of converter reads per step, reported as relative counts. We do not report joules, since the file gives no calibrated per-operation figures we could honestly reuse.
Baselines
The naive reference points are an undefended digital floating-point client and an analog client with the highest converter resolution and smallest threshold. The digital client anchors the best possible accuracy. In MPQ FL, undefended CIFAR-10 accuracy is 60.04% in their small-model setting. The high-resolution analog client tells us whether in-memory training leaks as much as digital training does before any knob is turned.
The strongest quantization-based competitor is software mixed-precision gradient quantization with locally retained scaling factors, run on a digital client. The cited papers report 58.9% CIFAR-10 accuracy against 38.39% for differential privacy (MPQ FL). They also report a drop in inversion PSNR from 55.3 to 8.1, along with 96.67% MNIST accuracy (Mixed Quantization FL). These are the numbers to beat. However, we will re-attack this baseline with the same hardware-aware attacker, because its published PSNR was measured against non-adaptive attacks.
The strongest general defense is CENSOR. CENSOR samples updates from the space orthogonal to the true gradient under a cold posterior and reports roughly 86% CIFAR-10 accuracy while reducing five attacks' reconstructions to noise. It needs full-precision arithmetic on the client, which is exactly what an analog client lacks.
Calibrated Gaussian noise differential privacy is the standard reference. We add randomized quantization from Randomized Quantization is All You Need for Differential Privacy in Federated Learning because it is the closest software analogue of stochastic device writes.
For fairness, all methods use the same architectures (LeNet-5 to match the quantization papers, ResNet-20, and ResNet-18), the same federated data splits, the same number of local steps and rounds, and the same hyperparameter search budget per method. Every defense faces both the vanilla attacker and the hardware-aware adaptive attacker with an equal optimization budget.
The key ablation removes device stochasticity. It keeps the threshold-and-sign rule but applies it digitally with $\eta=0$, which isolates the physical noise from the compression. Beating the baselines means lower reconstruction PSNR and SSIM than mixed quantization and randomized quantization at matched test accuracy, while issuing fewer programming pulses than the high-resolution analog client.
Why not just…?
Why not just use software mixed-precision quantization on an ordinary digital client? It is cheap, and it reports large PSNR drops. Its protection, though, is argued from a secret search space, and it was never tested against a straight-through adaptive attacker. Our re-attack settles whether that protection holds. Even if it does, it saves communication bandwidth but not the on-chip data movement that motivates in-memory hardware. The comparison that matters is leakage at equal accuracy and equal energy proxy, and we report exactly that.
Why not just add differential privacy noise? The file's evidence is consistent: noise strong enough to stop inversion costs roughly 15–22 accuracy points. In MPQ FL, CIFAR-10 falls from 60.04% to 38.39%, and Deep Leakage from Gradients finds that inversion stops only once noise variance exceeds about $10^{-2}$. Formal guarantees are a real advantage of noise-based privacy that our empirical audit does not provide. We therefore include randomized quantization at matched formal budgets and report whether the device-noise channel attains comparable empirical leakage at higher accuracy. We do not claim a guarantee.
Why not just call this gradient compression, since threshold-and-sign updates are sparsified sign updates? This is the real threat to the proposal. If the digital emulation with $\eta=0$ matches the analog client's leakage frontier, then device physics adds nothing beyond compression. The contribution would shrink to showing that analog training clients inherit compression-style protection for free, together with the energy accounting. The ablation is designed to decide this. Pruning-style defenses are also known to be bypassed by generative priors (CENSOR), so we include a generative-prior attacker in the style of Gradient Inversion with Generative Image Prior against every sparse configuration.
Why not just encrypt the updates? PPIMCE shows that even an in-SRAM cryptographic engine still needs gigabytes of client–server traffic for garbled-circuit labels and was built only for inference. We treat encryption as an orthogonal, costlier layer rather than a competitor.
Proposed Experiments
The attack benchmarks are CIFAR-10 and CIFAR-100 at batch sizes 1, 8 and 32, with a small ImageNet subset on ResNet-18 to test scale. The utility benchmarks are federated MNIST, Fashion-MNIST and CIFAR-10 accuracy. For analog training, the reference points are Nandakumar's 97.73% MNIST result and Tiki-Taka's reported 95.15% on ResNet-34 CIFAR-10 against 93.44% for digital SGD. Our simulator must first reproduce these trends, not necessarily the exact values, before any privacy claim is made.
The reconstruction reference for the undefended case is the roughly 14 dB PSNR that Inverting Gradients reports on a trained ResNet-20 with cosine matching. We found no Lacuna-reported reconstruction numbers for Fashion-MNIST or for CENSOR's LPIPS, so we generate those ourselves.
The central experiment sweeps converter bits (4 to 8) against the pulse threshold $\epsilon$ at fixed write-noise levels. For each point we plot accuracy, adaptive-attack PSNR, and pulse count.
Three outcomes are decisive. The first confirms the main claim: PSNR is nearly flat in converter bits under the hardware-aware attacker but falls steeply with $\epsilon$, while accuracy stays within a few points of the digital baseline. The second refutes the "hardware quantization is a defense" framing: the converter-only configurations leak as much as the undefended digital client. The third falsifies the physical-noise claim: the $\eta=0$ digital emulation reproduces the analog frontier.
A secondary check enumerates the realistic set of converter reference ranges. It measures whether the $m^L$ secrecy argument of mixed-quantization defenses survives when the attacker knows the chip family.
References
- Mixed Quantization Enabled Federated Learning to Tackle Gradient Inversion Attacks
- Mixed Precision Quantization to Tackle Gradient Leakage Attacks in Federated Learning
- Reshape and Adapt for Output Quantization (RAOQ): Quantization-aware Training for In-memory Computing Systems
- MemTorch: An Open-source Simulation Framework for Memristive Deep Learning Systems
- Mixed-Precision Deep Learning Based on Computational Memory
- Towards Exact Gradient-based Training on Analog In-memory Computing
- Inverting Gradients - How easy is it to break privacy in federated learning?
- Deep Leakage from Gradients
- CENSOR: Defense Against Gradient Inversion via Orthogonal Subspace Bayesian Sampling
- Randomized Quantization is All You Need for Differential Privacy in Federated Learning
- Gradient Inversion with Generative Image Prior
- Privacy Preserving In-memory Computing Engine