pygsti.tools.errgenproptools.slow_bulk_phi#
- slow_bulk_phi(tableau, desired_bitstring, Ps, Qs)#
Computes the phi function for multiple (P, Q) pairs at once while caching and reusing intermediate values computed via pauli_phase_update_all_zeros and amplitude_of_state.
- Parameters:
tableau (stim.Tableau or stim.TableauSimulator) – A stim Tableau or TableauSimulator corresponding to the input stabilizer state.
desired_bitstring (str) – A string of zeros and ones corresponding to the measured bitstring.
Ps (list[Union[str, stim.PauliString]]) – List of Pauli string indices for the first operator in each phi computation. Can be either a string or a stim.PauliString (but all values are assumed to be the same type).
Qs (list[Union[str, stim.PauliString]]) – List of Pauli string indices for the second operator in each phi computation. Can be either a string or a stim.PauliString (but all values are assumed to be the same type).
- Returns:
An array of computed phi values. Each phi will be one of {0, ±1, ±i}.
- Return type:
np.ndarray[np.complex128]