Packages

final case class FunctionDef(signature: Option[OpDef] = _root_.scala.None, attr: Map[String, AttrValue] = ..., argAttr: Map[Int, ArgAttrs] = ..., resourceArgUniqueId: Map[Int, Int] = ..., nodeDef: Seq[NodeDef] = _root_.scala.Seq.empty, ret: Map[String, String] = ..., controlRet: Map[String, String] = ..., unknownFields: UnknownFieldSet = ...) extends GeneratedMessage with Updatable[FunctionDef] with Product with Serializable

A function can be instantiated when the runtime can bind every attr with a value. When a GraphDef has a call to a function, it must have binding for every attr defined in the signature.

TODO(zhifengc): * device spec, etc.

signature

The definition of the function's name, arguments, return values, attrs etc.

attr

Attributes specific to this function definition.

resourceArgUniqueId

Unique IDs for each resource argument, used to track aliasing resources. If Argument A and Argument B alias each other, then resource_arg_unique_ids[A.index] == resource_arg_unique_ids[B.index]. If this field is empty, none of the arguments could alias; otherwise, every resource argument should have an entry in this field. When instantiated, the unique IDs will be attached to the _Arg nodes' "_resource_arg_unique_id" attribute.

nodeDef

By convention, "op" in node_def is resolved by consulting with a user-defined library first. If not resolved, "func" is assumed to be a builtin op.

ret

A mapping from the output arg names from signature to the outputs from node_def that should be returned by the function.

controlRet

A mapping from control output names from signature to node names in node_def which should be control outputs of this function.

Annotations
@SerialVersionUID()
Linear Supertypes
Updatable[FunctionDef], GeneratedMessage, Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. FunctionDef
  2. Updatable
  3. GeneratedMessage
  4. Serializable
  5. Serializable
  6. Product
  7. Equals
  8. AnyRef
  9. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new FunctionDef(signature: Option[OpDef] = _root_.scala.None, attr: Map[String, AttrValue] = ..., argAttr: Map[Int, ArgAttrs] = ..., resourceArgUniqueId: Map[Int, Int] = ..., nodeDef: Seq[NodeDef] = _root_.scala.Seq.empty, ret: Map[String, String] = ..., controlRet: Map[String, String] = ..., unknownFields: UnknownFieldSet = ...)

    signature

    The definition of the function's name, arguments, return values, attrs etc.

    attr

    Attributes specific to this function definition.

    resourceArgUniqueId

    Unique IDs for each resource argument, used to track aliasing resources. If Argument A and Argument B alias each other, then resource_arg_unique_ids[A.index] == resource_arg_unique_ids[B.index]. If this field is empty, none of the arguments could alias; otherwise, every resource argument should have an entry in this field. When instantiated, the unique IDs will be attached to the _Arg nodes' "_resource_arg_unique_id" attribute.

    nodeDef

    By convention, "op" in node_def is resolved by consulting with a user-defined library first. If not resolved, "func" is assumed to be a builtin op.

    ret

    A mapping from the output arg names from signature to the outputs from node_def that should be returned by the function.

    controlRet

    A mapping from control output names from signature to node names in node_def which should be control outputs of this function.

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def addAllArgAttr(__vs: Iterable[(Int, ArgAttrs)]): FunctionDef
  5. def addAllAttr(__vs: Iterable[(String, AttrValue)]): FunctionDef
  6. def addAllControlRet(__vs: Iterable[(String, String)]): FunctionDef
  7. def addAllNodeDef(__vs: Iterable[NodeDef]): FunctionDef
  8. def addAllResourceArgUniqueId(__vs: Iterable[(Int, Int)]): FunctionDef
  9. def addAllRet(__vs: Iterable[(String, String)]): FunctionDef
  10. def addArgAttr(__vs: (Int, ArgAttrs)*): FunctionDef
  11. def addAttr(__vs: (String, AttrValue)*): FunctionDef
  12. def addControlRet(__vs: (String, String)*): FunctionDef
  13. def addNodeDef(__vs: NodeDef*): FunctionDef
  14. def addResourceArgUniqueId(__vs: (Int, Int)*): FunctionDef
  15. def addRet(__vs: (String, String)*): FunctionDef
  16. val argAttr: Map[Int, ArgAttrs]
  17. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  18. val attr: Map[String, AttrValue]
  19. def clearArgAttr: FunctionDef
  20. def clearAttr: FunctionDef
  21. def clearControlRet: FunctionDef
  22. def clearNodeDef: FunctionDef
  23. def clearResourceArgUniqueId: FunctionDef
  24. def clearRet: FunctionDef
  25. def clearSignature: FunctionDef
  26. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  27. def companion: FunctionDef.type
    Definition Classes
    FunctionDef → GeneratedMessage
  28. val controlRet: Map[String, String]
  29. def discardUnknownFields: FunctionDef
  30. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  31. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  32. def getField(__field: FieldDescriptor): PValue
    Definition Classes
    FunctionDef → GeneratedMessage
  33. def getFieldByNumber(__fieldNumber: Int): Any
    Definition Classes
    FunctionDef → GeneratedMessage
  34. def getSignature: OpDef
  35. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  36. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  37. val nodeDef: Seq[NodeDef]
  38. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  39. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  40. val resourceArgUniqueId: Map[Int, Int]
  41. val ret: Map[String, String]
  42. def serializedSize: Int
    Definition Classes
    FunctionDef → GeneratedMessage
  43. val signature: Option[OpDef]
  44. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  45. final def toByteArray: Array[Byte]
    Definition Classes
    GeneratedMessage
  46. final def toByteString: ByteString
    Definition Classes
    GeneratedMessage
  47. final def toPMessage: PMessage
    Definition Classes
    GeneratedMessage
  48. def toProtoString: String
    Definition Classes
    FunctionDef → GeneratedMessage
  49. val unknownFields: UnknownFieldSet
  50. def update(ms: (Lens[FunctionDef, FunctionDef]) ⇒ Mutation[FunctionDef]*): FunctionDef
    Definition Classes
    Updatable
  51. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  52. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  53. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  54. def withArgAttr(__v: Map[Int, ArgAttrs]): FunctionDef
  55. def withAttr(__v: Map[String, AttrValue]): FunctionDef
  56. def withControlRet(__v: Map[String, String]): FunctionDef
  57. def withNodeDef(__v: Seq[NodeDef]): FunctionDef
  58. def withResourceArgUniqueId(__v: Map[Int, Int]): FunctionDef
  59. def withRet(__v: Map[String, String]): FunctionDef
  60. def withSignature(__v: OpDef): FunctionDef
  61. def withUnknownFields(__v: UnknownFieldSet): FunctionDef
  62. final def writeDelimitedTo(output: OutputStream): Unit
    Definition Classes
    GeneratedMessage
  63. def writeTo(_output__: CodedOutputStream): Unit
    Definition Classes
    FunctionDef → GeneratedMessage
  64. final def writeTo(output: OutputStream): Unit
    Definition Classes
    GeneratedMessage

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated
    Deprecated

Inherited from Updatable[FunctionDef]

Inherited from GeneratedMessage

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped