dqcnac.mapping.circuit_partitioning module
Circuit partitioning with metis.
- dqcnac.mapping.circuit_partitioning.circuit_partitioning(network: Network, circuit: qiskit.QuantumCircuit | qiskit.dagcircuit.DAGCircuit, graph: networkx.Graph | None = None, use_pre_pass=False, max_gates_in_a_group: int = 1) dict[int, int][source]
Compute unequal partitions of circuit over the network to minimize communication between different nodes
- Parameters:
network – the network
circuit – the circuit to partition
graph – a weighted graph representing the circuit
use_pre_pass – a boolean, it should be True if using pre-pass optimizations
max_gates_in_a_group – the maximum number of gates to consider when computing the partitions
- Returns:
A dictionary of qubits to partitions