Invert
Description
This operation inverts the transduction corresponding to an FST by
exchanging the FST's input and output labels.
Usage
template<class Arc>
void Invert(MutableFst<Arc> *fst);
|
[bad link?] |
template <class Arc> InvertFst<Arc>::
InvertFst(const Fst<Arc> &fst);
|
|
fstinvert a.fst out.fst
|
|
Examples
A
:
A-1
:
Invert(&A);
InvertFst<Arc>(A);
fstinvert a.fst out.fst
Complexity
Invert
:
O(V + E), where
V = # of states and
E = # of arcs.
InvertFst:
- Constructor: O(1)
- Traversal: O(v + e),
where v = # of states visited, e = # of arcs visited and constant time to visit an input state or arc is assumed.
--
MichaelRiley - 1 Jul 2007