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

Bug when using Gate.decompose on controlled gates #1585

Open
renatomello opened this issue Feb 12, 2025 · 0 comments · May be fixed by #1586
Open

Bug when using Gate.decompose on controlled gates #1585

renatomello opened this issue Feb 12, 2025 · 0 comments · May be fixed by #1586
Assignees
Labels
bug Something isn't working transpiler
Milestone

Comments

@renatomello
Copy link
Contributor

Decomposition of controlled gates not only loses the control information after .decompose(), but also acts on wrong qubits.

In [7]: from qibo import Circuit, gates
   ...: 
   ...: circuit = Circuit(3)
   ...: circuit.add(gates.U3(0, 0.1, 0.2, 0.3).controlled_by(1, 2).decompose())
   ...: circuit.draw()
0: ────────────────
1: ─RZSXRZSXRZ2: ────────────────
@renatomello renatomello added this to the Qibo 0.2.16 milestone Feb 12, 2025
@renatomello renatomello added bug Something isn't working transpiler labels Feb 12, 2025
@renatomello renatomello linked a pull request Feb 12, 2025 that will close this issue
4 tasks
@renatomello renatomello self-assigned this Feb 12, 2025
@scarrazza scarrazza modified the milestones: Qibo 0.2.16, Qibo 0.2.17 Feb 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working transpiler
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants