pub struct TrieCountLm<T, V, A> where
    T: TrieArray,
    V: Vocabulary,
    A: RankArray
{ /* private fields */ }
Expand description

Elias-Fano trie for indexing N-grams with their frequency counts.

Implementations

Builds the index from N-gram counts files.

Arguments
  • filepaths: Paths of N-gram counts files that should be sorted by N = 1, 2, …
  • fmt: File format.

Builds the index from N-gram counts files in a plain text format.

Arguments
  • filepaths: Paths of N-gram counts files that should be sorted by N = 1, 2, …

Builds the index from N-gram counts files in a gzip compressed format.

Arguments
  • filepaths: Paths of N-gram counts files that should be sorted by N = 1, 2, …

Builds the index from N-gram counts files in a deflate compressed format.

Arguments
  • filepaths: Paths of N-gram counts files that should be sorted by N = 1, 2, …

Builds the index from N-gram counts files in a zlib compressed format.

Arguments
  • filepaths: Paths of N-gram counts files that should be sorted by N = 1, 2, …

Serializes the index into the writer.

Deserializes the index from the reader.

Gets the number of bytes to serialize the index.

Gets breakdowns of memory usages for components.

Makes the lookuper.

Gets the maximum of N.

Gets the number of stored grams.

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.