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 gate powering with ** #9030

Merged
merged 5 commits into from
Jan 11, 2023
Merged

support gate powering with ** #9030

merged 5 commits into from
Jan 11, 2023

Conversation

kevinsung
Copy link
Contributor

Summary

Fixes #7473

Details and comments

@kevinsung kevinsung requested a review from a team as a code owner October 28, 2022 20:54
@qiskit-bot
Copy link
Collaborator

Thank you for opening a new pull request.

Before your PR can be merged it will first need to pass continuous integration tests and be reviewed. Sometimes the review process can be slow, so please be patient.

While you're waiting, please feel free to review other open PRs. While only a subset of people are authorized to approve pull requests for merging, everyone is encouraged to review open pull requests. Doing reviews helps reduce the burden on the core team and helps make the project's code better for everyone.

One or more of the the following people are requested to review this:

  • @Qiskit/terra-core

@coveralls
Copy link

coveralls commented Oct 28, 2022

Pull Request Test Coverage Report for Build 3892541916

  • 2 of 2 (100.0%) changed or added relevant lines in 1 file are covered.
  • 5 unchanged lines in 2 files lost coverage.
  • Overall coverage increased (+0.04%) to 84.642%

Files with Coverage Reduction New Missed Lines %
src/sabre_swap/layer.rs 2 98.95%
qiskit/pulse/library/waveform.py 3 91.49%
Totals Coverage Status
Change from base Build 3892057177: 0.04%
Covered Lines: 64481
Relevant Lines: 76181

💛 - Coveralls

@mtreinish mtreinish added the Changelog: New Feature Include in the "Added" section of the changelog label Oct 29, 2022
@mtreinish mtreinish added this to the 0.23.0 milestone Oct 29, 2022
Copy link
Member

@jakelishman jakelishman left a comment

Choose a reason for hiding this comment

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

I'm happy to add this as a convenience magic method, especially given that the power function already exists. I think we ought to avoid modifying tests of other behaviour when adding the functionality, though - it's pretty minor here, but in general, changes to existing tests when a new feature is added usually indicates that some public-facing semantics changed, which is something we don't want.

test/python/circuit/test_gate_power.py Outdated Show resolved Hide resolved
test/python/circuit/test_gate_power.py Outdated Show resolved Hide resolved
@kevinsung
Copy link
Contributor Author

Anything else?

jakelishman
jakelishman previously approved these changes Jan 11, 2023
Copy link
Member

@jakelishman jakelishman left a comment

Choose a reason for hiding this comment

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

Looks good, thanks!

jakelishman
jakelishman previously approved these changes Jan 11, 2023
Copy link
Member

@jakelishman jakelishman left a comment

Choose a reason for hiding this comment

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

Now with the merge conflict fixed.

@mergify mergify bot merged commit 7ed5de3 into Qiskit:main Jan 11, 2023
@kevinsung kevinsung deleted the gate-power branch January 11, 2023 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: New Feature Include in the "Added" section of the changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support gate exponentiation by Gate ** x instead of only Gate.power(x)
5 participants