SPRAAK
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Data Fields
SprCwrLMInterface Struct Reference

Data Fields

unsigned int flags
 
int max_context_len
 max. length of a context; including the initial 'len' element More...
 
int max_context_disc
 
int max_PC_depth
 
int max_PC_view
 
unsigned int max_class_id
 
int LMWord_sz
 
SprCwrLMWord * wrd
 
SprLMContext * scratch_lmc
 
_FuncPtr1_CWR_LM_INTERFACE_ func_prob
 
_FuncPtr2_CWR_LM_INTERFACE_ func_lmcn
 
void(* func_lmcr )(SprCwrLMInstance *lm, const SprLMContext *lmc)
 
void(* func_lmc0 )(SprCwrLMInstance *lm, SprLMContext *lmc_0)
 
_FuncPtr3_CWR_LM_INTERFACE_ func_lmcf
 
_FuncPtr4_CWR_LM_INTERFACE_ func_pall
 
_FuncPtr5_CWR_LM_INTERFACE_ func_lmcq
 query the LM More...
 

Field Documentation

unsigned int SprCwrLMInterface::flags
int SprCwrLMInterface::max_context_len

max. length of a context; including the initial 'len' element

int SprCwrLMInterface::max_context_disc

max. discriminative length of a context; excluding the initial 'len' element

int SprCwrLMInterface::max_PC_depth

max. depth returned by the LMI_SCAN_PROB and LMI_GET_CONTEXT_DEPTH sub-functions

int SprCwrLMInterface::max_PC_view

max. nr. of words covered by the {context,wrd} view of the LM (-1 for infinite) (e.g. N-gram -> N words)

unsigned int SprCwrLMInterface::max_class_id

upperbound on the class id's this LM will use, i.e. all class id's will be in the range [0...max_class_id-1]

int SprCwrLMInterface::LMWord_sz

total size (including header) needed by the LMWord structure for the current LM-type

SprCwrLMWord* SprCwrLMInterface::wrd

provides one LMWord structure of the correct length to the caller, if more are needed, they should be allocated

SprLMContext* SprCwrLMInterface::scratch_lmc

provides one LMContext structure of the correct length to the caller, if more are needed, they should be allocated

_FuncPtr1_CWR_LM_INTERFACE_ SprCwrLMInterface::func_prob

calc P(wndx|lmc)

_FuncPtr2_CWR_LM_INTERFACE_ SprCwrLMInterface::func_lmcn

calc P(wrd|lmc) + create lmc_next (lmc extended with wrd); wrd serves as a state variable (store the current state between calls when running over all classes a word can map to in the context lmc

void(* SprCwrLMInterface::func_lmcr)(SprCwrLMInstance *lm, const SprLMContext *lmc)

release the LM-context lmc

void(* SprCwrLMInterface::func_lmc0)(SprCwrLMInstance *lm, SprLMContext *lmc_0)

create an initial LM-context lmc_0

_FuncPtr3_CWR_LM_INTERFACE_ SprCwrLMInterface::func_lmcf

given a word wrd and an existing class index {wrd->hdr.word_ndx,wrd->hdr.class_id}, set the elements in wrd so that the specified LM-prob and LM-context will be set by a subsequent call to (*func_lmcn)()

_FuncPtr4_CWR_LM_INTERFACE_ SprCwrLMInterface::func_pall

calculate the LM probabilities for all words for a given LM-context

_FuncPtr5_CWR_LM_INTERFACE_ SprCwrLMInterface::func_lmcq

query the LM