Skip to content
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

Fix dd issue in calling PauliString.after. #6943

Merged
merged 3 commits into from
Jan 14, 2025

Conversation

babacry
Copy link
Collaborator

@babacry babacry commented Jan 11, 2025

Previous dd function would crash for circuits with PhXZ(a=0.25,x=-1,z=0) gate, e.g.,

   a: ───H───────PhXZ(a=0.25,x=-1,z=0)───────@───
                                             │
   b: ───H───H───H───────────────────────H───X───

in calling PauliString.after(ops) function. It is due to a known issue of decomposition.

In the PR:

  1. Force ops passed to PauliString in the format of CliffordGate.on(ops).
  2. Test cases are added to make sure the fix works.

Tracking issue: #6939

Copy link

codecov bot commented Jan 11, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 97.86%. Comparing base (988ecbc) to head (7deb8a8).
Report is 9 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6943   +/-   ##
=======================================
  Coverage   97.86%   97.86%           
=======================================
  Files        1084     1084           
  Lines       94408    94420   +12     
=======================================
+ Hits        92393    92406   +13     
+ Misses       2015     2014    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@babacry babacry marked this pull request as ready for review January 14, 2025 01:45
@babacry babacry requested review from vtomole and a team as code owners January 14, 2025 01:45
@babacry babacry requested a review from fdmalone January 14, 2025 01:46
@NoureldinYosri NoureldinYosri enabled auto-merge (squash) January 14, 2025 22:39
@NoureldinYosri NoureldinYosri merged commit 0361a81 into quantumlib:main Jan 14, 2025
35 checks passed
@babacry babacry deleted the dd_issue branch February 28, 2025 01:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants