TWiki> FST Web>FstQuickTour>InvertDoc (revision 1)EditAttach

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);
doc [bad link?]
template <class Arc> InvertFst<Arc>::
InvertFst(const Fst<Arc> &fst);
doc
fstinvert a.fst out.fst
 

Examples

A:

invert1.jpg

A-1:

invert2.jpg

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

Topic attachments
I Attachment History Action Size Date Who Comment
JPEGjpg invert1.jpg r1 manage 5.5 K 2007-07-02 - 03:03 MichaelRiley  
JPEGjpg invert2.jpg r1 manage 5.5 K 2007-07-02 - 03:03 MichaelRiley  
Edit | Attach | Watch | Print version | History: r3 < r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions...
Topic revision: r1 - 2007-07-02 - MichaelRiley
 
This site is powered by the TWiki collaboration platform Powered by PerlCopyright © 2008-2021 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback