deltakit.explorer.analysis.calculate_lep_and_lep_stddev#
- deltakit.explorer.analysis.calculate_lep_and_lep_stddev(fails: ndarray[tuple[Any, ...], dtype[int64]] | Sequence[int] | int, shots: ndarray[tuple[Any, ...], dtype[int64]] | Sequence[int] | int) tuple[ndarray[tuple[Any, ...], dtype[float64]], ndarray[tuple[Any, ...], dtype[float64]]]#
Calculate the logical error probability and its standard deviation.
- Parameters:
fails (npt.NDArray[np.int_] | Sequence[int] | int) – The number of logical failures.
shots (npt.NDArray[np.int_] | Sequence[int] | int) – The number of shots the experiment was run for.
- Returns:
A tuple consisting of - the logical error probability; - the standard deviation of the logical error probability.
- Return type:
tuple[npt.NDArray[np.float64], npt.NDArray[np.float64]]
Examples
Calculating logical error probability and standard deviation given number of fails, and number of shots:
lep, lep_stddev = Analysis.calculate_lep_and_lep_stddev( fails=[498, 151, 34], shots=[500000] * 3, )