15 #ifndef MULTIEPSILONCOMPOSE_HPP 16 #define MULTIEPSILONCOMPOSE_HPP 36 ,
const Fst<Arc>& fstrhs
37 ,
const std::vector<typename Arc::Label>& multiepsilons ) {
38 typedef MultiEpsMatcher< Matcher<Fst<Arc> > > MultiEpsilonMatcher;
39 typedef ComposeFstOptions<Arc, MultiEpsilonMatcher> COptions;
40 MultiEpsilonMatcher *mem1 =
new MultiEpsilonMatcher ( fstlhs, MATCH_OUTPUT,
42 MultiEpsilonMatcher *mem2 =
new MultiEpsilonMatcher ( fstrhs, MATCH_NONE,
44 for ( std::size_t i = 0; i < multiepsilons.size(); ++i ) {
45 mem1->AddMultiEpsLabel ( multiepsilons[i] );
54 return ComposeFst<Arc> ( fstlhs, fstrhs, copts );
ComposeFst< Arc > MultiEpsilonCompose(const Fst< Arc > &fstlhs, const Fst< Arc > &fstrhs, const std::vector< typename Arc::Label > &multiepsilons)
Convenience function that performs composition with multiple epsilons.