-
Notifications
You must be signed in to change notification settings - Fork 11
Add Steane-type and teleportation-based QEC for the Steane code #115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Something funny is going on in my testing, so I'm going to mark this as a draft until I figure it out... UPDATE: I think I fixed it. I'm still not sure I'm setting classical registers correctly though. |
| def qec(self, flag_bit: Bit | None = None): | ||
| def qec(self, flag: Bit | None = None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I also renamed flag_bit --> flag in this PR, for consistency with conventions elsewhere in the repo.
|
I think this PR fixes #112, which appears to just be an incorrect type hint |
|
Good questions. At first glance everything looks good... but I'll comb over everything shortly. More future facing stuff (not this PR): |
ciaranra
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
* Unroll broadcast face rotations (PECOS-packages#110) * Upgrade to using uv instead of pip (PECOS-packages#111) * Adding uv to Makefile * Turn on artifact generation (PECOS-packages#117) * Add T gates with active error correction (PECOS-packages#118) * remove t_tel_cor * bugfix in tdg_cor * fix t_cor * Permute all variables of the Steane code (PECOS-packages#114) * compute the swap of CRegs * Add Steane-type and teleportation-based QEC for the Steane code (PECOS-packages#115) * fix qec_steane_z * set flag bit correctly * add qec_steane_.*tel templates * fix Steane.qec_steane_tel * permute all qubits for teleportation * fix teleportation-based QEC * two flag bits for Steane.qec_tel * rename flag_bit --> flag, in agreement with elsewhere in the repo * fix If statement * fix Steane QEC and an incorrect type hint --------- Co-authored-by: Michael A. Perlin <[email protected]>
Teleportation-based QEC is essentially just one-bit teleportation, in which only one type of error (X or Z) is preserved in the teleported state. Teleporting in two different ways thereby corrects all errors.
I used state vector simulations to verify that these circuits correct all physical single-qubit errors by:
qubit.steane_qeccycle.I am not entirely certain that I am using/storing classical registers correctly, so @ciaranra please take a look.
Finally: the methods here write a
flagqubit to remember whether there were non-trivial syndromes. It may make sense to "guarantee" that this flag qubit is set correctly and remove this suggestive comment. Thoughts?