-
Notifications
You must be signed in to change notification settings - Fork 586
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make process_samples on SampleMP jit-compatible with Tracer indices (#…
…6211) **Context:** There is a use case in catalyst (currently a WIP, sampling an observable using `measurements_from_samples` to diagonalize everything) that results in `indices` in the `process_samples` function being an abstract `Tracer`, and then things break that don't need to. **Description of the Change:** Update the jax `take` dispatch in `qml.math` to cast indices to a jax array instead of a vanilla numpy array
- Loading branch information
1 parent
713a33d
commit 40195fd
Showing
4 changed files
with
85 additions
and
73 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