-
Notifications
You must be signed in to change notification settings - Fork 22
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
[WIP] Added a simple generator for gate-dependent depolarizing noise. #180
base: master
Are you sure you want to change the base?
Conversation
return pauli_kraus_map(probabilities) | ||
|
||
|
||
def generate_depolarizing_noise_model(qc: QuantumComputer, show_progress_bar: bool = True, |
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.
Is it reasonably sufficient (and/or fairly standard) to only consider a depolarizing noise model? What about things like cross-talk?
gates = gates_in_isa(qc.get_isa()) | ||
kraus_maps = [] | ||
for g in tqdm(gates, disable=not show_progress_bar): | ||
if g.name in ('RZ', 'I'): |
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.
Could these be subject to coherent errors?
combine_kraus_maps(noise_kraus, [matrix]), fidelity)) | ||
kraus_maps.append(km) | ||
|
||
return NoiseModel(kraus_maps, single_qubit_conf_matrices) |
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 it would also be worth adding a helper function that would convert the NoiseModel
here to a Program
or a set of pragma instructions that a user could append to their program, in order for the latter to feel the effects of the noise model.
Documentation, example notebook, and testing should be added before merging. I haven't yet tested for correctness.