Skip to content

🐛 Regression using qiskit>=0.45. #334

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

Closed
burgholzer opened this issue Nov 20, 2023 · 1 comment
Closed

🐛 Regression using qiskit>=0.45. #334

burgholzer opened this issue Nov 20, 2023 · 1 comment
Assignees
Labels
bug Something isn't working c++ Anything related to C++ code

Comments

@burgholzer
Copy link
Member

burgholzer commented Nov 20, 2023

Environment information

  • OS: any
  • Python version: any
  • mqt-qcec version: latest (but could be dating back a bit)
  • qiskit version: 0.45.0 (downgrading to qiskit<0.45 resolves the problem)

Description

While looking through the example docs, I noticed that the very simple example shown in the documentation for verifying compilation flows is broken as it reports not_equivalent and emits a warning that both circuits do not operate on the same number of qubits.

After checking the example locally, it turns out that this is a regression in the latest qiskit version. Downgrading qiskit solves the problem. Two things that could be at fault here are the new Singleton Gates or some changes in the _layout attribute.

Expected behavior

Circuits should be considered equivalent (as they always have been).

How to Reproduce

from qiskit import QuantumCircuit, transpile
from qiskit.providers.fake_provider import FakeLondon

from mqt import qcec

circ = QuantumCircuit(3)
circ.x(2)
circ.h(range(3))
circ.ccx(0, 1, 2)
circ.h(range(2))
circ.x(range(2))
circ.h(1)
circ.cx(0, 1)
circ.h(1)
circ.x(range(2))
circ.h(range(2))
circ.measure_all()

optimization_level = 1
circ_comp = transpile(circ, backend=FakeLondon(), optimization_level=optimization_level)

print(qcec.verify_compilation(circ, circ_comp, optimization_level=optimization_level))
@burgholzer burgholzer added bug Something isn't working c++ Anything related to C++ code labels Nov 20, 2023
@burgholzer burgholzer self-assigned this Nov 20, 2023
@burgholzer burgholzer moved this to Todo in MQT Nov 20, 2023
@burgholzer burgholzer moved this to Todo in MQT Verification Nov 20, 2023
@burgholzer burgholzer changed the title 🐛 Something with permutation inference is broken 🐛 Regression using qiskit>=0.45. Nov 20, 2023
@burgholzer
Copy link
Member Author

This seems to have resolved on its own as I can no longer reproduce it and the documentation now also prints equivalent again.

@github-project-automation github-project-automation bot moved this from Todo to Done in MQT Dec 8, 2023
@github-project-automation github-project-automation bot moved this from Todo to Done in MQT Verification Dec 8, 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 c++ Anything related to C++ code
Projects
None yet
Development

No branches or pull requests

1 participant