Cambridge SMT System
ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT > Class Template Reference

Class for multithreaded application of language model. Inherits taskinterface and provides standalone function object behaviour. More...

#include <main-run.applylm.hpp>

Inheritance diagram for ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >:
Collaboration diagram for ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >:

Public Member Functions

 MultiThreadedApplyLanguageModelTask (ucam::util::RegistryPO const &rg)
 Constructor. More...
 
bool operator() ()
 Standalone behaviour, just call the functor and it will do the job. More...
 
bool run (Data &original_data)
 Multithread lm application. Runs only if option –nthreads defined >0. More...
 
- Public Member Functions inherited from ucam::util::TaskInterface< DataT< ArcT > >
 TaskInterface ()
 Constructor. More...
 
virtual ~TaskInterface ()
 
bool chainrun (DataT< ArcT > &d)
 Implements chain of responsability. Calls run method and, if there is another task, call its run method too. More...
 
bool operator() (DataT< ArcT > &d)
 
TaskInterfaceoperator() (TaskInterface *t)
 
TaskInterfaceappendTask (TaskInterface *t)
 Appends a task class. If there is no task, append here, otherwise delegate in next task. More...
 
TaskInterfacegetTask ()
 Return appended task. More...
 
TaskInterfacenext ()
 

Detailed Description

template<template< class > class DataT, class ArcT>
class ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >

Class for multithreaded application of language model. Inherits taskinterface and provides standalone function object behaviour.

Definition at line 213 of file main-run.applylm.hpp.

Constructor & Destructor Documentation

template<template< class > class DataT, class ArcT >
ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >::MultiThreadedApplyLanguageModelTask ( ucam::util::RegistryPO const &  rg)
inline

Constructor.

Parameters
rgRegistry object containing parameters

Definition at line 246 of file main-run.applylm.hpp.

Member Function Documentation

template<template< class > class DataT, class ArcT >
bool ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >::operator() ( )
inline

Standalone behaviour, just call the functor and it will do the job.

Definition at line 265 of file main-run.applylm.hpp.

Here is the call graph for this function:

template<template< class > class DataT, class ArcT >
bool ucam::fsttools::MultiThreadedApplyLanguageModelTask< DataT, ArcT >::run ( Data &  original_data)
inlinevirtual

Multithread lm application. Runs only if option –nthreads defined >0.

Remarks
Now a threadpool is defined, each language model application is submitted as a thread. Important note: in contrast to single-threading, sentence specific language model loading does not work with multithreading. You have to load once your full language model.

Implements ucam::util::TaskInterface< DataT< ArcT > >.

Definition at line 280 of file main-run.applylm.hpp.

Here is the call graph for this function:


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