-
Notifications
You must be signed in to change notification settings - Fork 192
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
Bosonic engine results #546
Conversation
- Allows for multiple shots for measurements (new test) - Raises an error if symbolic non-Gaussian state prep is attempted
Defines the BosonicEngine class Co-Authored-By: ilan-tz <57886357+ilan-tz@users.noreply.github.com> Co-Authored-By: Josh Izaac <josh@iza.ac> Co-Authored-By: Nicolas Quesada <991946+nquesada@users.noreply.github.com>
Ancilla samples are produced by ancillary modes used for measurement-based gates
Updates/adds new integration tests to apply to the bosonic backend
Codecov Report
@@ Coverage Diff @@
## master #546 +/- ##
==========================================
+ Coverage 98.19% 98.22% +0.03%
==========================================
Files 76 76
Lines 8329 8360 +31
==========================================
+ Hits 8179 8212 +33
+ Misses 150 148 -2
Continue to review full report at Codecov.
|
boosts code coverage
Deletes the run method from the BosonicEngine, since it can be inherited from LocalEngine with a minimal change.
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.
@elib20 Looking good, no major blockers! 👍 Left some questions and suggestions, curious to get those addressed and could go for another round.
Co-authored-by: antalszava <antalszava@gmail.com>
- discovered and fixed bug in array dimension of returned samples - makes tests more readable - adds ancilla information to string of Results __repr__ - adds BosonicEngine to docs Co-Authored-By: antalszava <24476053+antalszava@users.noreply.github.com>
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.
It's getting late, but I'll have another look tomorrow unless you've merged it already. Leaving the few comments I had so far. 💯
Co-Authored-By: Theodor <6934626+thisac@users.noreply.github.com>
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.
Co-authored-by: antalszava <antalszava@gmail.com>
Co-Authored-By: antalszava <24476053+antalszava@users.noreply.github.com>
…strawberryfields into bosonic-engine_results
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.
Looks great from my side as well. Don't forget to update the changelog, if you plan to do that in this PR. 🙂 💯
@@ -555,7 +679,6 @@ def test_Pgate_decomp_equal(self, setup_eng, s, tol): | |||
eng.run(prog) | |||
assert np.all(eng.backend.is_vacuum(tol)) | |||
|
|||
@pytest.mark.backends("fock","tf","gaussian") |
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.
Are these removed since they run on all backends?
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.
Yes! The conftest file defaults to run tests on all backends.
Context: The bosonic backend is useful for simulating bosonic qubits.
Description of the Change:
Benefits:
Running Programs on the bosonic backend from the frontend using an engine.
Possible Drawbacks:
Related GitHub Issues: