-
Notifications
You must be signed in to change notification settings - Fork 35
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
Add the support class for the Adjoint Jacobian to the new device #907
Merged
Merged
Changes from all commits
Commits
Show all changes
49 commits
Select commit
Hold shift + click to select a range
120bbed
include the new device base class
LuisAlfredoNu bdf4daa
add measurements
LuisAlfredoNu b05a6a4
State vector almos done
LuisAlfredoNu 5dac907
tmp commit
LuisAlfredoNu bfd0771
Solve prop issue
LuisAlfredoNu a1ff6c6
ready measurenment class for LGPU
LuisAlfredoNu a0cfb1d
print helps for measurements
LuisAlfredoNu f472471
Merge gpuNewAPI_simulate
LuisAlfredoNu c7ac82d
grammar correction
LuisAlfredoNu 6627913
cleaning code
LuisAlfredoNu 6290953
apply format
LuisAlfredoNu 219262b
delete usuless variables
LuisAlfredoNu bca1a74
delete prints
LuisAlfredoNu 0f8f957
Revert change in measurenment test
LuisAlfredoNu a9ccf62
Merge branch 'gpuNewAPI_backend' into gpuNewAPI_simulate
LuisAlfredoNu a99b6e8
Merge branch 'gpuNewAPI_backend' into gpuNewAPI_simulate
LuisAlfredoNu 0399f18
add simulate method
LuisAlfredoNu 23d5696
apply format
LuisAlfredoNu 585c313
Shuli suggestion
LuisAlfredoNu 5eee8eb
apply format
LuisAlfredoNu be3c6f7
Develop Jacobian
LuisAlfredoNu 7ff13b3
unlock the test for jacobian and adjoint-jacobian
LuisAlfredoNu 3cec8b1
apply format
LuisAlfredoNu 92089eb
Update pennylane_lightning/lightning_gpu/_mpi_handler.py
LuisAlfredoNu 196042a
Apply suggestions from code review Vinvent's comments
LuisAlfredoNu b4ed1ae
Vincent's comments
LuisAlfredoNu 695283b
Merge branch 'gpuNewAPI_simulate' of github.com:PennyLaneAI/pennylane…
LuisAlfredoNu 1729d06
apply format
LuisAlfredoNu 38ddbdb
Merge branch 'gpuNewAPI_simulate' into gpuNewAPI_AdjJaco
LuisAlfredoNu 5819efc
Apply suggestions from code review. Vincent's suggestion
LuisAlfredoNu 2dbc7db
review comments
LuisAlfredoNu 0630edf
apply format
LuisAlfredoNu 3fa8409
apply format
LuisAlfredoNu af16b8d
Ali suggestion 1
LuisAlfredoNu 0cb050f
add reset
LuisAlfredoNu 54afeb5
apply_basis_state as abstract in GPU
LuisAlfredoNu ac87663
apply format
LuisAlfredoNu 35270fb
Apply suggestions from code review Ali suggestion docs
LuisAlfredoNu f51cbb9
propagate namming suggestion
LuisAlfredoNu 29675e7
Merge branch 'gpuNewAPI_simulate' into gpuNewAPI_AdjJaco
LuisAlfredoNu 65e66e9
Apply suggestions from code review. Ali's suggestion 3
LuisAlfredoNu 0472fdd
solve errors with kokkos
LuisAlfredoNu 96728cb
apply format
LuisAlfredoNu 5901a64
Merge branch 'gpuNewAPI_simulate' into gpuNewAPI_AdjJaco
LuisAlfredoNu 112ead0
solve conflicts
LuisAlfredoNu 1acf4db
Merge branch 'gpuNewAPI_backend' into gpuNewAPI_AdjJaco
LuisAlfredoNu 87778d6
apply format
LuisAlfredoNu c493d47
solve issue with reset
LuisAlfredoNu faead9c
solve error with kokkos
LuisAlfredoNu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -62,15 +62,13 @@ def __init__( | |
num_wires, | ||
dtype=np.complex128, | ||
kokkos_args=None, | ||
sync=True, | ||
): # pylint: disable=too-many-arguments | ||
|
||
super().__init__(num_wires, dtype) | ||
|
||
self._device_name = "lightning.kokkos" | ||
|
||
self._kokkos_config = {} | ||
self._sync = sync | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. In LK, any method requires the var |
||
|
||
# Initialize the state vector | ||
if kokkos_args is None: | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -302,7 +302,6 @@ def __init__( # pylint: disable=too-many-arguments | |
shots=None, | ||
batch_obs=False, | ||
# Kokkos arguments | ||
sync=True, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The var |
||
kokkos_args=None, | ||
): | ||
if not self._CPP_BINARY_AVAILABLE: | ||
|
@@ -324,11 +323,10 @@ def __init__( # pylint: disable=too-many-arguments | |
|
||
# Kokkos specific options | ||
self._kokkos_args = kokkos_args | ||
self._sync = sync | ||
|
||
# Creating the state vector | ||
self._statevector = self.LightningStateVector( | ||
num_wires=len(self.wires), dtype=c_dtype, kokkos_args=kokkos_args, sync=sync | ||
num_wires=len(self.wires), dtype=c_dtype, kokkos_args=kokkos_args | ||
) | ||
|
||
if not LightningKokkos.kokkos_config: | ||
|
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.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
👍