|  View source on GitHub | 
Describes how to serialize CircuitOperations.
Inherits From: OpDeserializer
Methods
can_deserialize_proto
can_deserialize_proto(
    proto
)
Whether the given operation can be serialized by this serializer.
from_proto
from_proto(
    proto: v2.program_pb2.CircuitOperation,
    *,
    constants: list[v2.program_pb2.Constant],
    deserialized_constants: list[Any]
) -> cirq.Operation
Turns a cirq.google.api.v2.CircuitOperation proto into a CircuitOperation.
| Args | |
|---|---|
| proto | The proto object to be deserialized. | 
| constants | The list of Constant protos referenced by constant
table indices in proto. This list should already have been
parsed to produce 'deserialized_constants'. | 
| deserialized_constants | The deserialized contents of constants. | 
| Returns | |
|---|---|
| The deserialized CircuitOperation represented by proto. | 
| Raises | |
|---|---|
| ValueError | If the circuit operatio proto cannot be deserialied because it is malformed. |