19 fst::VectorFst < fst::ArcTpl<fst::TropicalWeightTpl<double> > > pathFst;
22 for (fst::StateIterator
23 < fst::VectorFst<fst::ArcTpl<fst::TropicalWeightTpl<double> > >
24 > siter (pathFst); !siter.Done(); siter.Next() ) {
26 < fst::VectorFst<fst::ArcTpl<fst::TropicalWeightTpl<double> > >
27 > aiter (pathFst, siter.Value() ); !aiter.Done(); aiter.Next() ) {
28 line.
t.push_back (aiter.Value().olabel);
29 line.
score += aiter.Value().weight.Value();
44 double x = (++ml.begin() )->x;
48 ++ (++ml.begin() ); next != sd.
Value().end(); ++next) {
54 if ( (next->x - prev->x) / 2 > 1000) {
55 if (abs (prev->x) < abs (next->x) ) {
56 midpoint = prev->x + 1000;
58 midpoint = next->x - 1000;
62 midpoint = (prev->x + next->x) / 2.0;
void SingleShortestPath(const fst::Fst< FArc > &ifst, fst::MutableFst< TArc > *ofst, F gamma)
MertList::iterator MertIter
MertList ComputeFromFunctionArc(const fst::VectorFst< FunctionArc > &fst)
const MertList & Value() const
void const ComputeShortestPath(const fst::VectorFst< FunctionArc > &fst, double x, MertLine &line)
std::list< MertLine > MertList
void ShortestDistance(const fst::Fst< Arc > &fst, std::vector< typename Arc::Weight > *distance, const ShortestDistanceOptions< Arc, Queue, ArcFilter > &opts)