Preprint
Article

This version is not peer-reviewed.

Adaptive Stopping Rules for Probabilistic-Bit Classifiers with Autocorrelated Stochastic Magnetic Tunnel Junction Neurons

Submitted:

09 October 2026

Posted:

12 October 2026

You are already at the latest version

Abstract
Probabilistic-bit (p-bit) classifiers built from stochastic magnetic tunnel junctions (sMTJs) are usually read at most once per two dwell times to keep reads nearly independent. Reading faster leaves each neuron’s firing probability unchanged but makes successive votes autocorrelated, which matters for adaptive inference that stops once the decision is declared settled. We simulate a p-bit multilayer perceptron whose hidden neurons follow two-state telegraph dynamics with the exact p-bit stationary law, and replay five stopping rules against the same recorded vote streams on MNIST and Fashion-MNIST. At half the correlation time, the stopping error on low-margin inputs of a Wald sequential probability ratio test and the Adaptive-Consistency Dirichlet rule, which treat votes as independent, rises three- to fourfold over ideal randomness, while whole-test accuracy moves at most 0.2 points. The cause is lost effective sample size. A Markov-chain likelihood calibrated once per operating point from unlabelled, reference-masked reads keeps error within the configured level down to one correlation time, reducing but not removing the excess over ideal randomness, at 1.3–1.4 times the throughput of throttled Adaptive-Consistency; an e-process does so without device measurement. Below one correlation time the correction’s compliance is partial, and re-estimating the correlation online per input is degenerate.
Keywords: 
;  ;  ;  ;  ;  ;  ;  ;  

1. Introduction

Adaptive inference spends computation only where it is needed: a classifier that draws repeated stochastic passes can halt as soon as a stopping rule judges its decision settled, so easy inputs are answered in a few passes and hard ones receive more. Probabilistic-bit (p-bit) hardware is a natural host for this kind of inference, because each neuron is already a source of randomness [1,2,3]. When that neuron is a stochastic magnetic tunnel junction (sMTJ), an input (current or voltage) pulls the time-averaged free-layer state to tanh I , with I the dimensionless input, which is exactly the activation of a binary stochastic unit [1,4]. The randomness is also cheap: about 0.03 pJ per bit has been estimated for an easy-plane sMTJ, compared with roughly 30 nJ per bit for pseudorandom generation on CPUs and 3 nJ per bit on GPUs [5]. Statistical test suites for such sources certify the stationary firing probability [5,6]. A stopping rule depends on more than that: it also depends on how much each new read adds to the evidence already collected, and so on the memory between successive reads.
That memory is set by the switching time of the device: an sMTJ sampled more often than it switches tends to repeat its previous state. Daniels et al. showed in simulation that sMTJ bitstreams lose their lag-one autocorrelation only when the clock interval is longer than roughly two mean dwell times, warned that residual autocorrelation can make stochastic-computing results wrong, and slowed the clock to meet this condition in their MNIST network [7]. We call this condition the “ 2 τ rule”. Independence of successive reads is paid for elsewhere too, in clock time or in samples. An instrumented sMTJ system was read 40 times faster than its autocorrelation time and compensated with 40 times as many sweeps to collect an equal count of independent samples [8], which is the sample-count counterpart of the effective-sample-size loss we analyse. Kaiser and Datta describe their samples as “suitably spaced to ensure their independence” [2] without stating the spacing. For sampling machines, timing requirements are known: autonomous Ising machines require synapses that respond faster than the neurons fluctuate [9], in situ Boltzmann learning requires learning to be slower than MTJ fluctuations [10], and asynchronous Gibbs samplers can work with neighbour states that are moderately out of date [11]. In stochastic computing, correlation between bitstreams is a primary design variable [12,13,14]. None of this work asks what breaking the 2 τ rule costs a p-bit (binary stochastic neuron) classifier that stops adaptively, and a bitstream autocorrelation is not by itself a stopping error.
That cost depends on how the network uses its samples. The simplest p-bit classifier averages a fixed number of stochastic passes; averaging more passes, and training through the average, improves accuracy [4], as does drawing more predictions from an MTJ-based Bayesian network [15]. Correlated reads reduce the effective number of samples in such an average [16], but the stationary firing probability of each neuron is untouched, so a fixed-budget classifier may lose little; a companion study of fixed-budget inference on the same simulated network [17] finds that, once each input is given a settle interval of about four correlation times, reads far faster than the 2 τ rule cost little fixed-budget accuracy. The more efficient alternative is compute-adaptive inference: accumulate votes and stop when a stopping rule declares the decision settled, spending passes only on hard inputs. The machinery is mature and comes from several literatures [18,19,20,21,22,23], and nearly every rule in it assumes, explicitly or through its calibration, that the evidence stream is independent and identically distributed (i.i.d.) or exchangeable; the exception, SPRT-TANDEM, learns dependence from video data [23]. A recent p-bit sampling study states the assumption directly when it proposes drawing samples in parallel across separate hardware units, an argument that holds “so long as each sample is independent and identically distributed (i.i.d), which they are for these models” [4]. A physical entropy source read faster than it decorrelates violates this assumption, and a rule that treats dependent votes as independent evidence will stop too early.
Here we quantify that cost by simulation. The hidden units of a p-bit multilayer perceptron are modelled as telegraph-noise sMTJs whose stationary firing probability equals the p-bit activation exactly, for two device classes, and the read interval, measured in correlation times, is swept as a design variable. A specification of the stationary firing probability, which is what random-bit test suites certify, says nothing about the guarantees of a computation that stops adaptively. Adaptive stopping rules lose their calibrated error level in the regime where fixed-budget accuracy is intact, and top-line accuracy does not show it, because the failure concentrates on a small, identifiable stratum of hard inputs. That matters for any use that relies on the stopping level itself, such as abstaining on uncertain inputs or budgeting passes per decision. The failure is a loss of effective sample size, and it can be corrected in the stopping statistic rather than by slowing the clock: a Markov-chain likelihood, calibrated once per operating point from unlabelled, reference-masked reads, keeps error within the configured level down to a measured floor of one correlation time. It reduces rather than removes the excess over ideal randomness: at half the correlation time its error ratio is clearly above unity, and at one correlation time a residual excess of about 1.3-fold (1.4 once reference noise is removed) remains, which per-seed normalisation alone does not separate from unity.
Two studies are the direct baselines. Daniels et al. [7] set the read interval from bitstream autocorrelation and repair fast reads by throttling the clock; here, for adaptive inference, repairing the stopping rule gives 1.3–1.4 times the throughput of throttling (with and without the settle interval). At one correlation time the naive Wald rule is already compliant in 13 of 15 replicate cells; the correction makes all 15 compliant, and at half the correlation time it is compliant in 60%. Ghantasala et al. [4] analyse p-bit sample counts for i.i.d. samples; relaxing that assumption, i.i.d. stopping rules exceed their ideal-randomness error three- to fourfold at half the correlation time.
Section 2 describes the device model, network, stopping rules and error quantities; Section 3 reports the degradation, its mechanism and the repair; Section 4 discusses scope and limitations; and Section 5 concludes.

2. Materials and Methods

2.1. Device Model

The device and network models are shared with the companion fixed-budget study [17], which describes them in full; we summarise only what the stopping analysis uses. A hidden unit is a two-state fluctuator, s ∈ { − 1 , + 1 } , that jumps up at rate k − → + = f e + I and down at rate k + → − = f e − I . Here I is its dimensionless synaptic input, and the attempt rate f = f 0 e − δ Δ carries a per-device barrier offset δ Δ in units of k B T . Detailed balance gives
P ( s = + 1 ) = k − → + k − → + + k + → − = 1 + tanh I 2 ≡ p ,
the p-bit activation [1], and the state decorrelates with time constant τ corr ( I ) = 1 / ( 2 f cosh I ) . The read rate therefore shapes only how successive draws are correlated; the firing probability does not depend on it. Read intervals are quoted as r 0 = Δ t / τ corr ( 0 ) . Because the mean dwell time at zero bias is 1 / f = 2 τ corr ( 0 ) , the 2 τ rule [7] corresponds to r 0 ≥ 4 , and r 0 < 4 means reading faster than it allows. The input is held fixed between reads (sample-and-hold between clocked layers), so each read is drawn from the exact propagator of the two-state chain
P ( s t + Δ t = + 1 ∣ s t ) = p + 1 [ s t = + 1 ] − p e − Δ t / τ corr ,
with no discretization error at any r 0 . In the Arrhenius class Δ t / τ corr = r 0 e − δ Δ cosh I , so neurons driven hard decorrelate sooner. The bias-independent-rate class, which follows models of easy-plane devices [5,24], keeps the total rate at 2 f , giving Δ t / τ corr = r 0 e − δ Δ with an unchanged stationary law. A capped Arrhenius class limits the total rate, k tot = min ( 2 f 0 cosh I , 1 / τ 0 ) , and is evaluated at the worst corner τ corr ( 0 ) / τ 0 = 2 , since an unbounded attempt frequency would let bias-driven self-decorrelation grow without limit. Chip-to-chip variability enters as a barrier offset δ Δ ∼ N ( μ , σ Δ 2 ) with μ = − σ Δ 2 / 2 ; this centring holds the mean correlation time fixed and leaves the firing probability untouched, so variability acts on timing alone rather than as static sigmoid distortion [25,26,27]. The control is an ideal i.i.d. source, r 0 = ∞ . Unit tests verify the stationary distribution, the autocorrelation decay with and without bias, the settle relaxation and every device variant against these expressions.

2.2. Operating Modes

Settle mode is the primary mode. After an input is applied, the devices evolve from whatever state they were in for κ τ corr ( 0 ) before the first read; starting from idle, the first read then carries a residual bias of − 1 2 tanh ( I ) exp [ − κ τ corr ( 0 ) / τ corr ( I ) ] , that is − 1 2 tanh ( I ) e − κ cosh I for the Arrhenius class and − 1 2 tanh ( I ) e − κ for the bias-independent-rate class (at δ Δ = 0 ). We take κ = 4 and test κ ∈ { 2 , 8 } (Section 3.5). Streaming mode has no idle period: the first read of a new input sees the device states produced by the previous input. Below r 0 ≈ 1 zero-settle streaming is an idealization, reported only as a bracket. Figure 1 summarizes the pipeline.

2.3. Network, Training and Datasets

The classifier is a fully connected 784–256–128–10 network with real-valued input and readout layers and two stochastic bipolar hidden layers. As in p-bit operation, the hidden layers are resampled on every pass, inference included, unlike the deterministic test-time mode of binarized networks [28,29]. Training uses ideal randomness, a straight-through estimator [30] and Adam for 30 epochs (learning rate 10 − 3 , cosine schedule). A pass produces one vote, the arg-max of the readout. MNIST [31] is the primary dataset and Fashion-MNIST [32] the replication. Every tuning and selection decision uses a validation split made of the final 5000 training images; test images are used for reported numbers alone.

2.4. Stopping Rules

All rules read the same running per-class vote counts. The Dirichlet rule is Adaptive-Consistency’s plurality-stability rule at 1 − α , using its released top-two Beta simplification [18]; it is the rule deployed in practice, and its level is a posterior credibility.
The Wald rule is a leader-oriented binary sequential probability ratio test (SPRT) [33,34] on the sub-stream of votes for the current top two classes ( a , b ) : a vote for the leader a is a success, a vote for b a failure, votes for other classes are dropped, and the sub-stream is rebuilt from the stored votes whenever the top-two pair changes. It tests p 0 = 0.5 against p 1 = 0.75 with α = β = 0.05 and stops, deciding a, only when the log-likelihood ratio crosses log A , A = ( 1 − β ) / α . Wald’s lower threshold B = β / ( 1 − α ) is not used, because accepting H 0 would name no class; a lane that never crosses log A runs to t max and takes the plurality (the truncated channel below). For a fixed pair that contains the reference class and i.i.d. votes, a wrong decision requires the other class, whose pairwise share is at most p 0 , to cross log A , which by Ville’s inequality [35] has probability at most 1 / A = α / ( 1 − β ) ; because the pair is selected from the same data, this bound is heuristic. Reducing the ten-class decision to a binary test on the top two classes keeps Wald’s error bounds explicit and gives the Markov correction a single indicator to act on; the multihypothesis SPRT [36] is the asymptotically optimal alternative and would need its own dependence correction.
The Markov SPRT keeps this decision structure and threshold and replaces the product of per-vote likelihoods with the joint likelihood of a stationary two-state chain on the same indicator [37,38], with P ( z = 1 ) = p 0 under H 0 and p 1 under H 1 and a common, fixed lag-one autocorrelation ρ that must lie in the admissible range for both p 0 and p 1 ( ρ is measured on a full-stream plurality indicator, not on this top-two sub-stream; Section 2.7); the likelihood is the initial-state probability times the transition probabilities raised to the transition counts. If the vote indicator were the fitted chain, the likelihood ratio would be a martingale under H 0 ( P ( z = 1 ) = p 0 ) and Wald’s argument would apply there through the Markov property and Ville’s inequality [35,37,38,39]; whether this extends to every pairwise share below p 0 with a shared ρ , as it does for i.i.d. Bernoulli votes, is not proven here. In practice the indicator is defined against data-dependent top-two classes, ρ is plugged in from a separate split and from a different indicator (Section 2.7), and the stream is not exactly first order, so validity is checked empirically rather than guaranteed. The rule is run with ρ calibrated once per operating point (Section 2.7) or, as an ablation, re-estimated online per input. We correct the likelihood itself rather than rescaling the pass count to an effective sample size N ( 1 − ρ ) / ( 1 + ρ ) , because no theorem licenses substituting such a rescaled count into an SPRT boundary, whereas a likelihood ratio of the joint law retains the martingale structure that Wald’s argument uses.
The e-process rule [40,41] runs, for each class k, a betting capital process on the indicator x t = 1 [ vote t = k ] against the null H 0 , k that the class-k vote rate is at most 1 2 ,
M t = 1 L ∑ l = 1 L ∏ s ≤ t 1 + λ l x s − 1 2 ,
a uniform mixture over L = 20 bets λ l evenly spaced on [ 0.05 , 1.9 ] , inside ( 0 , 2 ) so that every factor is nonnegative. It decides class k the first time M t ≥ ( K − 1 ) / α , a Bonferroni split of α over the K − 1 wrong classes. By Ville’s inequality the probability of a wrong decision is then at most α whenever E [ x t ∣ x 1 , … , x t − 1 ] ≤ 1 2 under H 0 , k , a conditional-mean (martingale-difference) condition weaker than i.i.d.; positively autocorrelated votes can break it, because after a vote for k the conditional rate exceeds the stationary one. The per-class processes use the full vote stream rather than a data-dependent top-two sub-stream, which preserves the supermartingale property at the price of conservatism.
A fixed-N ladder, N ∈ { 1 , 2 , 4 , … , 256 } , is the reference frontier. All rules use α = β = 0.05 , t min = 4 and t max = 256 ; decisions reaching t max are truncated and reported as a separate error channel, because truncation is a budget effect present under ideal randomness too. Plurality ties are broken uniformly at random from a seeded per-lane stream.

2.5. Experimental Grid and Replay Protocol

The adaptive grid swept r 0 ∈ { ∞ , 4 , 2 , 1 , 0.5 , 0.25 } over four arms (Arrhenius and bias-independent devices, each in settle and streaming mode) plus the capped class at r 0 ≤ 1 , with dwell-time dispersion σ Δ ∈ { 0.5 , 1.0 } under mean- τ corr centring over three chip seeds as a separate column. The primary arm is the bias-independent-rate class in settle mode, whose vote correlation is the stronger. Sensitivity to t min ∈ { 2 , 8 } and to a settle of 2 or 8 correlation times was run on the primary arm.
A lane that stops early stops reading, but its devices remain driven by the same input, and a batched source cannot mask one lane without altering the others’ draws. All lanes are therefore sampled for the full t max , only reads are charged, and every rule is replayed offline against the same recorded vote stream within a cell, so rule comparisons are paired. The test set is divided into 100 sequential lanes.

2.6. Reference Decision, Error Quantities and Marginal Stratum

Stopping error is P ( adaptive decision ≠ reference decision ) ; task accuracy is scored against the label. The reference uses two independent 1024-pass ideal-randomness blocks per dataset and training seed: block A’s vote margin (top-class count minus runner-up count, as a fraction of 1024) defines the stratum, and block B’s majority is the decision scored against, so that stratum membership and scoring target do not share a noise term. The blocks disagree on 0.09% of MNIST test inputs and 1.20% of the marginal stratum. Block-B ties are excluded, so the scored denominator is 9999 or 10,000 images.
The marginal stratum is the set of inputs with block-A reference margin below 0.9: 7.8% of the MNIST test set and 21.4% of Fashion-MNIST. The stratum, its cut and the stopping-error convention were fixed in the version history before the reported grid was run (an earlier grid under a single-block reference was superseded by the split-sample convention before the reported grid; the 0.9 cut was set on the validation pre-check). Sensitivity to cuts of 0.8 and 0.95 and to the sub-stratum with reference top-class vote share q ≥ 0.75 is computed from stored per-input arrays without additional runs.
Different rules have different nominal levels, so our primary quantity is each rule’s stopping error divided by that same rule’s error under ideal randomness (the calibration-referenced ratio). We also report error against each rule’s nominal level, meaning the level it is configured for ( α , or α / ( 1 − β ) for the SPRTs), read as an error rate against the ideal-randomness decision. That reading is operational, not the frequentist guarantee of each rule: Wald’s bound assumes i.i.d. votes and is heuristic because the top-two pair is chosen from the data (Section 2.4), and the Dirichlet level is a posterior credibility. The calibration-referenced ratio needs neither reading. A compliance filter marks each operating point by the fraction of replicate cells whose marginal-stratum error has a Wilson 95% upper bound at or below α .

2.7. Chain Parameter

The Markov SPRT needs one number per operating point, ρ . For each selected input whose votes fluctuate, we compute the lag-one autocorrelation of the full-stream indicator x t = 1 [ vote t = c ★ ] , where c ★ is that input’s plurality class over all t max passes, so every pass enters and votes for other classes count as 0; ρ is the mean of these values over the selected inputs. The Markov SPRT applies it, as a plug-in, to the top-two sub-stream indicator of Section 2.4 (leader 1, runner-up 0, other classes dropped, rebuilt when the pair changes), which is a different process, so ρ is a proxy for that stream’s autocorrelation. It is measured on the first 2000 validation images, using no labels, once per device class, mode, r 0 , σ Δ , chip seed and settle interval, on training seed 0 only, and transferred unchanged to the other models and to test (Table A1). The headline calibration averages over marginal-stratum inputs whose votes fluctuate; a chip-measurable variant averages over all inputs whose votes fluctuate, needing no reference and no labels, and is smaller (on test, 0.177 against 0.272 at r 0 = 1 and 0.342 against 0.451 at r 0 = 0.5 ). Mechanism diagnostics, taken over marginal-stratum inputs whose votes fluctuate, report autocorrelation to lag 48, the integrated inflation factor against its first-order prediction, and the entropy rate of the fitted chain.

2.8. Cost Proxy

Fixed before any adaptive experiment, the cost per decision counts random bits and multiply-accumulates,
bits = ( passes ) × ( stochastic hidden units ) , MACs = ( passes ) × ∑ l d l d l + 1 .
Throttling lengthens the read interval without changing the draws, so it is reported only in latency-equivalent pass slots,
( passes ) × r 0 throttled / r 0 operating .
In settle mode each decision additionally waits 4 / r 0 operating-clock pass slots before its first read, and throughput ratios are given with and without that overhead. We make no energy claim for sample counts; per-bit energy figures are quoted from the literature for context only.

2.9. Statistics and Reproducibility

Five noise seeds run at r 0 ∈ { ∞ , 1 , 0.5 } and two elsewhere, over three training seeds on the primary arm, giving 15 and 6 cells respectively. Ratios are reported with cluster-robust intervals over the three training seeds (per-cell values averaged within a seed; Student’s t with two degrees of freedom on the three seed means). Absolute errors and the ideal-randomness denominators are reported as min–max ranges over cells. Calibration-referenced ratios divide every cell by one ideal-randomness error per rule, the mean of all 15 ideal cells pooled across training seeds, which is then held fixed, so their intervals exclude the uncertainty of that denominator; relative to its mean, the denominator’s own cluster-robust interval is 1.00 [0.72–1.28] for Wald and the Markov SPRT and 1.00 [0.78–1.22] for the Dirichlet rule and the e-process. Ratios to the ideal fixed-budget frontier likewise use a pooled reference. As a check, dividing each cell by its own training seed’s ideal mean moves no calibration-referenced point estimate by more than 0.07 and changes the intervals, widening most of them: the naive Wald and Dirichlet excesses at r 0 ≤ 1 still exclude unity (for example, Wald 1.63 [1.30–1.96] at r 0 = 1 ), whereas the Markov SPRT at r 0 = 1 , 1.30 [0.96–1.64], does not. Where only one training seed exists, bands are min–max and labelled so. Compliance uses Wilson 95% intervals per cell, never pooled. All intervals are two-sided at the 95% level. No hypothesis tests or P values are reported; comparisons rest on these intervals and on the stated replicate counts.
Simulations were written in Python with PyTorch 2.13.0 and NumPy 2.4.6. Every result cell is stamped with a content hash of the simulator sources; cells are reused only at the current hash or at an earlier hash documented in the driver as unable to change any stored number. All code, result records and figure pipelines are public at https://github.com/mnn31/adaptive-pbit (see the Data Availability Statement). Use of generative AI tools in this study is described in the Acknowledgments.

3. Results

3.1. Adaptive Stopping Rules Lose Their Error Level Under Autocorrelated Votes

Under ideal randomness the marginal-stratum stopping error is 0.0183 [0.0103–0.0243; min–max over 15 cells] for Wald, 0.0174 [0.0090–0.0217] for the e-process and 0.0278 [0.0183–0.0345] for the Dirichlet rule. As the read rate rises, the naive rules leave that calibration together (Figure 2a). Wald’s error is 1.02 [0.56–1.48] times its ideal value at r 0 = 4 and 1.05 [0.93–1.16] at r 0 = 2 , then 1.62 [1.39–1.86] at r 0 = 1 , 3.18 [2.18–4.19] at r 0 = 0.5 and 5.66 [4.69–6.63] at r 0 = 0.25 . The Dirichlet rule traces the same curve from an unrelated construction: 1.10, 1.36, 2.35, 4.07 and 6.03 [5.59–6.47]. The two rules are built differently and have only the vote stream in common, so the agreement of 5.66 and 6.03 points to the stream as the cause.
Against each rule’s own nominal scale (Figure 2b), and counting a rule as exceeding its bound when the interval on its mean ratio excludes unity, Wald exceeds its bound only at r 0 = 0.25 (1.97 [1.63–2.31]; at r 0 = 0.5 the mean ratio is 1.11 [0.76–1.46], although 0 of 15 cells there pass the stricter per-cell compliance filter of Section 3.4), the Dirichlet rule crosses its credibility level at r 0 = 1 (1.30 [1.11–1.50]) and reaches 3.35 [3.10–3.59], and the e-process survives further (0.75 [0.55–0.94] at r 0 = 0.5 ) before exceeding its Ville bound at r 0 = 0.25 (1.32 [1.09–1.56]), as expected once positive autocorrelation breaks its martingale-difference condition. Within the stratum, the naive Wald rule’s error concentrates on the lowest-margin inputs (Section 3.5). The Markov SPRT stays at or below its own bound on average at every ratio measured, 0.77 [0.55–0.99] at r 0 = 0.25 (per-cell compliance is lower below one correlation time; see Section 3.4). These are statements about the mean over replicate cells; the compliance filter used in Section 3.4 is stricter, requiring each cell’s Wilson upper bound to sit at or below α . Intervals are cluster-robust over three training seeds (Section 2.9).
Spending fewer passes does not explain the increase. Dividing each rule’s error by the ideal fixed-budget error interpolated at that rule’s own marginal-stratum mean budget (Figure A1), every rule sits well inside the frontier under ideal randomness (0.50 [0.35–0.64] for Wald and 0.47 [0.37–0.58] for the Dirichlet rule). That is about half the error of a fixed budget of the same size, which is the point of adaptivity. With correlated reads that advantage disappears: at r 0 = 0.25 both rules end up worse than the frontier, 1.59 [1.33–1.85] and 1.56 [1.45–1.66].

3.2. Top-Line Accuracy Does Not Reveal the Failure

Accuracy monitoring does not reveal this. Under ideal randomness the four peer rules reach the same whole-test-set accuracy, 0.9786, at budgets from 5.4 passes (Dirichlet) to 16.4 (e-process). At r 0 = 0.5 they still land there: 0.9766 at 4.4 passes for the Dirichlet rule, 0.9781 at 9.4 for Wald and 0.9786 at 20.2 for the Markov SPRT (Figure 3). Between ideal randomness and r 0 = 0.5 , whole-test-set accuracy moves by at most two tenths of a point, while the naive rules’ marginal-stratum stopping level moves three- to fourfold. Fixed-budget accuracy is equally robust on this device class: at N = 32 it is 0.9788 under ideal randomness and 0.9784 at r 0 = 0.5 (grey ladders in Figure 3). On the marginal stratum, task accuracy scored against the true labels is not intact. It falls by about three points at r 0 = 0.5 and five at r 0 = 0.25 (one cell) at small budgets, but it is flat at N = 64 (Figure 2c), consistent with a stationary law that correlation does not change. The stopping level therefore degrades three- to fourfold while stratum accuracy at small budgets falls by about three points and is flat at N = 64 .
Almost all of the error sits in the marginal stratum. On the primary arm (bias-independent-rate devices in settle mode), whole-test-set stopping error stays below 0.3 α in every cell at every sampling ratio, the largest mean being 0.27 [0.25–0.30, cluster-robust] times α (Dirichlet, r 0 = 0.25 ); yet the degradation factor is not diluted: at r 0 = 0.25 it is 6.36 [5.84–6.88] for the Dirichlet rule and 5.72 [4.87–6.57] for Wald over the whole test set, matching the stratum. The marginal stratum carries 94.8% [92.6–97.1] of the Dirichlet rule’s absolute error mass there and 99.0% of Wald’s. Because these inputs are 7.8% of the test set, top-line accuracy barely registers the failure.

3.3. The Failure Is Lost Effective Sample Size

The lag-one autocorrelation of the vote indicator, over marginal-stratum inputs whose votes fluctuate, is − 0.004 under ideal randomness, 0.009 at r 0 = 4 , 0.096 at r 0 = 2 , 0.272 at r 0 = 1 , 0.451 at r 0 = 0.5 and 0.592 at r 0 = 0.25 , and decays over a few lags (Figure 4a); over all inputs whose votes fluctuate, the quantity a chip could measure, it is smaller, 0.177 at r 0 = 1 and 0.342 at r 0 = 0.5 . The diagnostics below are likewise marginal-stratum values. The device class moves it far less than the sampling ratio does: at r 0 = 0.5 it spans 0.377 (Arrhenius, settle) to 0.499 (bias-independent, streaming), as expected when the vote is decided by units near threshold, where the rate’s bias dependence matters least (Figure 4b).
Autocorrelation inflates the variance of the vote sum. The integrated inflation factor of the vote sum reaches 1.856 at r 0 = 1 , 3.231 at r 0 = 0.5 and 5.696 at r 0 = 0.25 : a rule calibrated for independent draws reads an effective sample size two to six times smaller than its pass count (Figure 4c). The first-order prediction ( 1 + ρ ) / ( 1 − ρ ) from the lag-one value ρ tracks this at first and then falls behind; the ratio of the two is 1.004 at r 0 = 2 , 1.063 at r 0 = 1 , 1.222 at r 0 = 0.5 and 1.460 at r 0 = 0.25 . In information terms, the entropy rate of the fitted two-state vote chain falls short of the i.i.d. entropy of the same marginal by 0.0030 bits per pass under ideal randomness, 0.1263 at r 0 = 0.5 and 0.2082 at r 0 = 0.25 , roughly a third of that marginal’s 0.5876 bits. An i.i.d. rule counts this predictable part of the stream as evidence, and so it stops early.

3.4. Repairing the Stopping Rule Instead of the Clock

Comparing costs requires a compliance filter, since a rule that stops too early also looks cheap (Figure 5, Table 1). The naive Dirichlet rule spends only 4.7 passes per decision at r 0 = 1 and no cell there passes. Naive Wald holds every cell only down to r 0 = 2 . The Markov SPRT, with its chain parameter measured once per operating point on unlabelled validation reads of the reference-defined marginal stratum (a chip-measurable variant, checked below, keeps all 6 of 6 cells compliant at r 0 = 1 at 12.7 passes), keeps every cell compliant down to r 0 = 1 , one correlation time and a quarter of the 2 τ prescription, at 15.1 [14.6–15.5] passes; below that its compliance is partial, 60% of cells at r 0 = 0.5 and 33% at r 0 = 0.25 . At r 0 = 1 naive Wald is itself compliant in 87% of cells (13 of 15) at 10.2 passes, so there the correction buys full compliance for about half again as many passes. A naive Wald rule with α tightened per operating point might also reach full compliance there, possibly for fewer passes; that alternative was not evaluated (Section 4).
Compliance is judged against the nominal level; on the calibration-referenced scale the correction reduces the excess. Its error is 1.29 [1.21–1.37] times its ideal-randomness value at r 0 = 1 and 1.76 [1.28–2.23] at r 0 = 0.5 (Figure 2a), against 1.62 and 3.18 for naive Wald, and the e-process sits at 1.33 [1.25–1.41] at r 0 = 1 . These intervals hold the pooled ideal-randomness error fixed (Section 2.9). Normalising each training seed by its own ideal error changes these point estimates by at most 0.01 and changes the intervals to [0.96–1.64] at r 0 = 1 (wider) and [1.40–2.12] at r 0 = 0.5 (narrower) for the correction, and to [1.13–1.54] at r 0 = 1 for the e-process. The correction keeps error within the configured level; at half the correlation time its error stays clearly above the ideal-randomness value, and at one correlation time a residual excess of about 1.3 (1.43 [1.24–1.62] once reference noise is removed; see Section 4) remains, which per-seed normalisation alone does not separate from unity.
The e-process reaches the same floor at the same cost, 15.0 [14.7–15.4] passes, and needs no device measurement. The two separate on either side of the floor. Above it the correction is cheaper (11.3 against 16.3 passes at r 0 = 4 ), because a correction handed a near-zero ρ costs almost nothing, whereas a Ville bound pays its conservatism everywhere. Below it the correction degrades gradually, whereas the e-process loses compliance abruptly: 60% of cells against 27% at r 0 = 0.5 , and 33% against none at r 0 = 0.25 . A deployment that cannot measure ρ should use the e-process; one that can gains margin on both sides of the floor.
Against the standard remedy, throttling the naive Dirichlet rule back to the compliant r 0 = 4 (where it is itself compliant in only 83% of cells), the comparison is quoted where the correction is fully compliant, r 0 = 1 . Throttled, the Dirichlet rule costs 21.4 latency-equivalent pass slots, against 15.1 for the correction: 1.4 × the throughput, or 1.3 × when both sides are charged the settle interval. Throttling the Wald rule instead to r 0 = 2 , where it is fully compliant, would cost 21.6 slots (44.8 at r 0 = 4 ), so the Dirichlet baseline is the conservative choice. In random bits the sign reverses: the correction draws 2.8 × as many, because throttling spreads the same number of draws over more time. One comparison needs no throttling model at all: at r 0 = 1 the correction reaches a marginal-stratum stopping error of 0.0236 with a marginal-stratum mean budget of 50.9 passes, an error the ideal fixed-budget frontier reaches only near N = 144 , about 2.8 times that budget.
We ran two further checks relevant to deployment. The chain parameter above is averaged over the marginal stratum, which a deployed chip cannot identify. Measured instead over all fluctuating inputs, with no reference and no labels, it is smaller and gives a weaker correction, yet all six replicate cells at r 0 = 1 remain compliant, at 12.7 [12.1–13.3] passes. At r 0 = 0.5 this chip-measurable version keeps 2 of 6 cells compliant, the expected direction below the floor. Re-estimating the parameter online per input, by contrast, is degenerate: it truncates 80% of test inputs even under ideal randomness and behaves like fixed-budget inference at the maximum budget (Figure A2a). One-off calibration per operating point is therefore the deployment recommendation.

3.5. Replication and Robustness

On Fashion-MNIST, with one training seed, the naive rules degrade comparably (Figure A3): Wald reaches 3.51 [3.25–3.85; min–max over cells] times its ideal-randomness error at r 0 = 0.5 and 6.25 [6.18–6.31] at r 0 = 0.25 , and the Dirichlet rule 4.08 [3.88–4.24] and 5.60 [5.57–5.63], while the corrected rule stays lowest, at 1.88 and 2.71. Neither the minimum pass count t min ∈ { 2 , 4 , 8 } nor the settle interval (2, 4 or 8 correlation times) moves the degradation curve (Figure A2b,c), nor does dwell-time dispersion under mean- τ corr centring (Figure A4a). Capping the Arrhenius attempt frequency at the worst corner removes the bias-driven self-decorrelation of that class and raises its marginal-stratum lag-one vote autocorrelation at r 0 = 0.5 from 0.377 to 0.390, still below the bias-independent class’s 0.451 (Figure A4b). Recomputing the headline at stratum cuts of 0.8, 0.9 and 0.95 moves the absolute errors but leaves the calibration-referenced ratios nearly unchanged, within about 5% (3.15, 3.18 and 3.18 for Wald at r 0 = 0.5 ; Table A2). Finally, on inputs whose reference top-class share is at least 0.75, realized error at r 0 = 0.5 is 0.0057 for Wald and 0.0000 for the corrected rule, so the excess concentrates on the lowest-margin inputs of the stratum. That error still matters for deployment: low-margin inputs are exactly the ones on which a deployed classifier would abstain or spend extra passes, and under ideal randomness the same rules hold that error at their calibrated value, so the increase is caused by the entropy source, not by the rules’ design.

4. Discussion

A throughput-driven design would move to fast reads because fixed-budget accuracy is nearly unaffected there (on this grid, at N = 32 it changes from 0.9788 to 0.9784 at r 0 = 0.5 ), and in that range i.i.d. stopping rules no longer hold their calibrated error level. Whole-test-set accuracy moves by tenths of a point while the stopping level on hard inputs degrades several-fold. A fixed-budget accuracy specification therefore does not protect an adaptive one, and a design that combines p-bit entropy with early termination needs a dependence-aware rule or a throttled clock. Of the two remedies compared here, repairing the rule and throttling the clock, we recommend the former; the comparison is against throttling only and does not show that the correction is the cheapest possible repair. At one correlation time the Markov-chain correction keeps error within the configured level and gives 1.3 – 1.4 × the throughput of throttling in latency-equivalent pass slots (with and without the settle interval) at 2.8 × the random bits, while its error stays above the ideal-randomness value at half the correlation time, and a residual excess of about 1.3 (1.4 once reference noise is removed) remains at one correlation time, which per-seed normalisation alone does not separate from unity; throttling remains preferable where random-bit generation rather than latency binds. The correction is not the only repair, since an e-process reaches the same floor without measuring anything, but it is cheaper above the floor and degrades more gracefully below it; a naive rule recalibrated per operating point is a further candidate that we did not evaluate (see Limitations). The correction uses standard sequential analysis, in which Wald’s threshold remains valid under H 0 , for the fitted chain and a fixed pair (Section 2.4), once the independence product is replaced by the true joint likelihood [33,37,38,39,42]. What is new here is the measurement: how large the failure is on physical p-bit entropy, where it concentrates, what the correction costs against throttling, where it stops working, and a diagnostic, computable from unlabelled, reference-masked reads, that orders operating points by how far they are from that floor.
A third remedy acts at the source. A recent sMTJ generator suppresses short-term correlation with an on-FPGA XOR operation on the bitstream [43]. That works for a random-number generator, whose bit carries only entropy, but not for a p-bit, whose bit is the neuron state and must average to tanh I . For two reads at bias I with lag-one correlation ρ the XOR has mean 1 2 ( 1 − ρ ) sech 2 I , which is even in I: whitening discards the sign that carries the activation. For p-bits the correction therefore has to be made in the stopping statistic, after the votes are formed.
Dependence-aware sequential testing has been applied elsewhere in machine learning. SPRT-TANDEM relaxes the i.i.d. assumption by learning a high-order density ratio over dependent video frames [23,44]; its dependence comes from the data, not from a physical entropy source. Early-exit networks have been given anytime-valid confidence sequences whose dependence runs across network depth [45,46], and there the random draws come from a software generator and are i.i.d. by construction. In stochastic computing, progressive-precision and runtime early termination stop on operand precision or a convergence or stability metric [22,47,48,49], as does bitwise early termination in hyperdimensional computing [50], with no error-controlled accumulating statistic and no temporal-autocorrelation axis, and the closest randomness-source study finds that low-discrepancy generators improve early termination [51], a favourable effect of spatial quality, where ours is an adverse effect of temporal memory. Sharing stochastic hardware across neurons [52] concerns how many entropy sources a network needs; our axis, how fast one source may be read, is orthogonal to it.
The correction has a validity floor at one correlation time, and it co-varies with a diagnostic computable beforehand from unlabelled, reference-masked reads: the ratio of the true variance inflation factor to its first-order value grows as compliance falls away (marginal-stratum values 1.063, 1.222 and 1.460 at r 0 = 1 , 0.5 and 0.25). No threshold on it was pre-specified, so it can rank operating points but cannot locate the floor. Below the floor the vote stream is not adequately first-order, and the corrected rule’s residual error sits mostly in the truncated channel (0.0228 truncated against 0.0094 fired at r 0 = 0.5 ; Figure 4d), so holding the level there requires a larger pass budget, not a better ρ . The compliance it achieves is averaged over the stratum and rests on a fitted model; it is not a per-input guarantee.
Limitations. Our device model is an idealized two-state telegraph process without read disturb, retention drift or 1 / f noise; we cover one architecture and two small datasets, with one training seed on the Fashion-MNIST replication; and within a cell all stopping rules are replayed against one recorded vote stream, so rule comparisons are paired. The cost comparison uses throttling as its only baseline: a naive rule with α retuned per operating point, or with its log-likelihood ratio scaled by an effective-sample-size factor ( 1 − ρ ) / ( 1 + ρ ) , was not evaluated; either is an alternative remedy that would need the same per-operating-point calibration as the correction, and either might reach compliance at r 0 = 1 for fewer passes. The reference decision’s residual noise attenuates the calibration-referenced ratios toward unity, so the reported factors are conservative: on inputs where the two reference blocks agree, the factors at r 0 = 0.25 are 8.25 (Wald) and 7.63 (Dirichlet), and the corrected rule’s are 1.43 [1.24–1.62] at r 0 = 1 and 2.13 [1.35–2.90] at r 0 = 0.5 (1.50 [1.23–1.77] for the e-process at r 0 = 1 ), so the repair’s residual excess is also larger than reported. The hardware test is direct: record vote streams from a fabricated array such as the instrumented system of Singh et al. [8] at several read intervals, measure ρ on unlabelled inputs, and check whether the naive and corrected rules’ calibration-referenced ratios follow Figure 2a. Real devices add effects our model omits; 1 / f noise in particular adds correlation beyond first order, which a first-order chain cannot capture and which the inflation-ratio diagnostic above should register. Convolutional networks and correlated input streams such as video are the natural next tests.

5. Conclusions

In a simulated p-bit classifier with telegraph-noise sMTJ neurons, reading the devices faster than about one correlation time leaves whole-test accuracy and fixed-budget accuracy nearly unchanged but breaks adaptive stopping rules that treat votes as independent: at half the correlation time, the Wald and Adaptive-Consistency rules’ stopping error on low-margin inputs rises three- to fourfold above its ideal-randomness value. The cause is lost effective sample size. A Markov-chain likelihood calibrated once per operating point from unlabelled, reference-masked reads keeps error within the configured level down to one correlation time, reducing but not removing the excess, at 1.3–1.4 times the throughput of throttling the clock, and an e-process reaches the same floor without device measurement. Below one correlation time the correction’s compliance is partial and the e-process loses compliance abruptly, and per-input online re-estimation of the correlation is degenerate. Designs that pair p-bit entropy with early termination should therefore specify the read interval relative to the correlation time and either use a dependence-aware stopping statistic, calibrated per operating point, or throttle the clock; other per-operating-point recalibrations of naive rules were not compared here.

Author Contributions

Conceptualization, M.G.; methodology, M.G.; software, M.G.; validation, M.G.; formal analysis, M.G.; investigation, M.G.; data curation, M.G.; writing—original draft preparation, M.G.; writing—review and editing, M.G.; visualization, M.G. The author has read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Institutional Review Board Statement

Not applicable.

Data Availability Statement

The original data presented in the study are openly available in the GitHub repository at https://github.com/mnn31/adaptive-pbit: the adaptive-inference result records supporting every reported number are in results/grid2/, and the simulation code, experiment drivers, tests and figure pipelines are in the same repository (the fixed-budget records of the companion study are in fixed_budget/). MNIST and Fashion-MNIST are publicly available.

Acknowledgments

Claude (Anthropic) was used, under the author’s direction, to assist with repetitive and boilerplate portions of the code (including the scripts that generate the figures and tables), debugging, and drafting and revising manuscript text in all sections, from the Abstract to the Conclusion. The author formulated the research questions, designed the study, selected the methods and specific implementation approaches, and directed the organization of the code and files in the GitHub repository. The author retained control over all scientific and implementation decisions, reviewed and validated the code and results, and determined the interpretation and conclusions. The author reviewed and approved the final manuscript and takes full responsibility for the research questions, methodology, code, analyses, findings, and all content of this work.

Conflicts of Interest

The author declares no conflicts of interest.

Abbreviations

The following abbreviations are used in this manuscript:
i.i.d. Independent and identically distributed
MAC Multiply-accumulate
MLP Multilayer perceptron
MTJ Magnetic tunnel junction
p-bit Probabilistic bit
sMTJ Stochastic magnetic tunnel junction
SPRT Sequential probability ratio test

Appendix A. Ablations, Replication and Sensitivity

Figure A1. Excess at matched budget. Each rule’s marginal-stratum stopping error divided by the ideal-randomness fixed-N error, interpolated log-linearly at that rule’s own marginal-stratum mean budget. Unity means no worse than ideal randomness at the same number of passes. Cluster-robust intervals over three training seeds; n = 15 cells at r 0 = ∞ , 1 and 0.5 and n = 6 elsewhere.
Figure A1. Excess at matched budget. Each rule’s marginal-stratum stopping error divided by the ideal-randomness fixed-N error, interpolated log-linearly at that rule’s own marginal-stratum mean budget. Unity means no worse than ideal randomness at the same number of passes. Cluster-robust intervals over three training seeds; n = 15 cells at r 0 = ∞ , 1 and 0.5 and n = 6 elsewhere.
Preprints 237540 g0a1
Figure A2. Rule and protocol ablations, bias-independent-rate devices in settle mode. (a) The per-input online- ρ estimator, a degenerate ablation: calibration-referenced error as in Figure 2a, with marker area encoding truncation, which reaches 80–89% of all test inputs at every r 0 . (b) Minimum pass count t min ∈ { 2 , 4 , 8 } . (c) Settle interval of 2, 4 or 8 correlation times. In (b) and (c) colour is the knob value, solid lines the Dirichlet rule and dashed lines the Wald SPRT; vertical axes are as labelled in each panel.
Figure A2. Rule and protocol ablations, bias-independent-rate devices in settle mode. (a) The per-input online- ρ estimator, a degenerate ablation: calibration-referenced error as in Figure 2a, with marker area encoding truncation, which reaches 80–89% of all test inputs at every r 0 . (b) Minimum pass count t min ∈ { 2 , 4 , 8 } . (c) Settle interval of 2, 4 or 8 correlation times. In (b) and (c) colour is the knob value, solid lines the Dirichlet rule and dashed lines the Wald SPRT; vertical axes are as labelled in each panel.
Preprints 237540 g0a2
Figure A3. Fashion-MNIST replication of Figure 2a under the same calibration-referenced normalization. One training seed, so the band is min–max across noise-seed cells (three at r 0 = ∞ , 1 and 0.5; two at 4, 2 and 0.25) and no cluster-robust interval is claimed.
Figure A3. Fashion-MNIST replication of Figure 2a under the same calibration-referenced normalization. One training seed, so the band is min–max across noise-seed cells (three at r 0 = ∞ , 1 and 0.5; two at 4, 2 and 0.25) and no cluster-robust interval is claimed.
Preprints 237540 g0a3
Figure A4. Device ablations. (a) Dwell-time dispersion σ Δ of 0, 0.5 and 1.0 with mean- τ corr centring, so dispersion is isolated from a mean slowdown, three chip seeds; solid lines the Dirichlet rule, dashed lines the corrected rule. (b) The Arrhenius class with an attempt-frequency cap ( τ corr ( 0 ) / τ 0 = 2 ) against the uncapped Arrhenius and bias-independent classes. In the plots the bias-independent-rate class is labelled easy-plane and the corrected rule Markov SPRT.
Figure A4. Device ablations. (a) Dwell-time dispersion σ Δ of 0, 0.5 and 1.0 with mean- τ corr centring, so dispersion is isolated from a mean slowdown, three chip seeds; solid lines the Dirichlet rule, dashed lines the corrected rule. (b) The Arrhenius class with an attempt-frequency cap ( τ corr ( 0 ) / τ 0 = 2 ) against the uncapped Arrhenius and bias-independent classes. In the plots the bias-independent-rate class is labelled easy-plane and the corrected rule Markov SPRT.
Preprints 237540 g0a4
Table A1. Transfer of the chain parameter. Lag-one autocorrelation of the full-stream plurality indicator (Section 2.7) over marginal-stratum inputs whose votes fluctuate, on the first 2000 validation images (the value passed to the Markov SPRT) against the value realized on test, as validation/test pairs with the leading zero dropped. The validation measurement uses no labels and no test data; test values are cell means. The capped class ran only at r 0 ≤ 1 .
Table A1. Transfer of the chain parameter. Lag-one autocorrelation of the full-stream plurality indicator (Section 2.7) over marginal-stratum inputs whose votes fluctuate, on the first 2000 validation images (the value passed to the Markov SPRT) against the value realized on test, as validation/test pairs with the leading zero dropped. The validation measurement uses no labels and no test data; test values are cell means. The capped class ran only at r 0 ≤ 1 .
Class and Mode (val/test) r 0 = 4 2 1 0.5 0.25
Bias-independent, settle .011/.009 .106/.096 .271/.272 .466/.451 .591/.592
Bias-independent, stream .015/.009 .111/.097 .285/.281 .493/.499 .673/.675
Arrhenius, settle .006/.001 .059/.055 .202/.197 .390/.377 .544/.534
Arrhenius, stream .008/.002 .064/.054 .207/.201 .382/.392 .578/.577
Arrhenius capped — — .210/.202 .389/.390 .552/.546
Table A2. Stratum-cut sensitivity at r 0 = 0.5 , recomputed from stored per-input arrays with no additional runs. Absolute marginal-stratum error (cell means over 15 cells) and, in the second row of each pair, the calibration-referenced ratio formed cut by cut against the ideal-randomness error at that same cut. The absolute level tracks the cut; the ratio does not.
Table A2. Stratum-cut sensitivity at r 0 = 0.5 , recomputed from stored per-input arrays with no additional runs. Absolute marginal-stratum error (cell means over 15 cells) and, in the second row of each pair, the calibration-referenced ratio formed cut by cut against the ideal-randomness error at that same cut. The absolute level tracks the cut; the ratio does not.
Rule Quantity Cut 0.8 0.9 0.95
Wald SPRT error 0.0803 0.0582 0.0450
ratio 3.15 3.18 3.18
Dirichlet error 0.1508 0.1129 0.0879
ratio 3.91 4.07 4.10
Markov SPRT error 0.0447 0.0321 0.0248
ratio 1.75 1.76 1.75

References

  1. Camsari, K.Y.; Faria, R.; Sutton, B.M.; Datta, S. Stochastic p-Bits for Invertible Logic. Physical Review X 2017, 7, 031014. arXiv:1610.00377. [CrossRef]
  2. Kaiser, J.; Datta, S. Probabilistic computing with p-bits. Applied Physics Letters 2021, 119, 150503. arXiv:2108.09836. [CrossRef]
  3. Hassan, O.; Datta, S.; Camsari, K.Y. Quantitative Evaluation of Hardware Binary Stochastic Neurons. Physical Review Applied 2021, 15, 064046. [CrossRef]
  4. Ghantasala, L.A.; Li, M.C.; Jaiswal, R.; Behin-Aein, B.; Makin, J.; Sen, S.; Datta, S. Improving deep neural network performance through sampling. npj Unconventional Computing 2026, 3, 18. arXiv:2507.07763. [CrossRef]
  5. Sun, J.Z.; Safranski, C.; Koswatta, S.; Hashemi, P.; Kent, A.D. Superparamagnetic and Stochastic-Write Magnetic Tunnel Junctions for High-Speed True Random Number Generation in Advanced Computing. Journal of Physics D: Applied Physics 2026, 59, 013002. arXiv:2509.13469. [CrossRef]
  6. Vodenicarevic, D.; Locatelli, N.; Mizrahi, A.; Friedman, J.S.; Vincent, A.F.; Romera, M.; Fukushima, A.; Yakushiji, K.; Kubota, H.; Yuasa, S.; et al. Low-Energy Truly Random Number Generation with Superparamagnetic Tunnel Junctions for Unconventional Computing. Physical Review Applied 2017, 8, 054045. [CrossRef]
  7. Daniels, M.W.; Madhavan, A.; Talatchian, P.; Mizrahi, A.; Stiles, M.D. Energy-Efficient Stochastic Computing with Superparamagnetic Tunnel Junctions. Physical Review Applied 2020, 13, 034016. arXiv:1911.11204. [CrossRef]
  8. Singh, N.S.; Kobayashi, K.; Cao, Q.; Selcuk, K.; Hu, T.; Niazi, S.; Aadit, N.A.; Kanai, S.; Ohno, H.; Fukami, S.; et al. CMOS plus stochastic nanomagnets enabling heterogeneous computers for probabilistic inference and learning. Nature Communications 2024, 15, 2685. arXiv:2304.05949. [CrossRef]
  9. Sutton, B.M.; Faria, R.; Ghantasala, L.A.; Jaiswal, R.; Camsari, K.Y.; Datta, S. Autonomous Probabilistic Coprocessing with Petaflips per Second. IEEE Access 2020, 8, 157238–157252. arXiv:1907.09664. [CrossRef]
  10. Kaiser, J.; Borders, W.A.; Camsari, K.Y.; Fukami, S.; Ohno, H.; Datta, S. Hardware-Aware In Situ Learning Based on Stochastic Magnetic Tunnel Junctions. Physical Review Applied 2022, 17, 014016. arXiv:2102.05137. [CrossRef]
  11. Aadit, N.A.; Grimaldi, A.; Carpentieri, M.; Theogarajan, L.; Martinis, J.M.; Finocchio, G.; Camsari, K.Y. Massively Parallel Probabilistic Computing with Sparse Ising Machines. Nature Electronics 2022, 5, 460–468. [CrossRef]
  12. Alaghi, A.; Hayes, J.P. Survey of Stochastic Computing. ACM Transactions on Embedded Computing Systems 2013, 12, 92:1–92:19. [CrossRef]
  13. Alaghi, A.; Hayes, J.P. Exploiting correlation in stochastic circuit design. In Proceedings of the IEEE 31st International Conference on Computer Design (ICCD), 2013, pp. 39–46. [CrossRef]
  14. Baker, T.; Hayes, J. Impact of Autocorrelation on Stochastic Circuit Accuracy. In Proceedings of the 2019 IEEE Computer Society Annual Symposium on VLSI (ISVLSI). IEEE, 2019, pp. 271–277. [CrossRef]
  15. Liu, S.; Xiao, T.P.; Kwon, J.; Debusschere, B.J.; Agarwal, S.; Incorvia, J.A.C.; Bennett, C.H. Bayesian neural networks using magnetic tunnel junction-based probabilistic in-memory computing. Frontiers in Nanotechnology 2022, 4, 1021943. [CrossRef]
  16. Sokal, A.D. Monte Carlo Methods in Statistical Mechanics: Foundations and New Algorithms. In Functional Integration: Basics and Applications; Springer, 1997; pp. 131–192. [CrossRef]
  17. Gupta, M. Read rate limits for stochastic magnetic tunnel junction neurons in probabilistic-bit classifiers. IEEE Magn. Lett. 2026, submitted.
  18. Aggarwal, P.; Madaan, A.; Yang, Y.; Mausam. Let’s Sample Step by Step: Adaptive-Consistency for Efficient Reasoning and Coding with LLMs. In Proceedings of the 2023 Conference on Empirical Methods in Natural Language Processing. Association for Computational Linguistics, 2023, pp. 12375–12396. [CrossRef]
  19. Li, Y.; Moitra, A.; Geller, T.; Panda, P. Input-Aware Dynamic Timestep Spiking Neural Networks for Efficient In-Memory Computing. In Proceedings of the 2023 60th ACM/IEEE Design Automation Conference (DAC). IEEE, 2023, pp. 1–6. arXiv:2305.17346. [CrossRef]
  20. Li, Y.; Geller, T.; Kim, Y.; Panda, P. SEENN: Towards Temporal Spiking Early Exit Neural Networks. Adv. Neural Inf. Process. Syst. 2023, 36, 63327–63342. [CrossRef]
  21. Chen, J.; Park, S.; Simeone, O. Knowing When to Stop: Delay-Adaptive Spiking Neural Network Classifiers with Reliability Guarantees, 2023. arXiv:2305.11322.
  22. Hoffend, O.S.; Hayes, J.P. Runtime Termination Control in Stochastic Computing. IEEE Transactions on Emerging Topics in Computing 2026, 14, 69–79. [CrossRef]
  23. Ebihara, A.F.; Miyagawa, T.; Sakurai, K.; Imaoka, H. Sequential Density Ratio Estimation for Simultaneous Optimization of Speed and Accuracy. In Proceedings of the International Conference on Learning Representations (ICLR), 2021.
  24. Safranski, C.; Kaiser, J.; Trouilloud, P.; Hashemi, P.; Hu, G.; Sun, J.Z. Demonstration of Nanosecond Operation in Stochastic Magnetic Tunnel Junctions. Nano Letters 2021, 21, 2040–2045. arXiv:2010.14393. [CrossRef]
  25. Wood, P.; Pourmeidani, H.; DeMara, R.F. Modular Simulation Framework for Process Variation Analysis of MRAM-based Deep Belief Networks, 2020. arXiv:2002.00897.
  26. Zand, R.; Camsari, K.Y.; Datta, S.; DeMara, R.F. Composable Probabilistic Inference Networks Using MRAM-based Stochastic Neurons. ACM Journal on Emerging Technologies in Computing Systems 2019, 15, 1–22. arXiv:1811.11390. [CrossRef]
  27. Zhang, B.; Liu, Y.; Gao, T.; Yin, J.; Guan, Z.; Zhang, D.; Zeng, L. Automatic Extraction and Compensation of P-Bit Device Variations in Large Array Utilizing Boltzmann Machine Training. Micromachines 2025, 16, 133. [CrossRef]
  28. Courbariaux, M.; Bengio, Y.; David, J.P. BinaryConnect: Training Deep Neural Networks with Binary Weights during Propagations. Adv. Neural Inf. Process. Syst. 2015, 28.
  29. Hubara, I.; Courbariaux, M.; Soudry, D.; El-Yaniv, R.; Bengio, Y. Binarized Neural Networks. Adv. Neural Inf. Process. Syst. 2016, 29.
  30. Bengio, Y.; Léonard, N.; Courville, A. Estimating or Propagating Gradients Through Stochastic Neurons for Conditional Computation, 2013. arXiv:1308.3432.
  31. LeCun, Y.; Bottou, L.; Bengio, Y.; Haffner, P. Gradient-based learning applied to document recognition. Proceedings of the IEEE 1998, 86, 2278–2324. [CrossRef]
  32. Xiao, H.; Rasul, K.; Vollgraf, R. Fashion-MNIST: a Novel Image Dataset for Benchmarking Machine Learning Algorithms, 2017. arXiv:1708.07747.
  33. Wald, A. Sequential Tests of Statistical Hypotheses. The Annals of Mathematical Statistics 1945, 16, 117–186. [CrossRef]
  34. Wald, A.; Wolfowitz, J. Optimum Character of the Sequential Probability Ratio Test. The Annals of Mathematical Statistics 1948, 19, 326–339. [CrossRef]
  35. Ville, J. Étude critique de la notion de collectif; Number 3 in Monographies des Probabilités, Calcul des Probabilités et ses Applications, Gauthier-Villars: Paris, 1939.
  36. Dragalin, V.P.; Tartakovsky, A.G.; Veeravalli, V.V. Multihypothesis Sequential Probability Ratio Tests. I. Asymptotic Optimality. IEEE Transactions on Information Theory 1999, 45, 2448–2461. [CrossRef]
  37. Schmitz, N.; Süselbeck, B. Sequential Probability Ratio Tests for Homogeneous Markov Chains. In Mathematical Learning Models — Theory and Algorithms; Herkenrath, U.; Kalin, D.; Vogel, W., Eds.; Springer: New York, 1983; Vol. 20, Lecture Notes in Statistics, pp. 191–202. [CrossRef]
  38. Fuh, C.D. SPRT and CUSUM in Hidden Markov Models. The Annals of Statistics 2003, 31, 942–977. [CrossRef]
  39. Tartakovsky, A.; Nikiforov, I.; Basseville, M. Sequential Analysis: Hypothesis Testing and Changepoint Detection; Chapman and Hall/CRC, 2014. [CrossRef]
  40. Howard, S.R.; Ramdas, A.; McAuliffe, J.; Sekhon, J. Time-Uniform Chernoff Bounds via Nonnegative Supermartingales. Probability Surveys 2020, 17, 257–317. [CrossRef]
  41. Ramdas, A.; Grünwald, P.; Vovk, V.; Shafer, G. Game-Theoretic Statistics and Safe Anytime-Valid Inference. Statistical Science 2023, 38, 576–601. [CrossRef]
  42. Tartakovsky, A.G. Sequential Change Detection and Hypothesis Testing; Chapman and Hall/CRC, 2019. [CrossRef]
  43. Criss, T.; Sidi El Valli, A.; Li, N.; Haas, A.; Kent, A.D. Magnetic Tunnel Junction as a Real-Time Entropy Source: Field-Programmable Gate Array Based Random Bit Generation without Post-Processing. Journal of Applied Physics 2026, 139, 013903. arXiv:2510.20735. [CrossRef]
  44. Ebihara, A.F.; Miyagawa, T.; Sakurai, K.; Imaoka, H. Learning the Optimal Stopping for Early Classification within Finite Horizons via Sequential Probability Ratio Test. In Proceedings of the International Conference on Learning Representations (ICLR), 2025.
  45. Jazbec, M.; Forré, P.; Mandt, S.; Zhang, D.; Nalisnick, E. Early-Exit Neural Networks with Nested Prediction Sets. In Proceedings of the Fortieth Conference on Uncertainty in Artificial Intelligence. PMLR, 2024, Vol. 244, Proceedings of Machine Learning Research, pp. 1780–1796. arXiv:2311.05931.
  46. Jazbec, M.; Timans, A.; Hadži Veljković, T.; Sakmann, K.; Zhang, D.; Naesseth, C.A.; Nalisnick, E. Fast yet Safe: Early-Exiting with Risk Control. Adv. Neural Inf. Process. Syst. 2024, 37, 129825–129854. arXiv:2405.20915. [CrossRef]
  47. Chen, T.H.; Ting, P.; Hayes, J.P. Achieving Progressive Precision in Stochastic Computing. In Proceedings of the 2017 IEEE Global Conference on Signal and Information Processing (GlobalSIP). IEEE, 2017, pp. 1320–1324. [CrossRef]
  48. Hsiao, H.; San Miguel, J.; Anderson, J. Streaming Accuracy: Characterizing Early Termination in Stochastic Computing. In Proceedings of the 2022 27th Asia and South Pacific Design Automation Conference (ASP-DAC). IEEE, 2022, pp. 320–325. [CrossRef]
  49. Wu, D.; Yin, R.; San Miguel, J. Normalized Stability: A Cross-Level Design Metric for Early Termination in Stochastic Computing. In Proceedings of the 26th Asia and South Pacific Design Automation Conference. ACM, 2021, pp. 254–259. [CrossRef]
  50. Chen, W.C.; Wong, H.S.P.; Achour, S. Bitwise Adaptive Early Termination in Hyperdimensional Computing Inference. In Proceedings of the 61st ACM/IEEE Design Automation Conference. ACM, 2024, pp. 1–6. [CrossRef]
  51. Kamisian, I.; Marsono, M.N.; Paraman, N.; Hamzah, A.; Zakaria, J. Characterization of Early Termination for Stochastic Computing Image Processing Circuits. In Proceedings of the 2024 IEEE 14th Symposium on Computer Applications & Industrial Electronics (ISCAIE). IEEE, 2024, pp. 395–400. [CrossRef]
  52. Ando, K.; Saito, T.; Asai, T. BBBNN: Bernoulli Binary Bayesian Neural Network Accelerator toward Edge Explainable AI Inference. Nonlinear Theory and Its Applications, IEICE 2025, 16, 788–805. [CrossRef]
Figure 1. Adaptive probabilistic-bit (p-bit) inference studied here, in a 784–256–128–10 multilayer perceptron (MLP). Each pass resamples every stochastic hidden neuron (a simulated stochastic magnetic tunnel junction, sMTJ) and yields one vote; a stopping rule reads the running vote counts and either stops, returning a decision, or requests another pass after the read interval Δ t . In settle mode (timeline) each input first relaxes for four correlation times. Reads spaced by less than a few correlation times return autocorrelated votes, although every neuron’s firing probability is unchanged.
Figure 1. Adaptive probabilistic-bit (p-bit) inference studied here, in a 784–256–128–10 multilayer perceptron (MLP). Each pass resamples every stochastic hidden neuron (a simulated stochastic magnetic tunnel junction, sMTJ) and yields one vote; a stopping rule reads the running vote counts and either stops, returning a decision, or requests another pass after the read interval Δ t . In settle mode (timeline) each input first relaxes for four correlation times. Reads spaced by less than a few correlation times return autocorrelated votes, although every neuron’s firing probability is unchanged.
Preprints 237540 g001
Figure 2. Stopping error grows with read rate in two unrelated rule families. Marginal-stratum stopping error against sampling ratio r 0 , bias-independent-rate devices (labelled easy-plane in the figures) in settle mode, MNIST test split, α = 0.05 , at most 256 passes. (a) Each rule’s error divided by the same rule’s error under ideal randomness (dotted line at unity), logarithmic vertical axis; the denominator is that rule’s ideal-randomness error pooled over all ideal cells and held fixed, so the bands exclude its uncertainty (Section 2.9). (b) Error over each rule’s own nominal scale ( α , or α / ( 1 − β ) for the SPRTs), so that unity is each rule’s own claim. In (a) and (b) marker area encodes the mean truncation rate. (c) Marginal-stratum task accuracy at fixed N ∈ { 4 , 8 , 64 } (matched stratum and budget, as titled in the panel). Intervals are cluster-robust over three training seeds where three exist and min–max over cells otherwise, as labelled.
Figure 2. Stopping error grows with read rate in two unrelated rule families. Marginal-stratum stopping error against sampling ratio r 0 , bias-independent-rate devices (labelled easy-plane in the figures) in settle mode, MNIST test split, α = 0.05 , at most 256 passes. (a) Each rule’s error divided by the same rule’s error under ideal randomness (dotted line at unity), logarithmic vertical axis; the denominator is that rule’s ideal-randomness error pooled over all ideal cells and held fixed, so the bands exclude its uncertainty (Section 2.9). (b) Error over each rule’s own nominal scale ( α , or α / ( 1 − β ) for the SPRTs), so that unity is each rule’s own claim. In (a) and (b) marker area encodes the mean truncation rate. (c) Marginal-stratum task accuracy at fixed N ∈ { 4 , 8 , 64 } (matched stratum and budget, as titled in the panel). Intervals are cluster-robust over three training seeds where three exist and min–max over cells otherwise, as labelled.
Preprints 237540 g002
Figure 3. Adaptive rules stay on the accuracy frontier while their stopping level fails. Whole-test-set task accuracy against mean passes per decision; panels, left to right, are r 0 = ∞ (ideal randomness), 1 and 0.5; logarithmic horizontal axis. Grey lines are the fixed-N ladder, N ∈ { 1 , 2 , 4 , … , 256 } , at each panel’s own r 0 , so each panel compares adaptive and fixed-budget inference at matched randomness quality. Markers are the adaptive rules, with marker area encoding truncation and error bars cluster-robust or min–max as labelled.
Figure 3. Adaptive rules stay on the accuracy frontier while their stopping level fails. Whole-test-set task accuracy against mean passes per decision; panels, left to right, are r 0 = ∞ (ideal randomness), 1 and 0.5; logarithmic horizontal axis. Grey lines are the fixed-N ladder, N ∈ { 1 , 2 , 4 , … , 256 } , at each panel’s own r 0 , so each panel compares adaptive and fixed-budget inference at matched randomness quality. Markers are the adaptive rules, with marker area encoding truncation and error bars cluster-robust or min–max as labelled.
Preprints 237540 g003
Figure 4. Mechanism: autocorrelated votes inflate variance. (a) Mean lag-k autocorrelation of the vote indicator, k ≤ 48 , for each r 0 , over marginal-stratum inputs whose votes fluctuate (the panel title’s “images whose votes fluctuate” means this marginal stratum). (b) Lag-one vote autocorrelation over the same inputs for every device class and mode, with the i.i.d. control (the bias-independent-rate class is labelled easy-plane); open squares are the validation-measured values passed to the Markov SPRT, which uses no labels and no test data (the indicator is the full-stream plurality indicator of Section 2.7, a proxy for the top-two sub-stream the SPRT acts on). (c) Integrated variance inflation factor implied by (a) against the first-order prediction ( 1 + ρ ) / ( 1 − ρ ) . (d) Marginal-stratum stopping error at r 0 = 0.5 split into the fired and truncated (budget-exhausted) channels (the legend’s “fired (the bounded channel)” means an evidence-driven stop, not a guaranteed bound); bars are means over the 15 replicate cells (five noise seeds and three training seeds) and sum to the total.
Figure 4. Mechanism: autocorrelated votes inflate variance. (a) Mean lag-k autocorrelation of the vote indicator, k ≤ 48 , for each r 0 , over marginal-stratum inputs whose votes fluctuate (the panel title’s “images whose votes fluctuate” means this marginal stratum). (b) Lag-one vote autocorrelation over the same inputs for every device class and mode, with the i.i.d. control (the bias-independent-rate class is labelled easy-plane); open squares are the validation-measured values passed to the Markov SPRT, which uses no labels and no test data (the indicator is the full-stream plurality indicator of Section 2.7, a proxy for the top-two sub-stream the SPRT acts on). (c) Integrated variance inflation factor implied by (a) against the first-order prediction ( 1 + ρ ) / ( 1 − ρ ) . (d) Marginal-stratum stopping error at r 0 = 0.5 split into the fired and truncated (budget-exhausted) channels (the legend’s “fired (the bounded channel)” means an evidence-driven stop, not a guaranteed bound); bars are means over the 15 replicate cells (five noise seeds and three training seeds) and sum to the total.
Preprints 237540 g004
Figure 5. Cost of each rule under a compliance filter. Mean stochastic passes per decision (whole test set) against r 0 , logarithmic vertical axis. Marker fill encodes the filter: filled, every replicate cell’s marginal-stratum error has a Wilson 95% upper bound at or below α ; open, no cell does; half-filled, some do, with the percentage printed beside the marker. Marker area encodes truncation. The dashed line is the standard remedy, the naive Dirichlet rule (labelled throttled naive) throttled to the compliant r 0 = 4 , charged in latency-equivalent pass slots. The Markov SPRT is the corrected rule of the text; triangles near the top are the degenerate per-input online- ρ ablation (Figure A2a).
Figure 5. Cost of each rule under a compliance filter. Mean stochastic passes per decision (whole test set) against r 0 , logarithmic vertical axis. Marker fill encodes the filter: filled, every replicate cell’s marginal-stratum error has a Wilson 95% upper bound at or below α ; open, no cell does; half-filled, some do, with the percentage printed beside the marker. Marker area encodes truncation. The dashed line is the standard remedy, the naive Dirichlet rule (labelled throttled naive) throttled to the compliant r 0 = 4 , charged in latency-equivalent pass slots. The Markov SPRT is the corrected rule of the text; triangles near the top are the degenerate per-input online- ρ ablation (Figure A2a).
Preprints 237540 g005
Table 1. Cost and compliance by stopping rule and sampling ratio. Bias-independent-rate devices in settle mode, MNIST test split. Upper block: mean passes per decision over the whole test set, with cluster-robust intervals over three training seeds. Lower block: percentage of replicate cells whose marginal-stratum stopping error has a Wilson 95% upper bound at or below α ( n = 15 replicate cells at r 0 = 1 and 0.5, n = 6 elsewhere), and the whole-test-set truncation rate in per cent. The last two rows are charging conventions, not rules; the settle row is in each column’s own operating clock.
Table 1. Cost and compliance by stopping rule and sampling ratio. Bias-independent-rate devices in settle mode, MNIST test split. Upper block: mean passes per decision over the whole test set, with cluster-robust intervals over three training seeds. Lower block: percentage of replicate cells whose marginal-stratum stopping error has a Wilson 95% upper bound at or below α ( n = 15 replicate cells at r 0 = 1 and 0.5, n = 6 elsewhere), and the whole-test-set truncation rate in per cent. The last two rows are charging conventions, not rules; the settle row is in each column’s own operating clock.
Rule r 0 = 4 r 0 = 2 r 0 = 1 r 0 = 0.5 r 0 = 0.25
Mean passes per decision
Dirichlet (naive) 5.4 [5.0–5.8] 5.0 [4.8–5.3] 4.7 [4.6–4.7] 4.4 [4.3–4.4] 4.2 [4.2–4.2]
Wald SPRT (naive) 11.2 [10.5–11.9] 10.8 [10.2–11.3] 10.2 [9.9–10.5] 9.4 [9.2–9.6] 8.8 [8.6–9.0]
Markov SPRT (measured ρ ) 11.3 [10.5–12.0] 12.1 [11.5–12.7] 15.1 [14.6–15.5] 20.2 [19.8–20.7] 26.4 [26.1–26.6]
Markov SPRT (online ρ ) 218.7 [217.7–219.6] 223.2 [222.1–224.3] 229.2 [229.1–229.4] 233.6 [232.8–234.4] 237.9 [237.1–238.7]
e-process (Ville) 16.3 [16.0–16.7] 15.8 [15.5–16.1] 15.0 [14.7–15.4] 14.2 [13.9–14.5] 13.3 [13.2–13.4]
Cells inside α (%) / truncation rate (%)
Dirichlet (naive) 83 / 0.19 33 / 0.11 0 / 0.05 0 / 0.01 0 / 0.00
Wald SPRT (naive) 100 / 0.92 100 / 0.76 87 / 0.57 0 / 0.27 0 / 0.08
Markov SPRT (measured ρ ) 100 / 0.92 100 / 0.83 100 / 0.78 60 / 0.73 33 / 0.65
Markov SPRT (online ρ ) 100 / 80.5 100 / 82.8 100 / 85.6 47 / 87.5 0 / 89.1
e-process (Ville) 100 / 1.42 100 / 1.27 100 / 1.03 27 / 0.75 0 / 0.45
Throttled Dirichlet, latency-eq. passes 5.4 10.7 21.4 42.8 85.7
Settle overhead, pass slots 1.0 2.0 4.0 8.0 16.0
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.
Copyright: This open access article is published under a Creative Commons CC BY 4.0 license, which permit the free download, distribution, and reuse, provided that the author and preprint are cited in any reuse.