-
Notifications
You must be signed in to change notification settings - Fork 629
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add support for arbitrary linear combination gradient recipes (#909)
* Have positive and negative multiplier and shift values * No print * Formatting * 3 element terms for grad_recipes; qubit okay; CV draft * CV for tape mode * Comments * Remove unused * Formatting * Solve casting by specifying dtype at creation * No casting needed for shifted * Update module docstring and Operation.grad_recipe docstring * Development guide update * Wording * Adding tests; adding error raised for unsupported logic for tape second-order CV case * No f strings * Update pennylane/qnodes/cv.py Co-authored-by: Josh Izaac <[email protected]> * Update pennylane/tape/tapes/cv_param_shift.py * Simplify using np.dot in CV param shift tape * Update tests/qnodes/test_qnode_cv.py Co-authored-by: Josh Izaac <[email protected]> * get_parameter_shift in tape mode as per Josh's suggestion; use that * Changelog * Update tests/tape/tapes/test_cv_param_shift.py Co-authored-by: Josh Izaac <[email protected]> * Update .github/CHANGELOG.md Co-authored-by: Tom Bromley <[email protected]> * merge in changes from 915 * Update pennylane/operation.py Co-authored-by: Tom Bromley <[email protected]> * Update grad recipe formulae as per Tom's suggestions * Update other formula in comment * CHANGELOG * Add rendering img url approach * Plus * Update pennylane/operation.py Co-authored-by: Tom Bromley <[email protected]> * Applying review suggestions * Update doc/development/plugins.rst * Update pennylane/operation.py * equation formatting fixes Co-authored-by: Josh Izaac <[email protected]> Co-authored-by: Tom Bromley <[email protected]>
- Loading branch information
1 parent
5e01b7f
commit 6cc25a8
Showing
12 changed files
with
263 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.