---
title: Surface-GKP MWPM Decoder
url: https://www.emergentmind.com/topics/surface-gkp-mwpm-decoder
type: topic
---

# Surface-GKP MWPM Decoder

The Surface-GKP MWPM (Minimum-Weight Perfect Matching) decoder is a computational scheme enabling efficient and fault-tolerant error correction for quantum memories encoded using Gottesman-Kitaev-Preskill (GKP) bosonic codes concatenated with the surface code. This decoder integrates analog information from continuous-variable (CV) GKP measurements into a matching-based decoding framework over a 3D space–time syndrome graph, yielding improved thresholds and logical error rates compared to discrete-only (digitized) decoders. It is both the de facto practical decoder for surface-GKP codes in recent benchmarking studies and central to performance claims for experimentally viable continuous-variable quantum error correction [1908.03579, 2103.06994, 2303.04702, 2603.25757, 2603.06730, 2207.04383].

## 1. Surface-GKP Code Structure and Syndrome Extraction

The surface-GKP code concatenates N single-mode square GKP qubits (each realized in an oscillator) into a 2D surface code lattice. Each GKP mode encodes a qubit through a lattice of equally spaced displacements in phase space, while the higher-level surface code imposes additional stabilizer constraints for robust logical encoding. Typically, a square $d_0 \times d_0$ lattice is used, yielding $N = d_0^2$ data GKP modes [2303.04702]. Stabilizer measurements are performed iteratively in rounds, with each round extracting information about the defect (syndrome flip) locations. This process forms a space--time syndrome graph with vertices $(s, t)$, where $s$ indexes stabilizer checks (plaquettes/stars), and $t=0,\ldots,T$ indexes extraction rounds, with a noise-free round to close the temporal boundary [1908.03579, 2103.06994].

Continuous-variable GKP error correction occurs at the lowest layer: homodyne measurements yield continuous real-valued outcomes (e.g., $q$-modulo-$\sqrt{\pi}$), which are further digitized and processed to extract the syndrome and assign error probabilities. The Surface-GKP MWPM decoder exploits this analog measurement information rather than only the discretized syndromes [2103.06994, 2303.04702].

## 2. Space–Time Graph Construction and Noise Modeling

A 3D space--time graph encodes the propagation and measurement of errors, with vertices representing syndrome outcomes at each spatial and temporal location, and edges reflecting possible fault trajectories. Spatial edges correspond to data GKP qubits (i.e., faults propagating between checks sharing a qubit in the same round), while temporal edges link the same stabilizer between rounds, representing measurement errors [1908.03579]. In advanced decoders, additional edges encode space–time correlations generated by GKP-gate faults (e.g., CNOT or CZ gates) whose effect propagates both spatially and temporally in the syndrome graph [2103.06994]. Each edge is associated with a conditional probability of being traversed by a fault, determined by the noise model, which typically includes finite GKP squeezing ($\sigma^2$ parameterized as dB), circuit-level loss and heating, and measurement imprecision.

Crucially, correlated (non-i.i.d.) Gaussian shifts arising from two-qubit GKP gate errors are incorporated as nontrivial edge structures and weights, and the sum of variances due to all error channels is tracked precisely for each edge's noise parameter [2103.06994, 2207.04383].

## 3. Edge Weight Assignment with CV-Informed Probabilities

Edge weights in the matching graph are dynamically assigned using analog information from GKP stabilizer measurements. The operational principle is to compute the posterior Pauli error probability $p[\sigma](z)$ conditioned on the measured syndrome outcome $z$, rather than only using a fixed channel parameter [1908.03579, 2207.04383]. For a measurement result $z_{q,k}^{(t)}$ and total Gaussian-displacement variance $\sigma^2$, the relevant formula is:
\[
p[\sigma](z) = \frac{\sum_{n \in \mathbb{Z}} \exp\left[-\frac{(z-(2n+1)\sqrt{\pi})^2}{2 \sigma^2}\right]}
{\sum_{n \in \mathbb{Z}} \exp\left[-\frac{(z - n\sqrt{\pi})^2}{2 \sigma^2}\right]}
\]
with edge weight $w = -\log_2 p[\sigma](z)$.

For two-mode GKP EC following an entangling gate, the covariance of correlated shifts is incorporated:
\[
P^{[qq]}_{\mathrm{CNOT}}(\xi_1, \xi_2) = \frac{1}{2\pi\sqrt{|V|}} \exp\left[ -\frac{1}{2} [\xi_1, \xi_2]^T V^{-1} [\xi_1, \xi_2] \right]
\]
Maximum likelihood decoding selects integer shifts $(n_1, n_2)$ that maximize this likelihood. The final edge probabilities conditioned on the analog history replace tabulated gate error rates in weight assignments [2103.06994, 2207.04383].

Horizontal and vertical edges in the graph are assigned using precomputed total variances for each edge, and time-dependent renormalization of probabilities is performed to ensure dynamic, trial-by-trial weight updates [1908.03579].

## 4. The MWPM Decoding Algorithm

Defects are identified as vertices where the measured stabilizer outcomes flip between rounds. If the number of defects is odd in a time slice, one is artificially paired to the spatial or temporal boundary. The decoder proceeds as follows [1908.03579, 2103.06994]:

1. **Defect Identification:** Mark syndrome defects at $(s, t)$ where $S(s,t) \neq S(s, t-1)$.
2. **Shortest Paths:** Compute minimum-weight paths between all pairs of defects, where path weights are the sum of edge weights (from the dynamically assigned CV-informed probabilities).
3. **Perfect Matching:** Apply Edmonds' Blossom algorithm for minimum-weight perfect matching on the defect graph, pairing all defects with minimal total cost.
4. **Correction Path Lifting:** For each matched defect pair, retrieve the corresponding shortest path in the 3D syndrome graph and mark the associated edges.
5. **Physical Recovery:** Project marked horizontal edges to the surface code lattice and update the GKP frame (i.e., apply $\sqrt{\pi}$ shifts) on the corresponding data GKP qubits.
6. **Logical Assessment:** Evaluate the logical outcome by checking the parity of accumulated frame shifts and residual mode displacement.
7. **Statistical Processing:** Repeat for multiple trials; extract logical error rates and thresholds by analyzing the finite-size scaling and crossing points [1908.03579, 2303.04702].

The overall complexity is $\mathcal{O}(N^{3})$ for MWPM on $O(N)$ nodes, where $N$ is the number of surface code qubits; this is empirically observed as polynomial in code distance [2303.04702].

## 5. Performance, Thresholds, and Comparison to Alternative Decoders

Monte Carlo sampling across code distances and noise parameters determines the error threshold—the noise level $\sigma^*$ at which increasing code distance suppresses logical error rate. The canonical threshold for surface-GKP using MWPM with CV-informed weights is $\sigma^*=0.60$ (code-capacity, square GKP) [2303.04702]. With space–time-correlation and ML-decoded gates, thresholds improve to, e.g., 9.9 dB squeezing ($\sigma\simeq0.316$) in the finite-squeezing dominant regime, and 18.6 dB ($\kappa/g = 0.69\%$) in the full circuit-level noise model [2103.06994, 1908.03579, 2207.04383].

A direct comparison shows MWPM sits on the runtime–logical error Pareto frontier for both Pauli and native GKP-noise regimes, and substantially outperforms Union-Find, neural-guided MWPM, and belief propagation decoders in logical error rate and rank stability [2603.25757, 2603.06730]. The stability of finite-size crossing-based threshold estimates is unique to MWPM; other decoders fail to provide valid threshold crossings on standard estimator/grids.

Representative logical error rates for surface-GKP MWPM are (for $d=5$, $\sigma=0.20$): 0.2273 (MWPM) vs 0.2303 (Union-Find), 0.3730 (neural MWPM), and 0.6107 (belief propagation) [2603.25757]. Statistical benchmarking confirms that MWPM and Union-Find are close for moderate $\sigma$, but MWPM uniformly outperforms at higher noise.

## 6. Advanced Variants: Closest-Point Decoding and Decoder Robustness

The MWPM framework also supports closest lattice-point decoding for GKP codes embedded in the surface code. After rounding syndrome-inferred displacements to the nearest lattice point, remaining violated stabilizers define defects, and MWPM is used to determine the minimal set of corrections. The correction operator implements the closest symplectic-dual lattice vector, yielding the most likely (maximum-likelihood) recovery operation [2303.04702].

For asymmetric or generalized GKP concatenations (e.g., XZZX-surface GKP), similar MWPM procedures are used but with axis-dependent variances and aspect ratios, tuned for optimal threshold $\sigma^* \approx 0.67$ at $\lambda=2.1$ for the XZZX variant (compared to 0.60 for standard surface-GKP) [2207.04383].

Advanced simulation protocols such as LiDMaS+ enforce deterministic seeding, matched syndrome processing, and verify decoder failures by checking the satisfaction of $Hc \equiv y$. Neural-guided and Union-Find decoders may fail this verification at high-noise, but MWPM exhibits zero observed decoder failures [2603.06730].

## 7. Implementation, Resource Overheads, and Experimental Implications

Practical implementations utilize fast graph-matching libraries (e.g., PyMatching's Blossom V), multithreaded trial sampling, and runtime assignment of edge weights from ROI-specific GKP outcomes [2103.06994, 2603.25757]. MWPM decoding remains the performance baseline for researchers and experimenters, as it achieves logical failure rates $p_L<10^{-7}$ at moderate squeezing (e.g., $12$ dB using 291 GKP modes) versus $\sim1500$ qubits for the bare qubit surface code at the same error rate [2103.06994]. CV-informed edge weights and space–time-correlated matching are essential to achieving these overhead reductions.

These results indicate that the Surface-GKP MWPM decoder robustly enables hardware-friendly, scalable continuous-variable quantum error correction, establishing the standard for performance benchmarking, threshold estimation, and practical hardware proposals [1908.03579, 2103.06994, 2303.04702, 2603.25757, 2207.04383].

Source: https://www.emergentmind.com/topics/surface-gkp-mwpm-decoder