iqm.iqm_client.transpile.transpile_insert_moves

iqm.iqm_client.transpile.transpile_insert_moves#

iqm.iqm_client.transpile.transpile_insert_moves(circuit, arch, existing_moves=None, qubit_mapping=None)#

Transpile method that inserts moves to the circuit according to a given architecture specification. The function does nothing if the given architecture specification does not support move Instructions. Note that this method assumes that the circuit is already transpiled to a coupling map/architecture where the resonator has been abstracted away, i.e. the edges of the coupling map that contain resonators are replaced by edges between the other qubit and all qubits that can be moved to that resonator.

Parameters:
  • circuit (Circuit) – The circuit to add Move instructions to.

  • arch (QuantumArchitectureSpecification) – Restrictions of the target device

  • existing_moves (ExistingMoveHandlingOptions | None) –

    Specifies how to deal with existing move instruction,

    If None, the function will use ExistingMoveHandlingOptions.REMOVE with a user warning if there are move instructions in the circuit. Defaults to None.

    qubit_mapping: Mapping of logical qubit names to physical qubit names.

    Can be set to None if all circuits already use physical qubit names.

  • qubit_mapping (dict[str, str] | None) –

Return type:

Circuit