pennylane
pennylane copied to clipboard
qutrit mixed state sampling
Context:
Necessary next step in qutrit_mixed device development, allows for sampling a quantum circuit on the mixed state. This will be necessary to simulate sampling a qutrit device.
Description of the Change:
Added functionality for sampling a qutrit mixed-state via the new sample_state and measure_with_samples functions.
Benefits: Allows for sampling a qutrit mixed-state, allowing for noisy qutrit simulation sampling
Possible Drawbacks: Abstracting for qubits and more generally qutrits may have added challenges and will require a refactor or copied code code-smell. Methods are not the fastest possible, optimizations can still be made.
Related GitHub Issues: N/A
Current state of sampling PR, I could remove it and make it closer to what is in default.qutrit. I plan to cut it into two to also include expval, var, ... . This however should be a good start to get what is most necessesary while also leaving abstractions to make it easy to include other functionality.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 99.63%. Comparing base (
a4f0fff) to head (9ee688a). Report is 1 commits behind head on master.
Additional details and impacted files
@@ Coverage Diff @@
## master #5082 +/- ##
==========================================
- Coverage 99.63% 99.63% -0.01%
==========================================
Files 400 401 +1
Lines 37156 37007 -149
==========================================
- Hits 37022 36872 -150
- Misses 134 135 +1
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@albi3ro @glassnotes @mudit2812 @trbromley I cleaned up this PR since measure is close to being merged. Hope you like it!
Measure has been merged, so this is ready for review.
Fixed broken tests. Should be good to go!
Thanks! @mudit2812 do you have the ability to merge in master to the PR branch so that we can do a final round of tests?
@trbromley I just noticed your message and merged it in :+1:
Thanks! @mudit2812 do you have the ability to merge in
masterto the PR branch so that we can do a final round of tests?
I will check on the next PR, but I think I should as I'm part of the org that owns the fork.