0
$\begingroup$

Pymatching doesn't seems to be working for Steane's code on STIM. I am wondering is there any other decoder that I could possibly use? I am trying to simulate circuit-level noise in syndrome extraction circuit for Steane's Code. I am having issues integrating BPOSD into STIM.

$\endgroup$
1
  • $\begingroup$ Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking. $\endgroup$
    – Community Bot
    Commented Jan 11 at 16:58

2 Answers 2

1
$\begingroup$

You need to write three pieces of code:

  1. Configuration. Write something that takes a detector error model (dem) and configures your decoder with it. Typically this looks like glue code converting the dem into the graph format expected by the decoder, then initializing the decoder with that graph format. This is usually the hardest part to write.

  2. Shot decoding. Write something that takes a set of detection events, and converts that into a problem understood by the decoder, runs the decoder on the problem, and extracts the predictions about which observables were flipped. This usually isn't too hard to write but is the most important part to write well so that it's fast. You'll want (but don't initially need) a batched version that takes many shots at once, instead of one shot at a time.

  3. Wrapping. Package this up into a python class inheriting from sinter.Decoder. When you call sinter.collect tell it about your decoder via the argument custom_decoders={'bposd': YourDecoderClass()} and tell it to use your decoder via the argument decoders=['bposd'].

$\endgroup$
3
  • $\begingroup$ Hi @CraigGidney thank you very much for answering. BPOSD uses parity check matrices and performs Gaussian inversion after BP. However, pymatching uses graph. I am just wondering is there any way to convert the whole detector-error-model into parity check matrices and then use BPOSD. (I am very new to using STIM and I am still catching up on how it works) $\endgroup$ Commented Jan 12 at 0:49
  • $\begingroup$ @OmprakashChandra Doing that conversion is the "configuration" step you have to write. Stim doesn't have a built in way to do it, because a parity check matrix is an extremely inefficient representation for a large circuit. $\endgroup$ Commented Jan 12 at 1:58
  • $\begingroup$ that makes sense. Thanks again for responding. $\endgroup$ Commented Jan 14 at 23:58
0
$\begingroup$

The new version of the LDPC package that is currently under development, in the LDPC_V2 branch on LDPC's github repo, contains a Sinter BPOSD decoder.

This notebook shows step-by-step how to use the decoder to obtain a threshold.

$\endgroup$
1
  • $\begingroup$ That's very helpfull. Thanks @Peter_Jan $\endgroup$ Commented Jan 25 at 5:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.