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

Two qubits unitary decomposition not working for identity #1069

Closed
Simone-Bordoni opened this issue Nov 1, 2023 · 0 comments · Fixed by #1055
Closed

Two qubits unitary decomposition not working for identity #1069

Simone-Bordoni opened this issue Nov 1, 2023 · 0 comments · Fixed by #1055
Assignees
Labels
bug Something isn't working
Milestone

Comments

@Simone-Bordoni
Copy link
Contributor

Simone-Bordoni commented Nov 1, 2023

two_qubit_decomposition in transpiler.unitary_decompositions (now it is still in qibolab) fails when decomposing Identity.
It fails in decomposing any matrix that is not creating entanglement between the qubits.

backend = NumpyBackend()
gate = gates.I(0,1)
matrix = gate.matrix(backend)
c = Circuit(2)
c.add(two_qubit_decomposition(0, 1, matrix))

error:
UnboundLocalError: cannot access local variable 'u4' where it is not associated with a value

@Simone-Bordoni Simone-Bordoni added the bug Something isn't working label Nov 1, 2023
@Simone-Bordoni Simone-Bordoni self-assigned this Nov 1, 2023
@Simone-Bordoni Simone-Bordoni linked a pull request Nov 1, 2023 that will close this issue
4 tasks
@scarrazza scarrazza added this to the Qibo 0.2.3 milestone Nov 7, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants