Packages

final case class OpDef(name: String = "", inputArg: Seq[ArgDef] = _root_.scala.Seq.empty, outputArg: Seq[ArgDef] = _root_.scala.Seq.empty, controlOutput: Seq[String] = _root_.scala.Seq.empty, attr: Seq[AttrDef] = _root_.scala.Seq.empty, deprecation: Option[OpDeprecation] = _root_.scala.None, summary: String = "", description: String = "", isCommutative: Boolean = false, isAggregate: Boolean = false, isStateful: Boolean = false, allowsUninitializedInput: Boolean = false, unknownFields: UnknownFieldSet = ...) extends GeneratedMessage with Updatable[OpDef] with Product with Serializable

Defines an operation. A NodeDef in a GraphDef specifies an Op by using the "op" field which should match the name of a OpDef. LINT.IfChange

name

Op names starting with an underscore are reserved for internal use. Names should be CamelCase and match the regexp "[A-Z][a-zA-Z0-9>_]*".

inputArg

Description of the input(s).

outputArg

Description of the output(s).

controlOutput

Named control outputs for this operation. Useful only for composite operations (i.e. functions) which want to name different control outputs.

deprecation

Optional deprecation based on GraphDef versions.

summary

One-line human-readable description of what the Op does.

description

Additional, longer human-readable description of what the Op does.

isCommutative

True if the operation is commutative ("op(a,b) == op(b,a)" for all inputs)

isAggregate

If is_aggregate is true, then this operation accepts N >= 2 inputs and produces 1 output all of the same type. Should be associative and commutative, and produce output with the same shape as the input. The optimizer may replace an aggregate op taking input from multiple devices with a tree of aggregate ops that aggregate locally within each device (and possibly within groups of nearby devices) before communicating. TODO(josh11b): Implement that optimization. for things like add

isStateful

Ops are marked as stateful if their behavior depends on some state beyond their input tensors (e.g. variable reading op) or if they have a side-effect (e.g. printing or asserting ops). Equivalently, stateless ops must always produce the same output for the same input and have no side-effects. By default Ops may be moved between devices. Stateful ops should either not be moved, or should only be moved if that state can also be moved (e.g. via some sort of save / restore). Stateful ops are guaranteed to never be optimized away by Common Subexpression Elimination (CSE). for things like variables, queue

allowsUninitializedInput

By default, all inputs to an Op must be initialized Tensors. Ops that may initialize tensors for the first time should set this field to true, to allow the Op to take an uninitialized Tensor as input. for Assign, etc.

Annotations
@SerialVersionUID()
Linear Supertypes
Updatable[OpDef], GeneratedMessage, Serializable, Serializable, Product, Equals, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. OpDef
  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 OpDef(name: String = "", inputArg: Seq[ArgDef] = _root_.scala.Seq.empty, outputArg: Seq[ArgDef] = _root_.scala.Seq.empty, controlOutput: Seq[String] = _root_.scala.Seq.empty, attr: Seq[AttrDef] = _root_.scala.Seq.empty, deprecation: Option[OpDeprecation] = _root_.scala.None, summary: String = "", description: String = "", isCommutative: Boolean = false, isAggregate: Boolean = false, isStateful: Boolean = false, allowsUninitializedInput: Boolean = false, unknownFields: UnknownFieldSet = ...)

    name

    Op names starting with an underscore are reserved for internal use. Names should be CamelCase and match the regexp "[A-Z][a-zA-Z0-9>_]*".

    inputArg

    Description of the input(s).

    outputArg

    Description of the output(s).

    controlOutput

    Named control outputs for this operation. Useful only for composite operations (i.e. functions) which want to name different control outputs.

    deprecation

    Optional deprecation based on GraphDef versions.

    summary

    One-line human-readable description of what the Op does.

    description

    Additional, longer human-readable description of what the Op does.

    isCommutative

    True if the operation is commutative ("op(a,b) == op(b,a)" for all inputs)

    isAggregate

    If is_aggregate is true, then this operation accepts N >= 2 inputs and produces 1 output all of the same type. Should be associative and commutative, and produce output with the same shape as the input. The optimizer may replace an aggregate op taking input from multiple devices with a tree of aggregate ops that aggregate locally within each device (and possibly within groups of nearby devices) before communicating. TODO(josh11b): Implement that optimization. for things like add

    isStateful

    Ops are marked as stateful if their behavior depends on some state beyond their input tensors (e.g. variable reading op) or if they have a side-effect (e.g. printing or asserting ops). Equivalently, stateless ops must always produce the same output for the same input and have no side-effects. By default Ops may be moved between devices. Stateful ops should either not be moved, or should only be moved if that state can also be moved (e.g. via some sort of save / restore). Stateful ops are guaranteed to never be optimized away by Common Subexpression Elimination (CSE). for things like variables, queue

    allowsUninitializedInput

    By default, all inputs to an Op must be initialized Tensors. Ops that may initialize tensors for the first time should set this field to true, to allow the Op to take an uninitialized Tensor as input. for Assign, etc.

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 addAllAttr(__vs: Iterable[AttrDef]): OpDef
  5. def addAllControlOutput(__vs: Iterable[String]): OpDef
  6. def addAllInputArg(__vs: Iterable[ArgDef]): OpDef
  7. def addAllOutputArg(__vs: Iterable[ArgDef]): OpDef
  8. def addAttr(__vs: AttrDef*): OpDef
  9. def addControlOutput(__vs: String*): OpDef
  10. def addInputArg(__vs: ArgDef*): OpDef
  11. def addOutputArg(__vs: ArgDef*): OpDef
  12. val allowsUninitializedInput: Boolean
  13. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  14. val attr: Seq[AttrDef]
  15. def clearAttr: OpDef
  16. def clearControlOutput: OpDef
  17. def clearDeprecation: OpDef
  18. def clearInputArg: OpDef
  19. def clearOutputArg: OpDef
  20. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @HotSpotIntrinsicCandidate()
  21. def companion: OpDef.type
    Definition Classes
    OpDef → GeneratedMessage
  22. val controlOutput: Seq[String]
  23. val deprecation: Option[OpDeprecation]
  24. val description: String
  25. def discardUnknownFields: OpDef
  26. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  27. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  28. def getDeprecation: OpDeprecation
  29. def getField(__field: FieldDescriptor): PValue
    Definition Classes
    OpDef → GeneratedMessage
  30. def getFieldByNumber(__fieldNumber: Int): Any
    Definition Classes
    OpDef → GeneratedMessage
  31. val inputArg: Seq[ArgDef]
  32. val isAggregate: Boolean
  33. val isCommutative: Boolean
  34. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  35. val isStateful: Boolean
  36. val name: String
  37. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  38. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  39. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @HotSpotIntrinsicCandidate()
  40. val outputArg: Seq[ArgDef]
  41. def serializedSize: Int
    Definition Classes
    OpDef → GeneratedMessage
  42. val summary: String
  43. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  44. final def toByteArray: Array[Byte]
    Definition Classes
    GeneratedMessage
  45. final def toByteString: ByteString
    Definition Classes
    GeneratedMessage
  46. final def toPMessage: PMessage
    Definition Classes
    GeneratedMessage
  47. def toProtoString: String
    Definition Classes
    OpDef → GeneratedMessage
  48. val unknownFields: UnknownFieldSet
  49. def update(ms: (Lens[OpDef, OpDef]) ⇒ Mutation[OpDef]*): OpDef
    Definition Classes
    Updatable
  50. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  51. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  52. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  53. def withAllowsUninitializedInput(__v: Boolean): OpDef
  54. def withAttr(__v: Seq[AttrDef]): OpDef
  55. def withControlOutput(__v: Seq[String]): OpDef
  56. def withDeprecation(__v: OpDeprecation): OpDef
  57. def withDescription(__v: String): OpDef
  58. def withInputArg(__v: Seq[ArgDef]): OpDef
  59. def withIsAggregate(__v: Boolean): OpDef
  60. def withIsCommutative(__v: Boolean): OpDef
  61. def withIsStateful(__v: Boolean): OpDef
  62. def withName(__v: String): OpDef
  63. def withOutputArg(__v: Seq[ArgDef]): OpDef
  64. def withSummary(__v: String): OpDef
  65. def withUnknownFields(__v: UnknownFieldSet): OpDef
  66. final def writeDelimitedTo(output: OutputStream): Unit
    Definition Classes
    GeneratedMessage
  67. def writeTo(_output__: CodedOutputStream): Unit
    Definition Classes
    OpDef → GeneratedMessage
  68. 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[OpDef]

Inherited from GeneratedMessage

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped