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 the bug primitives cannot handle circuits with ndarray parameters #9103

Merged
merged 3 commits into from
Nov 17, 2022

Conversation

ikkoham
Copy link
Contributor

@ikkoham ikkoham commented Nov 9, 2022

Summary

Fixes #9102

Details and comments

@ikkoham ikkoham added stable backport potential The bug might be minimal and/or import enough to be port to stable Changelog: Bugfix Include in the "Fixed" section of the changelog mod: primitives Related to the Primitives module labels Nov 9, 2022
@ikkoham ikkoham requested review from a team and t-imamichi as code owners November 9, 2022 03:20
@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:

@ikkoham ikkoham added this to the 0.22.3 milestone Nov 9, 2022
@coveralls
Copy link

coveralls commented Nov 9, 2022

Pull Request Test Coverage Report for Build 3484725849

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

Files with Coverage Reduction New Missed Lines %
src/sabre_swap/layer.rs 2 98.95%
Totals Coverage Status
Change from base Build 3482770785: 0.04%
Covered Lines: 62614
Relevant Lines: 74010

💛 - Coveralls

@kevinsung
Copy link
Contributor

This PR indeed fixes #9102 for most practical use cases. However, as long as Gates can have unhashable parameters (besides np.ndarray) the issue is not truly fixed.

@t-imamichi
Copy link
Member

Shall I merge this PR?

@mergify mergify bot merged commit 599b663 into Qiskit:main Nov 17, 2022
mergify bot pushed a commit that referenced this pull request Nov 17, 2022
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
(cherry picked from commit 599b663)

# Conflicts:
#	qiskit/primitives/utils.py
mergify bot added a commit that referenced this pull request Dec 2, 2022
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
(cherry picked from commit 599b663)

# Conflicts:
#	qiskit/primitives/utils.py

Co-authored-by: Ikko Hamamura <ikkoham@users.noreply.github.com>
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Cryoris pushed a commit to Cryoris/qiskit-terra that referenced this pull request Jan 12, 2023
Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: Bugfix Include in the "Fixed" section of the changelog mod: primitives Related to the Primitives module stable backport potential The bug might be minimal and/or import enough to be port to stable
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Sampler fails on gates with unhashable parameters
5 participants