class_docstr: Represents the type of a TensorFlow function.
  
  FunctionType is the canonical way to represent the input/output contract of
  all kinds of functions within the tf.function domain, including:
    - Polymorphic Function
    - Concrete Function
    - Atomic Function
  
  It provides consistent, centralized and layered logic for:
    - Canonicalization of Python input arguments
    - Type-based dispatch to monomorphic functions
    - Packing/unpacking structured python values to Tensors
    - Generation of structured placeholder values for tracing
  
  Additionaly, it also provides:
    - Lossless serialization
    - Native integration with Python function signature representation
    - Seamless migration from older representation formats
class_docstr_tok: ["Represents","the","type","of","a","TensorFlow","function",".","FunctionType","is","the","canonical","way","to","represent","the","input\/output","contract","of","all","kinds","of","functions","within","the","tf.function","domain",",","including",":","-","Polymorphic","Function","-","Concrete","Function","-","Atomic","Function","It","provides","consistent",",","centralized","and","layered","logic","for",":","-","Canonicalization","of","Python","input","arguments","-","Type-based","dispatch","to","monomorphic","functions","-","Packing\/unpacking","structured","python","values","to","Tensors","-","Generation","of","structured","placeholder","values","for","tracing","Additionaly",",","it","also","provides",":","-","Lossless","serialization","-","Native","integration","with","Python","function","signature","representation","-","Seamless","migration","from","older","representation","formats"]
docstr: Generate a proto representation from the FunctionType.
code: def to_proto(self) -> Any:
      """Generate a proto representation from the FunctionType."""
      return function_type_pb2.FunctionType(
          parameters=[p.to_proto() for p in self.parameters.values()],
          captures=[
              function_type_pb2.Capture(
                  name=n, type_constraint=serialization.serialize(t)
              )
              for n, t in self.captures.items()
          ],
      )
  
imports: import collections
  import inspect
  from typing import Any, Callable, Dict, List, Mapping, Optional, Sequence, Tuple
  from absl import logging
  from tensorflow.core.function import trace_type
  from tensorflow.core.function.polymorphism import function_type_pb2
  from tensorflow.core.function.trace_type import serialization
  from tensorflow.python.types import core
  from tensorflow.python.types import trace
label_desc: Use image node_id 8 for calling the FunctionType obj's underlying member method code with example usage: obj.to_proto() and returns: function_type_pb2