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

Add an optional CompilationTargetGateset postprocessor to contract the circuit #6433

Merged
merged 9 commits into from
Feb 3, 2024

Conversation

NoureldinYosri
Copy link
Collaborator

@NoureldinYosri NoureldinYosri commented Jan 30, 2024

fixes #6422 as suggested by @tanujkhattar #6422 (comment)

calling optimize_for_target_gateset with gateset=cirq.CZTargetGateset(preserve_moment_structure=False) and max_num_passes equal a value >= 2 or None) produces the desired result

Copy link

codecov bot commented Jan 30, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (5dd05bf) 97.81% compared to head (089bc2a) 97.81%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #6433   +/-   ##
=======================================
  Coverage   97.81%   97.81%           
=======================================
  Files        1111     1111           
  Lines       97167    97198   +31     
=======================================
+ Hits        95047    95078   +31     
  Misses       2120     2120           

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

@pavoljuhas pavoljuhas self-requested a review January 31, 2024 18:15
@CirqBot CirqBot added the size: M 50< lines changed <250 label Feb 1, 2024
Copy link
Collaborator

@tanujkhattar tanujkhattar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM % comments

@tanujkhattar tanujkhattar self-assigned this Feb 2, 2024
@NoureldinYosri NoureldinYosri enabled auto-merge (squash) February 3, 2024 00:07
@NoureldinYosri NoureldinYosri merged commit f2c6f3c into main Feb 3, 2024
37 checks passed
harry-phasecraft pushed a commit to PhaseCraft/Cirq that referenced this pull request Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: M 50< lines changed <250
Projects
None yet
Development

Successfully merging this pull request may close these issues.

optimize_for_target_gateset returns a non-optimal circuit
3 participants