iqm.qiskit_iqm.qiskit_to_iqm.deserialize_instructions

iqm.qiskit_iqm.qiskit_to_iqm.deserialize_instructions#

iqm.qiskit_iqm.qiskit_to_iqm.deserialize_instructions(instructions: list[Instruction], qubit_name_to_index: dict[str, int], layout: Layout) QuantumCircuit#

Helper function to turn a list of IQM Instructions into a Qiskit QuantumCircuit.

Parameters:
  • instructions (list[Instruction]) – The gates in the circuit.

  • qubit_name_to_index (dict[str, int]) – Mapping from qubit names to their indices, as specified in a backend.

  • layout (Layout) – Qiskit representation of a layout.

Raises:

ValueError – Thrown when a given instruction is not supported.

Returns:

Qiskit circuit represented by the given instructions.

Return type:

QuantumCircuit