You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Adds an optional reweighting_strength argument to Matching.decode, Matching.decode_batch and Matching.decode_to_edges_array, used when enable_correlations=True.
After the first pass, correlated matching gives each edge correlated with a selected edge the probability min(P, 0.5), where P is its conditional probability given the selected edge. With this option it becomes min(reweighting_strength * P, 0.5). Values of reweighting_strength below 1.0 decrease the conditional probabilities and increase the posterior (implied/conditional) weights. The default (1.0) leaves behaviour unchanged: predictions and solution weights are bit-identical to v2.4.0.
The motivation is that, under circuit-level noise, selecting one edge in the first pass discounts several correlated edges at once. The second pass can then select several edges discounted by the same source edge, ignoring the cost of the additional independent faults that their joint occurrence requires. Deep below threshold, correlated matching fails on $(d-1)/2$ faults in a distance-$d$ surface code, losing a unit of effective distance and its advantage over uncorrelated matching. A reweighting_strength below 1.0, calibrated to the (characteristic) physical error rate, restores that advantage; see arXiv:2610.26785.
I built and tested the native reweighting_strength implementation at 176534d. On the inputs below, plain matching and s=1 each reproduced the corresponding PyMatching 2.4.0 observable predictions.
Stim 1.17.dev1793242987, surface_code:rotated_memory_z, rounds=d, after_clifford_depolarization=p and decompose_errors=True. Each fault is one flattened DEM error instruction. Pair rows enumerate all 1,906,128 unordered pairs of distinct instructions at each p. The sampled row uses the same 200,000 shots for every decoder (seed 1).
d, p
Outcome
Plain
s=1
s=0.5
s=0.2
s=0.1
s=0.05
3, 0.001
Single-fault failures / 286
0
6
2
0
0
0
5, 0.001
Pair failures
0
1173
633
167
28
4
5, 0.005
Pair failures
0
990
389
76
4
0
5, 0.005
Sampled logical errors
697
527
474
522
603
664
On five noisy TQEC gallery circuits (memory, move_rotation, cnot, three_cnots, steane_encoding), s=0.2 cleared all single-fault failures in four circuits. Memory still had two and cleared at s=0.1. At s=0.1, four circuits had higher observed logical error counts than s=1 on the same 100,000 shots per circuit (seed 20261119). TQEC gallery at 7f76728
The two d=5 cases showed different results at s=0.05. At p=0.005, that strength cleared the enumerated pairs and had a higher sampled logical error count than s=1. These observations cover the listed circuits, noise settings, DEM decompositions and fault weights.
AI disclosure: AI tools ran and checked these experiments at my direction.
This branch has not been deployed
No deployments
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds an optional
reweighting_strengthargument toMatching.decode,Matching.decode_batchandMatching.decode_to_edges_array, used whenenable_correlations=True.After the first pass, correlated matching gives each edge correlated with a selected edge the probability min(P, 0.5), where P is its conditional probability given the selected edge. With this option it becomes min(reweighting_strength * P, 0.5). Values of
reweighting_strengthbelow 1.0 decrease the conditional probabilities and increase the posterior (implied/conditional) weights. The default (1.0) leaves behaviour unchanged: predictions and solution weights are bit-identical to v2.4.0.The motivation is that, under circuit-level noise, selecting one edge in the first pass discounts several correlated edges at once. The second pass can then select several edges discounted by the same source edge, ignoring the cost of the additional independent faults that their joint occurrence requires. Deep below threshold, correlated matching fails on$(d-1)/2$ faults in a distance-$d$ surface code, losing a unit of effective distance and its advantage over uncorrelated matching. A
reweighting_strengthbelow 1.0, calibrated to the (characteristic) physical error rate, restores that advantage; see arXiv:2610.26785.Example usage: