TrivialFactorWeightFst takes as template parameter a FactorIterator as defined above. More...
#include <trivial-factor-weight.h>
Public Types | |
typedef A | Arc |
typedef A::Weight | Weight |
typedef A::StateId | StateId |
typedef DefaultCacheStore< Arc > | Store |
typedef Store::State | State |
typedef internal::TrivialFactorWeightFstImpl< A, F > | Impl |
Public Member Functions | |
TrivialFactorWeightFst (const Fst< A > &fst) | |
TrivialFactorWeightFst (const Fst< A > &fst, const TrivialFactorWeightOptions< A > &opts) | |
TrivialFactorWeightFst (const TrivialFactorWeightFst< A, F > &fst, bool copy) | |
TrivialFactorWeightFst< A, F > * | Copy (bool copy=false) const override |
void | InitStateIterator (StateIteratorData< A > *data) const override |
void | InitArcIterator (StateId s, ArcIteratorData< A > *data) const override |
Private Member Functions | |
TrivialFactorWeightFst & | operator= (const TrivialFactorWeightFst &fst)=delete |
Friends | |
class | ArcIterator< TrivialFactorWeightFst< A, F > > |
class | StateIterator< TrivialFactorWeightFst< A, F > > |
TrivialFactorWeightFst takes as template parameter a FactorIterator as defined above.
The result of weight factoring is a transducer equivalent to the input whose path weights have been factored according to the FactorIterator. States and transitions will be added as necessary. This algorithm differs from the one implemented in FactorWeightFst in that it does not attempt to push the extra weight forward to the next state: it uses a sequence of "extra" intermediate state, and outputs the remaining weight right away. This ensures that it will always succeed, even for Gallic representations of FSTs that have cycles with more output than input symbols. Note that the code below was modified from factor-weight.h by just search-and-replacing "FactorWeight" by "TrivialFactorWeight".
Definition at line 325 of file trivial-factor-weight.h.
typedef A Arc |
Definition at line 331 of file trivial-factor-weight.h.
typedef internal::TrivialFactorWeightFstImpl<A, F> Impl |
Definition at line 336 of file trivial-factor-weight.h.
typedef Store::State State |
Definition at line 335 of file trivial-factor-weight.h.
typedef A::StateId StateId |
Definition at line 333 of file trivial-factor-weight.h.
Definition at line 334 of file trivial-factor-weight.h.
typedef A::Weight Weight |
Definition at line 332 of file trivial-factor-weight.h.
|
inlineexplicit |
Definition at line 338 of file trivial-factor-weight.h.
|
inline |
Definition at line 341 of file trivial-factor-weight.h.
|
inline |
Definition at line 345 of file trivial-factor-weight.h.
|
inlineoverride |
Definition at line 349 of file trivial-factor-weight.h.
|
inlineoverride |
Definition at line 355 of file trivial-factor-weight.h.
|
inlineoverride |
Definition at line 391 of file trivial-factor-weight.h.
|
privatedelete |
|
friend |
Definition at line 328 of file trivial-factor-weight.h.
|
friend |
Definition at line 329 of file trivial-factor-weight.h.