T
- data type for output()
output@Operator public final class Placeholder<T> extends PrimitiveOp implements Operand<T>
N.B. This operation will fail with an error if it is executed. It is intended as a way to represent a value that will always be fed, and to provide attrs that enable the fed value to be checked at runtime.
Modifier and Type | Class and Description |
---|---|
static class |
Placeholder.Options
Optional attributes for
Placeholder |
operation
Modifier and Type | Method and Description |
---|---|
Output<T> |
asOutput()
Returns the symbolic handle of a tensor.
|
static <T> Placeholder<T> |
create(Scope scope,
Class<T> dtype,
Placeholder.Options... options)
Factory method to create a class wrapping a new Placeholder operation.
|
Output<T> |
output()
A placeholder tensor that must be replaced using the feed mechanism.
|
static Placeholder.Options |
shape(Shape shape) |
equals, hashCode, op, toString
public static <T> Placeholder<T> create(Scope scope, Class<T> dtype, Placeholder.Options... options)
scope
- current scopedtype
- The type of elements in the tensor.options
- carries optional attributes valuespublic static Placeholder.Options shape(Shape shape)
shape
- (Optional) The shape of the tensor. If the shape has 0 dimensions, the
shape is unconstrained.public Output<T> output()
public Output<T> asOutput()
Operand
Inputs to TensorFlow operations are outputs of another TensorFlow operation. This method is used to obtain a symbolic handle that represents the computation of the input.
asOutput
in interface Operand<T>
OperationBuilder.addInput(Output)
Copyright © 2022. All rights reserved.