qat.synthopline.clifford_normalizer.CliffordNormalizer
- class qat.synthopline.clifford_normalizer.CliffordNormalizer(bidirectional: bool = False, max_iter: int = 20, timeout: float = None, optimize_initial: bool = False, codiag: str = 'syndrome', codiag_args: dict = None, verbose: bool = False)
Concept for a compilation strategy that, given a quantum circuit and some specs, produces a quantum circuit and a final Clifford operator. In other words, given a circuit \(U\), the algorithm should produce quantum circuit \(U'\) and Clifford operator \(C\) such that:
\[U = C\cdot U'\]- Parameters
bidirectional (optional, bool) – if set to True, the algorithm will be used to perform a bidirectional optimization (thus the algorithm will be called many times)
max_iter (optional, int) – the number of bidirectional optimization attempts (default to 20)
timeout (optional, float) – the maximum time to spend performing the bidirectional optimization in seconds. If set, the max_iter argument is ignored. This is useful to perform any-time optimization.
optimize_initial (optional, bool) – if set to True, try and optimize the initial rotations in the Pauli rotation decomposition of the circuit. Default to False.
codiag (optional, int) – the co-diagonalization backend used to deal with the initial (and final, in the case of sampling) Clifford operators. 0: greedy, 1: greedy graph state synthesis 2: syndrome decoding based graph state synthesis
codiag_args (optional, dict) – additional arguments passed to the co-diagonalization process
verbose (optional, bool) – set it to True to have a more talkative behavior (you’ll hate it)
- abstract compile_circuit(circuit, specs)
Compiles a single circuit, given some specs.
- Parameters
circuit (
Circuit
) – the circuit to compilespecs (
HardwareSpecs
or networkx.Graph) – the specs to use
- Returns
- a circuit and a
final Clifford operator (a stim Tableau)
- Return type
(
Circuit
, stim.Tableau)