Cambridge SMT System
fst::TropicalSparseTupleWeight< T > Class Template Reference

Implements Tropical Sparse tuple weight semiring, extending from openfst SparsePowerWeight class. More...

#include <tropical-sparse-tuple-weight.h>

Inherits SparsePowerWeight< TropicalWeightTpl< T > >, and SparsePowerWeight< TropicalWeightTpl< T > >.

Public Types

typedef TropicalWeightTpl< T > W
 
typedef TropicalSparseTupleWeight< T > ReverseWeight
 
typedef TropicalWeightTpl< T > W
 
typedef TropicalSparseTupleWeight< T > ReverseWeight
 

Public Member Functions

 TropicalSparseTupleWeight ()
 
 TropicalSparseTupleWeight (const SparsePowerWeight< W > &sw)
 
 TropicalSparseTupleWeight (W w)
 
TropicalSparseTupleWeight< T > Quantize (float delta=kDelta) const
 
ReverseWeight Reverse () const
 
 TropicalSparseTupleWeight ()
 
 TropicalSparseTupleWeight (const SparsePowerWeight< W > &sw)
 
 TropicalSparseTupleWeight (W w)
 
TropicalSparseTupleWeight< T > Quantize (float delta=kDelta) const
 
ReverseWeight Reverse () const
 

Static Public Member Functions

static std::vector< T > & Params ()
 
static std::string GetPrecisionString ()
 
static const std::string & Type ()
 
static uint64 Properties ()
 
static const TropicalSparseTupleWeight< T > & Zero ()
 
static const TropicalSparseTupleWeight< T > & One ()
 
static std::vector< T > & Params ()
 
static std::string GetPrecisionString ()
 
static const std::string & Type ()
 
static uint64 Properties ()
 
static const TropicalSparseTupleWeight< T > & Zero ()
 
static const TropicalSparseTupleWeight< T > & One ()
 

Friends

template<typename TT >
TropicalSparseTupleWeight< TT > Plus (const TropicalSparseTupleWeight< TT > &, const TropicalSparseTupleWeight< TT > &)
 
template<typename TT >
TropicalSparseTupleWeight< TT > Plus (const TropicalSparseTupleWeight< TT > &, const TropicalSparseTupleWeight< TT > &)
 

Detailed Description

template<typename T>
class fst::TropicalSparseTupleWeight< T >

Implements Tropical Sparse tuple weight semiring, extending from openfst SparsePowerWeight class.

Remarks
Main addition: The dot product of features with its scales is a tropical weight.

Definition at line 35 of file fsttools/include/tropical-sparse-tuple-weight.h.

Member Typedef Documentation

template<typename T>
typedef TropicalWeightTpl<T> fst::TropicalSparseTupleWeight< T >::W
template<typename T>
typedef TropicalWeightTpl<T> fst::TropicalSparseTupleWeight< T >::W

Constructor & Destructor Documentation

template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( )
inline
template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( const SparsePowerWeight< W > &  sw)
inline
template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( W  w)
inline
template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( )
inline
template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( const SparsePowerWeight< W > &  sw)
inline
template<typename T>
fst::TropicalSparseTupleWeight< T >::TropicalSparseTupleWeight ( W  w)
inline

Member Function Documentation

template<typename T>
static std::string fst::TropicalSparseTupleWeight< T >::GetPrecisionString ( )
inlinestatic
template<typename T>
static std::string fst::TropicalSparseTupleWeight< T >::GetPrecisionString ( )
inlinestatic

Definition at line 69 of file fsttools/include/tropical-sparse-tuple-weight.h.

Here is the caller graph for this function:

template<typename T>
static const TropicalSparseTupleWeight<T>& fst::TropicalSparseTupleWeight< T >::One ( )
inlinestatic
template<typename T>
static const TropicalSparseTupleWeight<T>& fst::TropicalSparseTupleWeight< T >::One ( )
inlinestatic
template<typename T>
static std::vector<T>& fst::TropicalSparseTupleWeight< T >::Params ( )
inlinestatic
template<typename T>
static std::vector<T>& fst::TropicalSparseTupleWeight< T >::Params ( )
inlinestatic

Definition at line 40 of file fsttools/include/tropical-sparse-tuple-weight.h.

Here is the caller graph for this function:

template<typename T>
static uint64 fst::TropicalSparseTupleWeight< T >::Properties ( )
inlinestatic
template<typename T>
static uint64 fst::TropicalSparseTupleWeight< T >::Properties ( )
inlinestatic
template<typename T>
TropicalSparseTupleWeight<T> fst::TropicalSparseTupleWeight< T >::Quantize ( float  delta = kDelta) const
inline
template<typename T>
TropicalSparseTupleWeight<T> fst::TropicalSparseTupleWeight< T >::Quantize ( float  delta = kDelta) const
inline
template<typename T>
ReverseWeight fst::TropicalSparseTupleWeight< T >::Reverse ( ) const
inline

Definition at line 95 of file latmert/include/tropical-sparse-tuple-weight.h.

Here is the call graph for this function:

template<typename T>
ReverseWeight fst::TropicalSparseTupleWeight< T >::Reverse ( ) const
inline
template<typename T>
static const std::string& fst::TropicalSparseTupleWeight< T >::Type ( )
inlinestatic

Definition at line 67 of file latmert/include/tropical-sparse-tuple-weight.h.

Here is the call graph for this function:

template<typename T>
static const std::string& fst::TropicalSparseTupleWeight< T >::Type ( )
inlinestatic

Definition at line 80 of file fsttools/include/tropical-sparse-tuple-weight.h.

Here is the call graph for this function:

Here is the caller graph for this function:

template<typename T>
static const TropicalSparseTupleWeight<T>& fst::TropicalSparseTupleWeight< T >::Zero ( )
inlinestatic
template<typename T>
static const TropicalSparseTupleWeight<T>& fst::TropicalSparseTupleWeight< T >::Zero ( )
inlinestatic

Definition at line 92 of file fsttools/include/tropical-sparse-tuple-weight.h.

Here is the caller graph for this function:

Friends And Related Function Documentation

template<typename T>
template<typename TT >
TropicalSparseTupleWeight<TT> Plus ( const TropicalSparseTupleWeight< TT > &  ,
const TropicalSparseTupleWeight< TT > &   
)
friend
template<typename T>
template<typename TT >
TropicalSparseTupleWeight<TT> Plus ( const TropicalSparseTupleWeight< TT > &  ,
const TropicalSparseTupleWeight< TT > &   
)
friend

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