OpenFst

Z MetaCentrum
Skočit na navigaci Skočit na vyhledávání

Description

OpenFst is a library for constructing, combining, optimizing, and searching weighted finite-state transducers (FSTs). Weighted finite-state transducers are automata where each transition has an input label, an output label, and a weight. The more familiar finite-state acceptor is represented as a transducer with each transition's input and output label equal. Finite-state acceptors are used to represent sets of strings (specifically, regular or rational sets); finite-state transducers are used to represent binary relations between pairs of strings (specifically, rational transductions). The weights can be used to represent the cost of taking a particular transition.

FSTs have key applications in speech recognition and synthesis, machine translation, optical character recognition, pattern matching, string processing, machine learning, information extraction and retrieval among others. Often a weighted transducer is used to represent a probabilistic model (e.g., an n-gram model, pronunciation model). FSTs can be optimized by determinization and minimization, models can be applied to hypothesis sets (also represented as automata) or cascaded by finite-state composition, and the best results can be selected by shortest-path algorithms.

License

open-source, distributed under the terms of the Apache license.

Usage

Upcoming modulesystem change alert!

Due to large number of applications and their versions it is not practical to keep them explicitly listed at our wiki pages. Therefore an upgrade of modulefiles is underway. A feature of this upgrade will be the existence of default module for every application. This default choice does not need version number and it will load some (usually latest) version.

You can test the new version now by adding a line

source /cvmfs/software.metacentrum.cz/modulefiles/5.1.0/loadmodules

to your script before loading a module. Then, you can list all versions of openfst and load default version of openfst as

module avail openfst/ # list available modules
module load openfst   # load (default) module


If you wish to keep up to the current system, it is still possible. Simply list all modules by

module avail openfst

and choose explicit version you want to use.

Running the application

  • ask for interactive task with one node and specified processors count (the ppn parameter)
$ qsub -I -l nodes=1:ppn=X -l mem=Yg

Also specify the memory size (the mem parameter) or any other task requirements.

  • call the application module into your system
$ module add openfst-1.1
  • Then simply run any command from OpenFST library with desired parameters. When you run any command with switch --help, will obtain simple manual:
$ fstcompose --help
Composes two FSTs.

  Usage: fstcompose in1.fst in2.fst [out.fst]
  Flags: connect filter

  Flags Description:
    --acceptor: type = bool, default = false
      Input in acceptor format
  
  ...atd.
  • Concatenation of some commands with use of the pipe brings an advantage to your work:
$ fstcompose <in1.fst <in2.fst | fstrmepsilon | fstminimize | fstdeterminize >out.fst

Documentation

Homepage

http://www.openfst.org/twiki/bin/view/FST/WebHome