You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# 1.2.4 and main branch
┌──────────────────┐┌──────────────────┐
q: ┤ exp(-it Z)(γ[0]) ├┤ exp(-it X)(β[0]) ├
└──────────────────┘└──────────────────┘
# 1.3.0rc1
Traceback (most recent call last):
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passmanager.py", line 464, in wrapper
return meth(*meth_args, **meth_kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passmanager.py", line 226, in run
return super().run(
^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/passmanager/passmanager.py", line 232, in run
_run_workflow(program=program, pass_manager=self, callback=callback, **kwargs)
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/passmanager/passmanager.py", line 292, in _run_workflow
passmanager_ir, final_state = flow_controller.execute(
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/passmanager/base_tasks.py", line 218, in execute
passmanager_ir, state = next_task.execute(
^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/basepasses.py", line 195, in execute
new_dag, state = super().execute(
^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/passmanager/base_tasks.py", line 98, in execute
ret = self.run(passmanager_ir)
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 279, in run
out_dag = self._run(dag, tracker, context, use_ancillas=True, top_level=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 606, in _synthesize_operation
synthesized = self._run(
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 606, in _synthesize_operation
synthesized = self._run(
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 606, in _synthesize_operation
synthesized = self._run(
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 606, in _synthesize_operation
synthesized = self._run(
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 606, in _synthesize_operation
synthesized = self._run(
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 379, in _run
synthesized, synthesized_context = self._synthesize_operation(
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 570, in _synthesize_operation
synthesized = self._get_custom_definition(operation, indices)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passes/synthesis/high_level_synthesis.py", line 655, in _get_custom_definition
raise TranspilerError(f"HighLevelSynthesis was unable to synthesize {inst}.")
qiskit.transpiler.exceptions.TranspilerError: "HighLevelSynthesis was unable to synthesize Instruction(name='u', num_qubits=1, num_clbits=0, params=[0.0, 0.0, ParameterExpression(2.0*γ[0])])."
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/Users/ima/tasks/4_2024/qiskit/terra/tmp/synth.py", line 9, in <module>
qc2 = pm.run(qc)
^^^^^^^^^^
File "/Users/ima/envs/qiskit130/lib/python3.12/site-packages/qiskit/transpiler/passmanager.py", line 466, in wrapper
raise TranspilerError(ex.message) from ex
qiskit.transpiler.exceptions.TranspilerError: "HighLevelSynthesis was unable to synthesize Instruction(name='u', num_qubits=1, num_clbits=0, params=[0.0, 0.0, ParameterExpression(2.0*γ[0])])."
Any suggestions?
No response
The text was updated successfully, but these errors were encountered:
t-imamichi
changed the title
HighLevelSynthesis raises an error with 1.3.0rc1 (not 1.2.4 and main branch)HighLevelSynthesis raises an error with 1.3.0rc1 (no error with 1.2.4 and main branch)
Nov 8, 2024
The issue seems to be that HLS sees that we have a plugin available for PauliEvolution and calls that, even though it is already in the basis_gates. We're looking into it.
As a workaround until then, does it work for you to use
qc=QAOAAnsatz(...., flatten=True)
or just a manual decompose, to remove that outer wrapping layer, instead of calling HLS?
Environment
What is happening?
HighLevelSynthesis
raises an error with only 1.3.0rc1. 1.2.4 and main branch work fine.How can we reproduce the issue?
What should happen?
Any suggestions?
No response
The text was updated successfully, but these errors were encountered: