Skip to content

Commit 47d0e70

Browse files
committed
2 parents 0647264 + c4a29d2 commit 47d0e70

File tree

5 files changed

+40
-3
lines changed

5 files changed

+40
-3
lines changed

.github/workflows/prerelease.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
fail-fast: true
4848
matrix:
4949
os: [ubuntu-22.04, ubuntu-24.04, macos-13, macos-14]
50-
python-version: ['3.10', '3.11', '3.12']
50+
python-version: ['3.10', '3.11', '3.12', '3.13']
5151
steps:
5252
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
5353
- name: Set up Python

.github/workflows/stable-release-workflow.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ jobs:
4646
fail-fast: true
4747
matrix:
4848
os: [ubuntu-22.04, ubuntu-24.04, macos-13, macos-14]
49-
python-version: ['3.10', '3.11', '3.12']
49+
python-version: ['3.10', '3.11', '3.12', '3.13']
5050

5151
steps:
5252
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4

BUILD

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ py_wheel(
3939
summary="A search-based decoder for quantum error correction (QEC).",
4040
author="The Tesseract Decoder Authors.",
4141
homepage="https://github.com/quantumlib/tesseract-decoder",
42+
license="Apache 2",
4243
)
4344

4445
config_setting(

README.md

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ A Search-Based Decoder for Quantum Error Correction.
1717

1818
</div>
1919

20+
2021
Tesseract is a Most Likely Error decoder designed for Low Density Parity Check (LDPC) quantum
2122
error-correcting codes. It applies pruning heuristics and manifold orientation techniques during a
2223
search over the error subsets to identify the most likely error configuration consistent with the
@@ -167,6 +168,11 @@ Here are some tips for improving performance:
167168

168169
This repository contains the C++ implementation of the Tesseract quantum error correction decoder, along with a Python wrapper. The Python wrapper/interface exposes the decoding algorithms and helper utilities, allowing Python users to leverage this high-performance decoding algorithm.
169170

171+
For installation:
172+
```bash
173+
pip install tesseract-decoder
174+
```
175+
170176
The following example demonstrates how to create and use the Tesseract decoder using the Python interface.
171177

172178
```python
@@ -206,8 +212,37 @@ print(f"Predicted errors indices: {predicted_errors}")
206212
for i in predicted_errors:
207213
print(f" {i}: {decoder.errors[i]}")
208214
```
215+
## Good Starting Points for Tesseract Configurations:
216+
The [Tesseract paper](https://arxiv.org/pdf/2503.10988) recommends two setup for starting your exploration with tesseract:
209217

210218

219+
(1) Long-beam setup:
220+
```
221+
tesseract_config = tesseract.TesseractConfig(
222+
dem=dem,
223+
pqlimit=1_000_000,
224+
det_beam=20,
225+
beam_climbing=True,
226+
num_det_orders=21,
227+
det_order=tesseract_decoder.utils.DetOrder.DetIndex,
228+
no_revisit_dets=True,
229+
)
230+
```
231+
(2) Short-beam setup:
232+
233+
```
234+
tesseract_config = tesseract.TesseractConfig(
235+
dem=dem,
236+
pqlimit=200_000,
237+
det_beam=15,
238+
beam_climbing=True,
239+
num_det_orders=16,
240+
det_order=tesseract_decoder.utils.DetOrder.DetIndex,
241+
no_revisit_dets=True,
242+
)
243+
```
244+
For `det_order`, you can use two other options of `DetIndex` and `DetCoordinate` as well.
245+
These values balance decoding speed and accuracy across the benchmarks reported in the paper and can be adjusted for specific use cases.
211246
## Help
212247

213248
* Do you have a feature request or want to report a bug? [Open an issue on

src/common.cc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,8 @@ stim::DetectorErrorModel common::merge_indistinguishable_errors(
127127
case stim::DemInstructionType::DEM_ERROR: {
128128
Error error(instruction);
129129
if (error.symptom.detectors.size() == 0) {
130-
throw std::invalid_argument("Errors that do not flip any detectors are not supported.");
130+
// TODO: For errors without detectors, the observables should be included if p>0.5
131+
std::cout << "Warning: the circuit has errors that do not flip any detectors \n";
131132
}
132133

133134
if (errors_by_symptom.find(error.symptom) != errors_by_symptom.end()) {

0 commit comments

Comments
 (0)