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

Bug/607 fidelity statevector kernel cannot be pickled (backport #778) #782

Merged
merged 1 commit into from
Mar 1, 2024

Conversation

mergify[bot]
Copy link
Contributor

@mergify mergify bot commented Feb 29, 2024

This is an automatic backport of pull request #778 done by Mergify.


Mergify commands and options

More conditions and actions can be found in the documentation.

You can also trigger Mergify actions by commenting on this pull request:

  • @Mergifyio refresh will re-evaluate the rules
  • @Mergifyio rebase will rebase this PR on its base branch
  • @Mergifyio update will merge the base branch into this PR
  • @Mergifyio backport <destination> will backport this PR on <destination> branch

Additionally, on Mergify dashboard you can:

  • look at your merge queues
  • generate the Mergify configuration with the config editor.

Finally, you can contact us on https://mergify.com

* Made fidelity_statevector_kernel picklable

Added a new param to store cache size and a custom __getstate__  and __setstate__ to handle removing and re-initliasing the lru cache during pickle/unpickling respectively.

* updated notes

* name changes

* spell corrections

* Updated description

* Added unittest for pickling

* Spelling changes

* Making error messages clearer

* Spelling -_-

* Update releasenotes/notes/fix-fid_statevector_kernel-pickling-b7fa2b13a15ec9c6.yaml

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Update .gitignore

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Update test/kernels/test_fidelity_statevector_kernel.py

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Update qiskit_machine_learning/kernels/fidelity_statevector_kernel.py

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Update test/kernels/test_fidelity_statevector_kernel.py

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Update qiskit_machine_learning/kernels/fidelity_statevector_kernel.py

Co-authored-by: Declan Millar <declan.millar@ibm.com>

* Added Any class

---------

Co-authored-by: M. Emre Sahin <40424147+OkuyanBoga@users.noreply.github.com>
Co-authored-by: Declan Millar <declan.millar@ibm.com>
Co-authored-by: Anton Dekusar <62334182+adekusar-drl@users.noreply.github.com>
(cherry picked from commit c59063a)
@coveralls
Copy link

Pull Request Test Coverage Report for Build 8099320004

Warning: This coverage report may be inaccurate.

This pull request's base commit is no longer the HEAD commit of its target branch. This means it includes changes from outside the original pull request, including, potentially, unrelated coverage changes.

Details

  • 9 of 9 (100.0%) changed or added relevant lines in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.03%) to 92.665%

Totals Coverage Status
Change from base Build 8099036952: 0.03%
Covered Lines: 1895
Relevant Lines: 2045

💛 - Coveralls

@edoaltamura edoaltamura merged commit 5b341e8 into stable/0.7 Mar 1, 2024
16 checks passed
@mergify mergify bot deleted the mergify/bp/stable/0.7/pr-778 branch March 1, 2024 11:41
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