diff --git a/pytket/extensions/qiskit/qiskit_convert.py b/pytket/extensions/qiskit/qiskit_convert.py index 6e22e6ad..ad206ccf 100644 --- a/pytket/extensions/qiskit/qiskit_convert.py +++ b/pytket/extensions/qiskit/qiskit_convert.py @@ -1062,11 +1062,9 @@ def get_avg_characterisation( dict[Node, list[list[float]]], characterisation["ReadoutErrors"] ) - avg: Callable[[dict[Any, float]], float] = lambda xs: sum( + avg: Callable[[dict[Any, float]], float] = lambda xs: sum( # noqa: E731 xs.values() - ) / len( # noqa: E731 - xs - ) + ) / len(xs) avg_mat: Callable[[list[list[float]]], float] = ( # noqa: E731 lambda xs: (xs[0][1] + xs[1][0]) / 2.0 )