SetSize

public final class SetSize

Number of unique elements along last dimension of input `set`.

Input `set` is a `SparseTensor` represented by `set_indices`, `set_values`, and `set_shape`. The last dimension contains values in a set, duplicates are allowed but ignored.

If `validate_indices` is `True`, this op validates the order and range of `set` indices.

Nested Classes

class SetSize.Options Optional attributes for SetSize

Constants

String OP_NAME The name of this op, as known by TensorFlow core engine

Public Methods

Output < TInt32 >
asOutput ()
Returns the symbolic handle of the tensor.
static SetSize
create ( Scope scope, Operand < TInt64 > setIndices, Operand <? extends TType > setValues, Operand < TInt64 > setShape, Options... options)
Factory method to create a class wrapping a new SetSize operation.
Output < TInt32 >
output ()
For `set` ranked `n`, this is a `Tensor` with rank `n-1`, and the same 1st `n-1` dimensions as `set`.
static SetSize.Options
validateIndices (Boolean validateIndices)

Inherited Methods

Constants

public static final String OP_NAME

The name of this op, as known by TensorFlow core engine

Constant Value: "SetSize"

Public Methods

public Output < TInt32 > asOutput ()

Returns the symbolic handle of the tensor.

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.

public static SetSize create ( Scope scope, Operand < TInt64 > setIndices, Operand <? extends TType > setValues, Operand < TInt64 > setShape, Options... options)

Factory method to create a class wrapping a new SetSize operation.

Parameters
scope current scope
setIndices 2D `Tensor`, indices of a `SparseTensor`.
setValues 1D `Tensor`, values of a `SparseTensor`.
setShape 1D `Tensor`, shape of a `SparseTensor`.
options carries optional attributes values
Returns
  • a new instance of SetSize

public Output < TInt32 > output ()

For `set` ranked `n`, this is a `Tensor` with rank `n-1`, and the same 1st `n-1` dimensions as `set`. Each value is the number of unique elements in the corresponding `[0...n-1]` dimension of `set`.

public static SetSize.Options validateIndices (Boolean validateIndices)