-
Notifications
You must be signed in to change notification settings - Fork 33
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
Migrate entanglement forging to Qiskit Nature 0.5.0 #83
Conversation
There is also #59. |
circuit_knitting_toolbox/entanglement_forging/cholesky_decomposition.py
Outdated
Show resolved
Hide resolved
circuit_knitting_toolbox/entanglement_forging/cholesky_decomposition.py
Outdated
Show resolved
Hide resolved
circuit_knitting_toolbox/entanglement_forging/entanglement_forging_ground_state_solver.py
Outdated
Show resolved
Hide resolved
circuit_knitting_toolbox/entanglement_forging/entanglement_forging_knitter.py
Outdated
Show resolved
Hide resolved
circuit_knitting_toolbox/entanglement_forging/entanglement_forging_knitter.py
Outdated
Show resolved
Hide resolved
Pull Request Test Coverage Report for Build 4702934575Warning: 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
💛 - Coveralls |
Yes, that's the other option that allows us to avoid breaking the tutorials. 🙂 I'd be fine with removing that notebook in a subsequent PR so that we can easily revert that PR when the bug is fixed. I'm sure we could also figure out restoring it if made part of this PR, too. |
Now that qiskit-community/qiskit-nature#1142 has been merged, our "development version tests" are going to fail on `main` until #83 is merged. This change fixes CI immediately by excluding the development version of qiskit-nature from these tests. This change should be reverted as part of #83 before it is merged.
Now that qiskit-community/qiskit-nature#1142 has been merged, our "development version tests" are going to fail on `main` until #83 is merged. This change fixes CI immediately by excluding the development version of qiskit-nature from these tests. This change should be reverted as part of #83 before it is merged.
releasenotes/notes/migrate-to-qiskit-nature-0.5.0-96e90cd48f36d731.yaml
Outdated
Show resolved
Hide resolved
tox.ini
Outdated
@@ -35,7 +35,7 @@ deps = | |||
extras = | |||
notebook-dependencies | |||
commands = | |||
pytest --nbmake --nbmake-timeout=3000 {posargs} docs/ | |||
pytest --nbmake --nbmake-timeout=3000 {posargs} --ignore-glob=*forging*serverless* docs/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should put a notice at the top of this notebook, saying that it is currently broken and point to issue #108.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do, will include #413 from serverless as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This tutorial works now. I updated the code, and Paul had also updated the serverless usage. I'm not sure what fixed it, because the error I encountered before implementing my fix was different than before.
Anyway, I'm returning this to its original state
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haha, this is great ! 😁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Qiskit/qiskit-serverless#413 (comment)
Yes! I updated the serverless issue here, and I'll probably recommend they close it soon when this is passing CI
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is still broken in 0.6.0 but is fixed in 0.5.0. I think I will move the ignore-glob into the Actions workflow and out of tox, since it only affects the one workflow (I think/hope)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will add a note to the serverless notebook as discussed before
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could consider pinning Qiskit nature < 0.6 in the notebook-dependencies only.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could consider pinning Qiskit nature < 0.6 in the notebook-dependencies only.
I like that. Let's do that instead of ignoring the notebook, and I'll leave the warning in the notebook for now?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds perfect to me (as long as CI passes 😂). In particular, I think it makes sense to keep the warning in the notebook, in case people are using the tutorial in a setting where they did not install using [notebook-dependencies]
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 🥳
Fixes #89
Fixes #94
This PR removes the deprecated Qiskit Nature API calls from the entanglement forging source code.
This PR removes support for deprecated Qiskit Nature classes as inputs. See the release note for more details.
Considerations/Stray Thoughts:
ElectronicStructureProblem
class in Nature 0.6.0 and quantum serverless. The serverless folks probably need to add support for a new class or two to support serialization of the new classes coming from Nature. I've made an issue here. I've turned off testing of this notebook for now. I think that's the best we can do until a QServerless fix is available.Tasks before merging:
Make issue for adding the serverless tutorial back to the development workflow in CI when quantum serverless fix is available.
Ensure MO coeff handling is done in the most reasonable way. Work with Nature devs to review.
Update rst files in docs with new Nature API calls
merge in latest
main
and revert Temporarily disable qiskit-nature development version test #120 on this branch