Skip to content
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

Support DepolarizingChannel for multiqubit gates #2584

Open
1 task done
ikkoham opened this issue Feb 4, 2025 · 0 comments
Open
1 task done

Support DepolarizingChannel for multiqubit gates #2584

ikkoham opened this issue Feb 4, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@ikkoham
Copy link
Contributor

ikkoham commented Feb 4, 2025

Required prerequisites

  • Search the issue tracker to check if your feature has already been mentioned or rejected in other issues.

Describe the feature

DepolarizingChannel can be defined for multiple qubits.
For example, the following code should work as expected:

import cudaq
cudaq.set_target("density-matrix-cpu")

depolarization_channel = cudaq.DepolarizationChannel(probability=0.3)

noise_model = cudaq.NoiseModel()
noise_model.add_all_qubit_channel("cx", depolarization_channel)

@cudaq.kernel
def test():
    q = cudaq.qvector(2)
    x(q[0])
    cx(q[0], q[1])

print(cudaq.sample(test, noise_model=noise_model))
@ikkoham ikkoham added the enhancement New feature or request label Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant