Cambridge SMT System
lm::HifstEnumerateVocab< WordMapperT > Class Template Reference

This class extends EnumerateVocab in kenlm code. This class creates a grammar-integer to lm-integer hash which will be used during composition. If there is an lm wordmap available, then it uses the wordmap to synchronize. Note: The nplm wrapper does not support this functionality. More...

#include <hifst_enumerate_vocab.hpp>

Inherits EnumerateVocab.

Collaboration diagram for lm::HifstEnumerateVocab< WordMapperT >:

Public Member Functions

 HifstEnumerateVocab (IdBridge &idb, WordMapperT *wm)
 
virtual ~HifstEnumerateVocab ()
 
virtual void Add (WordIndex index, const StringPiece &str)
 
void Add (WordIndex index, const std::string &s)
 
void AddOutput (WordIndex index, const std::string &s)
 

Public Attributes

IdBridgeidb_
 

Detailed Description

template<class WordMapperT>
class lm::HifstEnumerateVocab< WordMapperT >

This class extends EnumerateVocab in kenlm code. This class creates a grammar-integer to lm-integer hash which will be used during composition. If there is an lm wordmap available, then it uses the wordmap to synchronize. Note: The nplm wrapper does not support this functionality.

Definition at line 38 of file hifst_enumerate_vocab.hpp.

Constructor & Destructor Documentation

template<class WordMapperT>
lm::HifstEnumerateVocab< WordMapperT >::HifstEnumerateVocab ( IdBridge idb,
WordMapperT *  wm 
)
inline

Definition at line 45 of file hifst_enumerate_vocab.hpp.

template<class WordMapperT>
virtual lm::HifstEnumerateVocab< WordMapperT >::~HifstEnumerateVocab ( )
inlinevirtual

Definition at line 46 of file hifst_enumerate_vocab.hpp.

Member Function Documentation

template<class WordMapperT>
virtual void lm::HifstEnumerateVocab< WordMapperT >::Add ( WordIndex  index,
const StringPiece &  str 
)
inlinevirtual

Definition at line 47 of file hifst_enumerate_vocab.hpp.

Here is the caller graph for this function:

template<class WordMapperT>
void lm::HifstEnumerateVocab< WordMapperT >::Add ( WordIndex  index,
const std::string &  s 
)
inline

Definition at line 52 of file hifst_enumerate_vocab.hpp.

Here is the call graph for this function:

template<class WordMapperT>
void lm::HifstEnumerateVocab< WordMapperT >::AddOutput ( WordIndex  index,
const std::string &  s 
)
inline

Definition at line 72 of file hifst_enumerate_vocab.hpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

template<class WordMapperT>
IdBridge& lm::HifstEnumerateVocab< WordMapperT >::idb_

Definition at line 44 of file hifst_enumerate_vocab.hpp.


The documentation for this class was generated from the following file: