Fix #168: Remove Pauli measurements#498
Conversation
This commit implements the algorithm described in [BMBdF+21], Theorem 4.12 in Section 4.3: Removing Clifford vertices. The new method `Pattern.remove_pauli_measurements` removes almost all Pauli measurements on non-input nodes, and all of them if the pattern has flow, fixing TeamGraphix#168. [BMBdF+21] Miriam Backens, Hector Miller-Bakewell, Giovanni de Felice, Leo Lobski, and John van de Wetering, There and back again: A circuit extraction tale, Quantum, 2021, https://doi.org/10.22331/q-2021-03-25-421
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #498 +/- ##
==========================================
- Coverage 89.57% 88.91% -0.66%
==========================================
Files 48 49 +1
Lines 7039 7111 +72
==========================================
+ Hits 6305 6323 +18
- Misses 734 788 +54 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
matulni
left a comment
There was a problem hiding this comment.
Thanks a lot for this nice piece of work @thierry-martinez ! Code is super clear and new tool very useful!
Now that remove_pauli_nodes will become a fundamental part of the workflow, I'm even more unhappy that the transformation Pattern -> OpenGraph or Pattern -> XZCorrections does not preserve information about the LC fragment. Maybe it may be worth thinking about this...
…`PauliPushingCut`
CI fails with version 11.0.9: https://github.com/TeamGraphix/graphix/actions/runs/25607609586/job/75172334745 CI succeeds with version 10.33.4: https://github.com/TeamGraphix/graphix/actions/runs/25476469782/job/74750924624
Incorporate Pauli results
matulni
left a comment
There was a problem hiding this comment.
LGTM!
Thanks for the nice work
mgarnier59
left a comment
There was a problem hiding this comment.
Overall it looks very good. The code is extremely clean. I have a couple of questions concerning the exact procedure but it looks ready to merge!
This commit implements the algorithm described in [BMBdF+21], Theorem 4.12 in Section 4.3: Removing Clifford vertices.
The new method
Pattern.remove_pauli_measurementsremoves almost all Pauli measurements on non-input nodes, and all of them if the pattern has flow, fixing #168.[BMBdF+21] Miriam Backens, Hector Miller-Bakewell, Giovanni de Felice, Leo Lobski, and John van de Wetering, There and back again: A circuit extraction tale, Quantum, 2021,
https://doi.org/10.22331/q-2021-03-25-421