class LMCacheEntry

This class implements the internal entries within the LMCache class.

Public Methods

[more]void addProb( int vocab_word, real prob )
Adds a log probability for the next-word denoted by 'vocab_word'

Public Members

[more] Creates the cache entry
[more] 'max_n_prev_words_' is the maximum number of prev words that will
[more] ever be used with the cache entry (eg.
[more] Replaces the current prev words with new ones.
[more] a number of prev words that is <= max_n_prev_words (ie.
[more] Resets all of the next-word log probs to -LOG_ZERO (to indicate that
[more] Returns the cached log probability for the next-word denoted by


Documentation

This class implements the internal entries within the LMCache class. Each entry consists of an array of previous words (eg. 2 previous words in a trigram entry), and a list of probabilities of next words given the previous words. There is also an age field that is used to keep track of how recently the entry was accessed.

o Creates the cache entry
Creates the cache entry

o 'max_n_prev_words_' is the maximum number of prev words that will
'max_n_prev_words_' is the maximum number of prev words that will

o ever be used with the cache entry (eg.
ever be used with the cache entry (eg. 2 for trigram LM)

o Replaces the current prev words with new ones.
Replaces the current prev words with new ones. The new entry can

o a number of prev words that is <= max_n_prev_words (ie.
a number of prev words that is <= max_n_prev_words (ie. can

o Resets all of the next-word log probs to -LOG_ZERO (to indicate that
Resets all of the next-word log probs to -LOG_ZERO (to indicate that

ovoid addProb( int vocab_word, real prob )
Adds a log probability for the next-word denoted by 'vocab_word'

o Returns the cached log probability for the next-word denoted by
Returns the cached log probability for the next-word denoted by


This class has no child classes.
Author:
Darren Moore (moore@idiap.ch)

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.