Distance Prediction for Quantum Codes
Organizations: School of Electrical and Computer Engineering, Ben-Gurion University of the Negev, Israel
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 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
Figures & tables
| QDistRnd | QDistEvol | BP-OSD | GEStim | CCStim | UEStim | BB-Net (ours) | |
| Trials Per Code | 200 | 200 | 200 | 1 | 1 | 3 | 1 |
| Time Per Code [s] ( ) | 3.3 | 1.0 | 19.1 | 1.2 | 1.2 | 13.1 | 0.005 |
| Total Time [s] ( ) | 19,383 | 6,057 | 112,275 | 6,940 | 7,164 | 76,775 | 26.8 |
| RMSE ( ) | 2.319 | 1.485 | 23.322 | 4.950 | 9.309 | 1.933 | 1.131 |
| Accuracy ( ) | 92.20% | 94.86% | 82.23% | 0.02% | 34.60% | 61.23% | 96.39% |
| QDistRnd | QDistEvol | BP-OSD | GEStim | CCStim | UEStim | BB-Net (ours) | |
| Trials Per Code | 200 | 200 | 200 | 1 | 1 | 3 | 1 |
| Time Per Code [s] ( ) | 5.0 | 1.6 | 3.8 | 1.0 | 1.0 | 2.1 | 0.005 |
| Total Time [s] ( ) | 11,887 | 3,883 | 9,032 | 2,406 | 2,407 | 4,898 | 10.8 |
| RMSE ( ) | 0.000 | 0.000 | 0.699 | 11.453 | 7.434 | 2.641 | 0.594 |
| Accuracy ( ) | 100.00% | 100.00% | 99.96% | 0.04% | 64.03% | 98.44% | 98.94% |
| QDistRnd | QDistEvol | BP-OSD | GEStim | CCStim | UEStim | BB-Net (ours) | |
| Trials Per Code | 200 | 200 | 200 | 1 | 1 | 3 | 1 |
| Time Per Code [s] ( ) | 2.1 | 0.6 | 29.5 | 1.3 | 1.4 | 20.5 | 0.005 |
| Total Time [s] ( ) | 7,496 | 2,175 | 103,243 | 4,535 | 4,758 | 71,877 | 16.0 |
| RMSE ( ) | 3.002 | 1.923 | 30.181 | 42.355 | 35.362 | 37.190 | 1.380 |
| Accuracy ( ) | 86.93% | 91.38% | 70.26% | 0.00% | 14.73% | 36.10% | 94.66% |
| BB-Net | 1.000 | 0.998 | 0.996 | 0.993 | 0.989 | 0.989 | 0.988 | 0.987 | 0.990 | 0.991 |
| QDistEvol | 1.000 | 1.000 | 1.000 | 1.000 | 0.999 | 0.998 | 0.998 | 0.995 | 0.991 | 0.992 |
| QDistRnd | 1.000 | 1.000 | 1.000 | 1.000 | 1.000 | 0.998 | 0.997 | 0.993 | 0.991 | 0.990 |
| BP-OSD | 1.000 | 1.000 | 1.000 | 0.997 | 0.987 | 0.967 | 0.950 | 0.936 | 0.931 | 0.926 |
| UEStim | 0.996 | 0.996 | 0.997 | 0.992 | 0.974 | 0.944 | 0.917 | 0.900 | 0.890 | 0.883 |
| GEStim | 0.998 | 0.946 | 0.913 | 0.892 | 0.876 | 0.871 | 0.855 | 0.849 | 0.845 | 0.845 |
| Component | NLL | |||
| Aug. | Shift-Canon | FiLM | BB-Net | BB-Net-Tanner |
Appendix figures & tables3 assets
Supplementary material from the paper’s appendix.
Appendix
| Params | Values |
| 8 | |
| 256 | |
| lr | 3e-4 |
| Dropout | 0.1 |
| Epochs | 90 |
| Warmup Epochs | 9 |
| GT | BP-OSD | QDistEvol | QDistRnd | BB-Net (ours) | |||||
| – | – | 18 | 44 | 45 | 18 | 18 | |||
| – | – | 25 | 35 | 38 | 37 | 25 | |||
| 24 | Fail | 36 | 26 | 24 | |||||
| 24 | Fail | 36 | 44 | 24 | |||||
| – | – | 25 | 37 | 36 | 28 | 25 | |||
| – | – | 20 | 30 | 30 | 22 | 20 |