qiskit_qm_provider.utils.compilation.qua_script.get_qua_script¶
- get_qua_script(backend: QMBackend, circuit: QuantumCircuit, param_table: Mapping[Any, Any] | None = None) str[source][source]¶
Compile a circuit on its own and return the QUA script that would run, to inspect its pulse sequence.
The circuit is compiled outside any QUA program, so no
ParameterTableorParametercan be declared for it: each circuit input instead starts from a plain Python value. Inputs missing fromparam_tablestart from a typed zero (0.0,0orFalse, or a list of those for an array input), so a parameterized circuit needs no bindings at all. To compile with real streamed parameters, callquantum_circuit_to_qua()insidewith program():instead.- Parameters:
backend – The QM backend (used for quantum_circuit_to_qua and generate_config).
circuit – The transpiled QuantumCircuit to compile to QUA.
param_table – Optional Python values for some circuit inputs, keyed like a
quantum_circuit_to_quadict (circuit objects or their names).
- Returns:
The QUA script string (Python source of the program that would be executed).
- Raises:
TypeError – if
param_tableis not a dict (a table cannot be declared outside a QUA program).