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

Support parameter broadcasting with GlobalPhase #5923

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

dwierichs
Copy link
Contributor

@dwierichs dwierichs commented Jul 1, 2024

Context:
GlobalPhase does not support broadcasting yet.

Description of the Change:
Introduce broadcasting to GlobalPhase, using the code from PauliRot with set(pauli_word) == {"I"}.
The latter falls back to the GlobalPhase implementation.

Also fixes a small bug where the global phase returned by one_qubit_decomposition gains a broadcasting dimension even if the input matrix does not have one.

Benefits:
Broadcasting support & Bug fix

Possible Drawbacks:

Related GitHub Issues:
Implements #5815

[sc-65316]

Copy link

codecov bot commented Jul 1, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.66%. Comparing base (e74c9bf) to head (29cc5c5).

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5923      +/-   ##
==========================================
- Coverage   99.67%   99.66%   -0.01%     
==========================================
  Files         425      425              
  Lines       40772    40479     -293     
==========================================
- Hits        40640    40345     -295     
- Misses        132      134       +2     

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

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.

None yet

1 participant