chaeyeunpark / UnionFind

C++ implementation of Union-Find decoder and its Python binding.
GNU Lesser General Public License v2.1
24 stars 4 forks source link

decoder with open boundary #14

Open a0024356 opened 1 year ago

a0024356 commented 1 year ago

Hi, I am a beginner at QEC and I would like to use this code. But the explanation seems to assume the periodic boundary. Could you tell me if this project also supports union-find decoder with open boundary?

chaeyeunpark commented 1 year ago

Yes, the current version of the code supports a QEC with the open boundary condition. You can just pass the corresponding parity matrix as in this usage document. If you want faster runtime, you may need to use C++ code directly, which I explained here.

a0024356 commented 1 year ago

Thank you for your quick reply, but I got a segmentation fault error when I used a parity matrix like this: H=[[1 1 0 1 0 0 0 0 0 0 0 0 0] [0 1 1 0 1 0 0 0 0 0 0 0 0] [0 0 0 1 0 1 1 0 1 0 0 0 0] [0 0 0 0 1 0 1 1 0 1 0 0 0] [0 0 0 0 0 0 0 0 1 0 1 1 0] [0 0 0 0 0 0 0 0 0 1 0 1 1]] I am trying to decode d=3 surface code with the open boundary. Is there any good solution? Or isn't it the right way to create parity matrix?

chaeyeunpark commented 1 year ago

Hi, I confirm that the current implementation does not support this parity matrix as it assumes that a qubit is associated with two nearby syndromes. I am fixing this by relaxing the condition. I will update here when it is fixed. Thanks for reporting an issue :smile:

a0024356 commented 1 year ago

Thank you for the verification. I look forward to hearing from you.