arXiv:2610.18130quant-phOct 2026

Manuscript Offprint

arXiv:2610.18130

Distance Prediction for Quantum Codes

Nadav Schneider, Eliya Nachmani

Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.

ABSTRACT

The distance of a quantum code is a fundamental metric that dictates its error-correction capability. While quantum low-density parity-check (qLDPC) families such as Bivariate Bicycle (BB) codes offer a promising pathway to low-overhead fault-tolerant quantum computing, computing their distance is challenging. Current exact solvers and even search heuristics that provide a distance upper bound suffer from severe computational bottlenecks, restricting the discovery of optimal codes. In this paper, we construct a dataset of BB codes with corresponding distance upper bounds obtained through high-budget heuristic searches. We introduce BB-Net, an attention-based neural network architecture for predicting the distance of BB codes. It achieves 96.39% accuracy on the reference distances in the test set, compared with 94.86% for state-of-the-art heuristics with a budget of up to 10410^{4} times more computational runtime. On a subset with certified exact distances, BB-Net achieves 98.94%. By relieving the distance-calculation bottleneck, BB-Net enables faster screening of large code spaces, particularly in ML-driven search pipelines, and thereby can accelerate the discovery of novel quantum error-correcting codes, an important capability for advancing scalable fault-tolerant quantum computing. Our code is publicly available.

https://github.com/NadavSc/BBNet

Figure

Figure 1: Distance estimation for bivariate bicycle codes through two approaches: computationally intensive heuristic search and orders of magnitude more efficient inference using BB-Net. Numbers refer to a full benchmark evaluation.

1 INTRODUCTION

Quantum computing offers the potential to solve computational problems that are intractable for classical methods (Steane, 1998; Preskill, 2012), with landmark algorithms such as Shor's factoring algorithm (Shor, 1994) and Grover's search algorithm (Grover, 1996) providing prominent examples of quantum computational advantage. Recent experimental advances across multiple quantum-computing platforms have further demonstrated this potential (Arute et al., 2019; Bharti et al., 2022; Bluvstein et al., 2024; Huang et al., 2022; Bennett & Brassard, 2014; Bao et al., 2023). However, realizing practical, large-scale quantum computation requires overcoming a fundamental challenge:

the inherent fragility of physical qubits. Highly susceptible to decoherence and operational errors (Burnett et al., 2019; Etxezarreta Martinez et al., 2021), physical qubits cannot reliably preserve quantum information for the duration of complex calculations.

Quantum Error Correction (QEC) is therefore indispensable for bridging the gap between noisy physical hardware and reliable computation (Shor, 1995; Terhal, 2015). Recently, there has been significant interest in the development of quantum Low-Density Parity-Check (qLDPC) codes, which hold the promise of substantially reducing the resource overhead required for fault-tolerant quantum computation (Panteleev & Kalachev, 2021; Breuckmann & Eberhardt, 2021). Within this class, Bivariate Bicycle (BB) codes have emerged as a highly promising family, offering a practical pathway to high-threshold, low-overhead fault tolerance that maps efficiently to physical hardware constraints (Bravyi et al., 2024), and recently, perturbed bivariate bicycle (PBB) codes have been introduced as a non-CSS ansatz that augments the BB polynomial pairs (Cruz-Benito et al., 2026).

The efficacy of any QEC protocol is anchored by a fundamental figure of merit: its minimum distance, d. The distance of a QEC code is defined as the minimum number of physical errors required to cause an undetectable logical failure. It provides a rigorous, decoder-agnostic guarantee of a code's ability to suppress errors. Consequently, discovering codes with optimal distances is a primary objective when designing new fault-tolerant architectures. However, the minimum-distance problem for quantum stabilizer codes is computationally hard: the corresponding decision problem is NP-complete, and exact distance computation is therefore NP-hard (Kapshikar & Kundu, 2023; Grigorescu et al., 2025). The analogous hardness result for classical linear codes was established by Vardy (1997).

To evaluate code distance, researchers traditionally rely on exact solvers, such as Mixed Integer Linear Programming (MILP) (Punekar et al., 2010), or search heuristics such as QDistRnd (Pryadko et al., 2023), which provide an upper bound. Exact methods scale exponentially and become computationally intractable even for moderate code sizes. While heuristics offer a relative speedup compared to exact solvers, they remain far from real-time execution. Consequently, evaluating the thousands or millions of candidates encountered in searches over qLDPC code families remains severely constrained by distance-estimation cost (Webster et al., 2026). A common strategy is therefore to perform distance screening: limited computational budget is first used to filter candidates, after which computationally intensive heuristics or exact solvers are applied only to the most promising codes to tighten bounds or obtain certificates (Qian & Li, 2026; Yan et al., 2026; Cruz-Benito et al., 2026). However, the effectiveness of such pipelines remains limited by the runtime of existing distance-estimation methods, leaving large portions of the design space unexplored.

In this paper, we address this critical bottleneck by introducing BB-Net, an attention-based neural network architecture for both BB and PBB codes. We propose a compact tokenization scheme that exploits the algebraic structure of BB codes, enabling BB-Net to learn informative latent representations for distance prediction. By relieving this bottleneck, BB-Net enables fast evaluation of large code spaces, particularly in ML-driven search pipelines, and thereby can accelerate the discovery of novel QEC codes, an important capability for advancing scalable fault-tolerant quantum computing.

Our main contributions are summarized as follows:

• We frame distance estimation for BB codes as a machine-learning problem: a network is trained on labels from expensive heuristic searches and predicts them at a small fraction of the cost. To our knowledge, this is the first work to predict quantum-code distance directly with a learned model.

• We present a designated dataset of approximately 58,000 code examples of both CSS BB and non-CSS PBB types with a corresponding distance upper bound.

• We propose a highly compressed input representation for the codes and an attention-based sequence neural network architecture, BB-Net, for this task.

• We show that BB-Net’s accuracy on the test benchmark is 96.39% compared to 94.86% by state-of-the-art heuristics with a budget of up to 10410^{4} more computational runtime, and it achieves 98.94% on certified exact distance subset test codes.

References (61)