-
Notifications
You must be signed in to change notification settings - Fork 61
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
Noise Channels with the CliffordSimulator
#1183
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1183 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 68 68
Lines 9906 9919 +13
=========================================
+ Hits 9906 9919 +13
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
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.
I think this is missing an explicit how-to in the docs of Pauli noise channels and Clifford simulation
def apply_clifford(self, backend, state, nqubits): | ||
return backend.apply_channel(self, state, nqubits) |
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.
This will break if one calls this method in any other scenario that isn't the Clifford backend acting on a symplectic matrix, right?
Maybe we should add a docstring explicitly mentioning that and/or raising an error when state
isn't a symplectic matrix and/or raising an error when backend
isn't Clifford
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, in principle, a user might instantiate a channel and call the apply_clifford
method on a state vector and with a backend that is not the ClffordBackend
, but the same is true for the standard apply
and apply_density_matrix
.
I don't think that's the way channels are intended to be used. Usually you just build the circuit put the channels you like and execute it. If an user wants for some reason to perform all the steps manually, then it's their responsibility to be aware of which backend and state object to use.
This PR adds support for noise channels to the
CliffordSimulator
.Checklist: