Open BankNatchapol opened 3 weeks ago
Circuits after Transpilation should give similar result, but not.
from qiskit.quantum_info import Statevector from qiskit.compiler import transpile with open('acircuit.qpy', 'rb') as handle: qc = qpy.load(handle) wo = transpile(qc, basis_gates=['cz', 'swap', 'cx', 'tdg', 's', 'sdg', 'h', 'rz'], optimization_level=1)[0] w = transpile(wo, basis_gates=['cz', 'swap', 'cx', 'tdg', 's', 'sdg', 'h', 'rz'], optimization_method="zxpass") print(Statevector(wo)) print(Statevector(w))
ill attach acircuit.qpy acircuit.zip
acircuit.qpy
the statevector should be the same.
If it's correct, please guide me how to make the statevector output to be the same. Thank you in advance.
We don't define an optimization_method called zxpass; you must be pulling that in from some external plugin.
optimization_method
zxpass
Environment
What is happening?
Circuits after Transpilation should give similar result, but not.
How can we reproduce the issue?
ill attach
acircuit.qpy
acircuit.zipWhat should happen?
the statevector should be the same.
Any suggestions?
If it's correct, please guide me how to make the statevector output to be the same. Thank you in advance.