-
Notifications
You must be signed in to change notification settings - Fork 40
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 issue with adjoint-jacobian of adjoint ops #996
Conversation
Hello. You may have forgotten to update the changelog!
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #996 +/- ##
==========================================
- Coverage 97.76% 95.85% -1.92%
==========================================
Files 231 231
Lines 36707 36190 -517
==========================================
- Hits 35886 34689 -1197
- Misses 821 1501 +680 ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
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.
LGTM! @astralcai could you check your PR against the latest changes?
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.
Looks good! Thanks!
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.
Looks good! Thank you for fixing this!
LGTM! Thanks @josephleekl for completing the PR 🙌 |
Before submitting
Please complete the following checklist when submitting a PR:
All new features must include a unit test.
If you've fixed a bug or added code that should be tested, add a test to the
tests
directory!All new functions and code must be clearly commented and documented.
If you do make documentation changes, make sure that the docs build and
render correctly by running
make docs
.Ensure that the test suite passes, by running
make test
.Add a new entry to the
.github/CHANGELOG.md
file, summarizing thechange, and including a link back to the PR.
Ensure that code is properly formatted by running
make format
.When all the above are checked, delete everything above the dashed
line and fill in the pull request template.
Context:
The Adjoint-Jacobian of adjoint operations in Lightning is incorrectly returning
0
if we don't decompose them. This issue stems from the ops serialization logic in Python, which mistakenly assumesinverse = False
for all operations. This PR fixes the issue so that we can addAdjoint(op)
for all supportedop
to the frozenset of devices operations that will also fix the blocker for merging PR #988.Description of the Change:
Benefits:
Possible Drawbacks:
Related GitHub Issues:
[sc-78336]