SPRAAK
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
spr_sel_gauss.c File Reference

Reduce the number of Gaussians in a mixture. More...

Detailed Description

Reduce the number of Gaussians in a mixture.

spr_sel_gauss <-i hmm_file> [-gi mvg_file] [-seli sel_file] [-u unit_fname] [-am_opt acmod_opt]
    [-o hmm_file] [-go hmm_file] [-selo sel_file] [-nu unit_fname] [-U Unit#s1:s2] [-S](flag: )
    [-N](flag: ) [-G](flag: ) [-origMVG](flag: ) [-nsel NrGaussPerState]
Parameters
-i<em>hmm_file</em><aname="spr_sel_gauss.i" class="el">
HMM-file to read.
-gi<em>mvg_file</em><aname="spr_sel_gauss.gi" class="el">
MVG-file to read. If specified, this MVG file is read instead of the MVG file given in the header of the input HMM.
-seli<em>sel_file</em><aname="spr_sel_gauss.seli" class="el">
SEL-file to read. If specified, this SELECT file is read instead of the SELECT file given in the header of the input HMM.
-u<em>unit_fname</em><aname="spr_sel_gauss.u" class="el">
UNIT-file to read. If specified, this unit file is used to read the input HMM instead of the file corresponding to the filename in the header of the input HMM.
-am_opt<em>acmod_opt</em><aname="spr_sel_gauss.am_opt" class="el">
Extra options for loading the acoustic model.
-o<em>hmm_file</em><aname="spr_sel_gauss.o" class="el">
HMM-file to write to. If not specified, the input HMM will be overwritten.
-go<em>hmm_file</em><aname="spr_sel_gauss.go" class="el">
MVG-file to write to. By default the input mvg file will be overwritten.
-selo<em>sel_file</em><aname="spr_sel_gauss.selo" class="el">
SEL-file to write to. By default is input sel file will be overwritten.
-nu<em>unit_fname</em><aname="spr_sel_gauss.nu" class="el">
Specify a new unit file to write the units to (or as input for rearanging the existing units).
-U<em>Unit\s1:s2</em><aname="spr_sel_gauss.U" class="el">
Selection of unit and statenumbers. If unit (denoted by its name string) is not specified, units are selected according to flags -S, -N and -G. If states (integers s1 and s2, 0 as first state) are not specified, all states of all selected units are selected. If only s1 is specified, and not s2, only s1 is selected. Else, s1 ... s2 are selected.
-Sflag
-S, -N and -G select Speech, Silence, and Garbage units respectively . Can be combined, but are overruled when a unit is selected with -U. If no units are selected with flags or with -U, default all units are selected.
-Nflag
See -S
-Gflag
See -S
-origMVGflag
If this flag is set, the gaussians that are useless when selection is done are not removed from the MVG file.
-nsel<em>NrGaussPerState</em><aname="spr_sel_gauss.nsel" class="el">
Indicates the number of gaussians per state for each of the mixtures. If one value is given, it is used for all mixtures. Else a value per mixture must be given. Separate values with a comma. The numbers can be preceded by a character to indicate the selection type.

Reduce the number of Gaussians in a mixture. Selects the best gaussians for each mixture of each state of a SC_HMM as indicated by option -nsel. The number of gaussians in a state can be limited in different ways, indicated by one character followed by the limit value:

  1. Character n (e.g. -nsel n64, or -nsel 64 as n is the default): Limit the Number of gaussians for a state to a fixed value. The gaussians with the largest weights are chosen.
  2. Character p: Select the gaussians with the largest weights untill a fixed Percentage of the total weight is reached.
  3. Character w: Limit the Weights to a fixed value: only larger weights are selected.
  4. Character o: Limit the occupancy for a gaussian: a weight is selected only if it is based on more frames than this value indicates (state occupancy should be saved during training).
  5. Character l: Limit the (estimate of the) loss in likelihood (probability loss times occupancy) when a gaussian is removed from the mixture for a state.

After selection, the resulting HMM is renormalised. Default, the gaussians that are not used in any state when selection is done, are removed in the output MVG. If flag -origMVG is set, the original MVG remains.

Revision History:
08/94, JD
creation
01/96, JD
adapted for new structures in hmm60
11/96, JD
speeded up sel_gauss
07/97, JD
rewritten for extended hmm structures (state-variable mixture dimension, linear or logarithmic probabilities in HMM, ...)
08/97, JD
sel_gauss extended for more selection methods