Skip to main content
KetQat

Appearance

Decoder · intermediate

Minimum-weight perfect matching decoder

Pairs detection events with each other or with a boundary so that the total log-likelihood weight of the connecting paths is minimal. Exact for the most likely error of a graph-like error model, polynomial time, and the reference decoder for surface codes.

ExpositionMachine-checkedUpdated 2026-12-01 · last verified 2026-12-01

AI-assisted text, machine-checked, not yet reviewed by a person. Citations resolve and an automated pass compared the statements with the cited sources. That is not peer review; check the sources for anything you depend on.

Input and output. A graph-like detector error model with edge weights wj=ln⁡((1−pj)/pj)w_j = \ln((1 - p_j)/p_j) and a set of detection events. The output is a set of edges whose end points, counted modulo 2, are the detection events, together with the logical observables that set flips.

Procedure. Compute lightest-path distances between detection events and from each event to the boundary, find a minimum-weight perfect matching of the events with the blossom algorithm, and return the union modulo 2 of the lightest paths between matched pairs. Implementations such as PyMatching explore the graph outward from the events instead of computing all pairwise distances first.

What it is exact for. By the matching theorem the output is a most likely error of the graph-like model. It is not the most likely coset: the decoder ignores how many errors of similar weight lie in each coset. It is also not exact for the true noise when one physical fault flips more than two detectors. A YY error on a surface-code qubit flips two XX-type and two ZZ-type detectors; decoding the two graphs separately discards that correlation.

Complexity. Polynomial in the number of detection events; this is Edmonds' theorem. In the regime of interest the cost is dominated by local exploration of the graph. The sparse blossom implementation decodes both bases of distance-17 surface-code circuits at 0.1% circuit-level depolarising noise in under one microsecond per round on one core. Fusion Blossom is a second fast implementation designed for parallel execution.

Accuracy. For the toric code with independent bit-flip noise and perfect syndrome measurement the matching threshold is the zero-temperature critical point of the random-bond Ising model, p=0.1031±0.0001p = 0.1031 \pm 0.0001, below the optimal value near 0.1090.109 obtained on the Nishimori line; with measurement errors of the same probability (phenomenological noise) it is 0.0293±0.00020.0293 \pm 0.0002 (Wang, Harrington and Preskill, following Dennis et al.). Under circuit-level depolarising noise reported thresholds lie between about 0.7% and 0.8%, depending on the circuit and noise details: 0.70% in Tan et al. and 0.82% in Higgott et al..

Variants. Correlated matching reweights one graph using the matching found in the other, to recover part of the XX–ZZ correlation (Fowler). Belief-matching sets the edge weights from a belief-propagation pass over the full hypergraph and raises the circuit-level threshold from 0.82% to 0.94% in the same study (Higgott et al.).

Holds when

  • Applies to graph-like detector error models, in which every error mechanism flips at most two detectors. Surface, toric and repetition codes under independent X and Z noise have this property; colour codes and general quantum LDPC codes do not.
Mentions
Part of
Mentioned in
Stated in

Open in the knowledge graph

Contributions about this record

Nobody has published a contribution about it yet.

Publish a result, reproduction or commentPropose a correction to this page

References

  1. Eric Dennis, Alexei Kitaev, Andrew Landahl, John Preskill (2002). Topological quantum memory. Journal of Mathematical Physics 43, 4452-4505. doi:10.1063/1.1499754arXiv:quant-ph/0110143
  2. Jack Edmonds (1965). Paths, Trees, and Flowers. Canadian Journal of Mathematics 17, 449-467. doi:10.4153/CJM-1965-045-4
  3. Chenyang Wang, Jim Harrington, John Preskill (2003). Confinement-Higgs transition in a disordered gauge theory and the accuracy threshold for quantum memory. Annals of Physics 303, 31-58. doi:10.1016/S0003-4916(02)00019-2arXiv:quant-ph/0207088
  4. Oscar Higgott (2022). PyMatching: A Python Package for Decoding Quantum Codes with Minimum-Weight Perfect Matching. ACM Transactions on Quantum Computing 3, 16. doi:10.1145/3505637arXiv:2105.13082
  5. Oscar Higgott, Craig Gidney (2025). Sparse Blossom: correcting a million errors per core second with minimum-weight matching. Quantum 9, 1600. doi:10.22331/q-2025-01-20-1600arXiv:2303.15933
  6. Yue Wu, Lin Zhong (2023). Fusion Blossom: Fast MWPM Decoders for QEC. 2023 IEEE International Conference on Quantum Computing and Engineering (QCE), 928-938. doi:10.1109/QCE57702.2023.00107arXiv:2305.08307
  7. Austin G. Fowler (2013). Optimal complexity correction of correlated errors in the surface code. arXiv preprint. arXiv:1310.0863
  8. Xinyu Tan, Fang Zhang, Rui Chao, … Jianxin Chen (2023). Scalable Surface-Code Decoders with Parallelization in Time. PRX Quantum 4, 040344. doi:10.1103/PRXQuantum.4.040344arXiv:2209.09219
  9. Oscar Higgott, Thomas C. Bohdanowicz, Aleksander Kubica, … Earl T. Campbell (2023). Improved Decoding of Circuit Noise and Fragile Boundaries of Tailored Surface Codes. Physical Review X 13, 031007. doi:10.1103/PhysRevX.13.031007arXiv:2203.04948

Contributors

  • KetQat maintainers · @ketqatConceptualization; Supervision (CRediT roles)
  • Claude (AI drafting assistant)Writing, original draft (CRediT roles)

Review history

  1. Automated source check · Pass · 2026-12-01 · Independent automated verification pass (AI, not the drafting session)

    Procedure and exactness statements checked against theorem/minimum-weight-matching-finds-a-most-likely-error; Y-error correlation (two X-type and two Z-type detectors in the bulk) re-derived. Numbers compared with full texts on arXiv: Wang-Harrington-Preskill quant-ph/0207088 (p_c0 = .1031 +- .0001 at T = 0, Nishimori value .1093 +- .0002, phenomenological .0293 +- .0002), Tan et al. 2209.09219 (MWPM 0.70%, UF 0.55% circuit-level batch thresholds), Higgott et al. 2203.04948 (MWPM 0.82%, belief-matching 0.94%); Sparse Blossom abstract 2303.15933 (distance-17, 0.1% circuit noise, under 1 microsecond per round on one core). Fusion Blossom, PyMatching, Fowler correlated-matching and Edmonds references consistent with their identifiers.

Revision history

  1. 2026-12-01Content release 2.1.0: 35 more topics, an independent source check of every record, intake hardening (#17)80537b7e
  2. 2026-11-30KetQat Commons: free learning paths, knowledge records, research problems, literature intake (#14)571c9b10

Current revision fd4b67c13577ae51. Source file knowledge/records/decoder/minimum-weight-perfect-matching.md in the content repository (readable there once it is public).