def assert_mixtures_equal(actual, expected) -> None:
    """Assert equal for tuple of mixed scalar and array types."""
    for a, e in zip(actual, expected):
        np.testing.assert_almost_equal(a[0], e[0])
        np.testing.assert_almost_equal(a[1], e[1])
Assert equal for tuple of mixed scalar and array types.
cirq-core/cirq/ops/gate_operation_test.py