-
Notifications
You must be signed in to change notification settings - Fork 615
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
default.qutrit
now returns integer samples (#6385)
**Context:** `default.qutrit` was returning float samples instead of integer samples. This causes errors when jitting, as the jit boundary is extremely sensitive to types and shapes. **Description of the Change:** Only casts samples to float if the `obs` is not a measurement process. I also add a test to the device test suite for `qml.sample`. Though the device test suite does not apply to `default.qutrit`, this test will still help validate that sample returns are working as expected on devices. **Benefits:** **Possible Drawbacks:** **Related GitHub Issues:** Fixes #6384 [sc-75867]
- Loading branch information
Showing
4 changed files
with
34 additions
and
1 deletion.
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