iqm.benchmarks.utils_shadows.get_local_shadow#
- iqm.benchmarks.utils_shadows.get_local_shadow(counts: dict[str, int], unitary_arg: ndarray | Sequence[str], subsystem_bit_indices: Sequence[int], clifford_or_haar: Literal['clifford', 'haar'] = 'clifford', cliffords_1q: dict[str, IQMCircuit] | None = None) ndarray#
Constructs shadows for each individual initialisation.
- Parameters:
counts (dict[str, int]) – A dictionary of bit-string counts.
unitary_arg (ndarray | Sequence[str]) – Local random unitaries used for a given initialisation, either specified as - A numpy array, or - A Sequence of Clifford labels.
subsystem_bit_indices (Sequence[int]) – Bit indices in the counts of the subsystem to construct the shadow of.
clifford_or_haar (Literal['clifford', 'haar']) – Whether to use Clifford or Haar random 1Q gates.
cliffords_1q (dict[str, IQMCircuit] | None) – Dictionary of 1-qubit Cliffords in terms of IQM-native r and CZ gates
- Returns:
Shadow of considered subsystem.
- Return type: