-
Notifications
You must be signed in to change notification settings - Fork 12
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
Error in Parameter Handling #256
Comments
Hi there, unfortunately, the error still persists in pytket-qiskit v0.50.0 with qiskit v1.0.2. However, the error message is now a bit different: It would be highly appreciated if you could have a look into this issue, since it currently prevents a smooth combination of compilation passes from both qiskit and tket within our MQT Predictor framework. |
Interestingly, when I try to convert the quantum circuit after the tket from qiskit import QuantumCircuit
from pytket.qasm import circuit_to_qasm_str
transformed_qc = QuantumCircuit.from_qasm_str(circuit_to_qasm_str(tket_qc)) I get a different error: |
Thank you for reporting this, I will take a look and try to understand what is going on |
Thanks a lot for that. I was wondering whether you already had the time to have a look? |
Hi @nquetschlich |
The issue in qiskit was caused by an updated and what we were trying in the conversion is not expected to work any more. I have updated that now and put out a release candidate. Can you please check if this solved all the issues you have? You can install it with |
Thanks a lot for fixing this issue. I tried it out and it works. |
Hi there,
when experimenting with compiling a parameterized quantum circuit partly with Qiskit and partly with TKET using the following example:
I face a
TypeError: could not cast expression to complex
error.Apparently, there is some error in the parameter handling in combination with
sympy
. When executingthe expression is apparently not real, although the symbolic representation can be reduced to a real number. Even a
assigned_expr._symbol_expr.evalf()
does not reduce theassigned_expr
and returns-0.5*(3.14159265358979 - 2*atan2(-0.841470984807895, 0.540302305868143))
. Maybe theatan2
causes the problem?I used Qiskit v0.45.3, pytket_qiskit v0.48.0 using python 3.11 under Mac OS v14.2.1.
The text was updated successfully, but these errors were encountered: