def clifford_tableau_from_proto(msg: v2.program_pb2.CliffordTableau) -> CliffordTableau:
    """Extracts a CliffordTableau object from a CliffordTableau proto.
    Args:
        msg: The proto containing a serialized value.
    Returns:
        The deserialized InternalGate object.
    """
    return CliffordTableau(
        num_qubits=msg.num_qubits,
        initial_state=msg.initial_state,
        rs=np.array(msg.rs, dtype=bool) if msg.rs else None,
        xs=np.array(msg.xs, dtype=bool).reshape((2 * msg.num_qubits, -1)) if msg.xs else None,
        zs=np.array(msg.zs, dtype=bool).reshape((2 * msg.num_qubits, -1)) if msg.zs else None,
    )
Extracts a CliffordTableau object from a CliffordTableau proto.
    Args:
        msg: The proto containing a serialized value.
    Returns:
        The deserialized InternalGate object.
    
cirq-google/cirq_google/serialization/arg_func_langs.py