Module: tf.contrib.lookup

View source on GitHub

Ops for lookup operations.

Classes

class HashTable: A generic hash table implementation.

class HasherSpec: A structure for the spec of the hashing function to use for hash buckets.

class IdTableWithHashBuckets: String to Id table wrapper that assigns out-of-vocabulary keys to buckets.

class InitializableLookupTableBase: Initializable lookup table interface.

class KeyValueTensorInitializer: Table initializers given keys and values tensors.

class LookupInterface: Represent a lookup table that persists across different steps.

class MutableDenseHashTable: A generic mutable hash table implementation using tensors as backing store.

class MutableHashTable: A generic mutable hash table implementation.

class StrongHashSpec: A structure to specify a key of the strong keyed hash spec.

class TableInitializerBase: Base class for lookup table initializers.

class TextFileIdTableInitializer: Table initializer for string to int64 IDs tables from a text file.

class TextFileIndex: The key and value content to get from each line.

class TextFileInitializer: Table initializers from a text file.

class TextFileStringTableInitializer: Table initializer for int64 IDs to string tables from a text file.

Functions

index_table_from_file(...): Returns a lookup table that converts a string tensor into int64 IDs.

index_table_from_tensor(...): Returns a lookup table that converts a string tensor into int64 IDs.

index_to_string(...): Maps tensor of indices into string values based on mapping. (deprecated)

index_to_string_table_from_file(...): Returns a lookup table that maps a Tensor of indices into strings.

index_to_string_table_from_tensor(...): Returns a lookup table that maps a Tensor of indices into strings.

string_to_index(...): Maps tensor of strings into int64 indices based on mapping. (deprecated)

string_to_index_table_from_file(...): DEPRECATED FUNCTION

string_to_index_table_from_tensor(...): DEPRECATED FUNCTION

Other Members

  • FastHashSpec