Lookup table initializer to use.
Default value to use if a key is missing from the table.
If non-empty, the created table is placed in the given container. Otherwise, a default container is used.
If non-empty, the created table is named in the given bucket with this shared name. Otherwise, the op name is used, instead.
If set to true
and sharedName
is empty, the table is shared using the node name.
Name for the created table.
Checks that the provided keys and values data types match those expected for this lookup table and throws an
InvalidDataTypeException
if they do not.
Checks that the provided keys and values data types match those expected for this lookup table and throws an
InvalidDataTypeException
if they do not.
Provided keys data type to check.
Provided values data type to check.
InvalidDataTypeException
If any of the provided data type does not match the corresponding expected type.
If non-empty, the created table is placed in the given container.
If non-empty, the created table is placed in the given container. Otherwise, a default container is used.
Default value to use if a key is missing from the table.
Default value to use if a key is missing from the table.
Resource handle to a lookup table.
Resource handle to a lookup table.
Creates and returns an op used to initialize this table.
Creates and returns an op used to initialize this table.
Name for the created op.
Created op.
Lookup table initializer to use.
Lookup table initializer to use.
Data type of the table keys.
Data type of the table keys.
Creates an op that looks up the provided keys in this table and returns the corresponding values.
Creates an op that looks up the provided keys in this table and returns the corresponding values.
Tensor containing the keys to look up.
Name for the created op.
Created op output.
InvalidDataTypeException
If the provided keys data types does not match the keys data type of this table.
Name for the created table.
Name for the created table.
If non-empty, the created table is named in the given bucket with this shared name.
If non-empty, the created table is named in the given bucket with this shared name. Otherwise, the op name is used, instead.
Creates an op that computes the number of elements in this table.
Creates an op that computes the number of elements in this table.
Name for the created op.
Created op output.
If set to true
and sharedName
is empty, the table is shared using the node name.
Data type of the table values.
Data type of the table values.
Generic hash table implementation for lookup tables.
The constructor creates a hash table, specifying the type of its keys and values. Before using the table the caller will have to initialize it. After initialization the table will be immutable.
Example usage:
Lookup table initializer to use.
Default value to use if a key is missing from the table.
If non-empty, the created table is placed in the given container. Otherwise, a default container is used.
If non-empty, the created table is named in the given bucket with this shared name. Otherwise, the op name is used, instead.
If set to
true
andsharedName
is empty, the table is shared using the node name.Name for the created table.