|
Sautrela | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.gtts.sautrela.wfsa.models.LMM
public class LMM
| Nested Class Summary | |
|---|---|
class |
LMM.LayerConnectionException
|
static class |
LMM.TopLayer
|
class |
LMM.xState
|
class |
LMM.xTransition
|
| Nested classes/interfaces inherited from interface edu.gtts.sautrela.wfsa.WFSA |
|---|
WFSA.Factory |
| Field Summary | |
|---|---|
static WFSA.Factory |
myFactory
|
| Constructor Summary | |
|---|---|
LMM()
Creates a new instance of LMM |
|
| Method Summary | |
|---|---|
void |
addLayer(WFSASet wfsaset)
Adds a new layer on the top of this LMM |
void |
addLayer(WFSASet wfsaset,
double scale,
double offset)
Adds a new layer on the top of this LMM |
void |
addTopLayer(LMM.TopLayer type)
|
void |
addTopLayer(LMM.TopLayer type,
double scale,
double offset)
|
void |
addTopLayer(WFSA _wfsa)
|
void |
addTopLayer(WFSA _wfsa,
double scale,
double offset)
|
void |
checkBottomUp()
|
void |
dumpTrainCounts()
Dumps the trained data to any WFSA model at any layer. |
Alphabet<Symbol> |
getAlphabet()
Returns the alphabet of the Model. |
double |
getFinProb(LMM.xState state)
Returns the probability of being final |
LMM.xState |
getIniState()
Returns the initial State |
java.lang.String |
getName()
Returns the name of the Model. |
static java.lang.String |
getPathInfo(Path<LMM.xState,LMM.xTransition> p)
|
LMM.xTransition |
getRandomTrans(LMM.xState from)
Returns a random transitions from a state |
LMM.xTransition[] |
getTrans(LMM.xState from)
Returns all possible transitions from a state. |
LMM.xTransition[] |
getTrans(LMM.xState from,
Symbol symbol)
Returns all possible transitions for the given source state and symbol. |
void |
incrementTrainCount(LMM.xState state,
double count)
Increments the training counts of each model/state pair of the given LMMSate. |
void |
incrementTrainCount(LMM.xTransition t,
double count)
Increments the training counts of a given LMMTransition. |
void |
initTrainCounts(double initCount)
Initializes the training counts of any WFSA model
at any layer. |
static void |
main(java.lang.String[] args)
LMM - create Layered Markov Model from WFSASets. |
void |
setName(java.lang.String name)
Sets the name of the LMM. |
java.lang.String |
toString()
Returns a string representation of the object. |
java.lang.String |
toXML()
Returns a XML representation of the WFSA |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final WFSA.Factory myFactory
| Constructor Detail |
|---|
public LMM()
| Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Objectpublic void setName(java.lang.String name)
name - the name of this LMM
public void addLayer(WFSASet wfsaset)
throws LMM.LayerConnectionException
wfsaset - the WFSASet that represents the layer to be added.
LMM.LayerConnectionException
public void addLayer(WFSASet wfsaset,
double scale,
double offset)
throws LMM.LayerConnectionException
wfsaset - the WFSASet that represents the layer to be added.
LMM.LayerConnectionException
public void addTopLayer(WFSA _wfsa)
throws LMM.LayerConnectionException
LMM.LayerConnectionException
public void addTopLayer(WFSA _wfsa,
double scale,
double offset)
throws LMM.LayerConnectionException
LMM.LayerConnectionException
public void checkBottomUp()
throws LMM.LayerConnectionException
LMM.LayerConnectionException
public void addTopLayer(LMM.TopLayer type)
throws LMM.LayerConnectionException
LMM.LayerConnectionException
public void addTopLayer(LMM.TopLayer type,
double scale,
double offset)
throws LMM.LayerConnectionException
LMM.LayerConnectionExceptionpublic java.lang.String getName()
WFSA
getName in interface WFSA<LMM.xState,Symbol,LMM.xTransition>public Alphabet<Symbol> getAlphabet()
WFSA
getAlphabet in interface WFSA<LMM.xState,Symbol,LMM.xTransition>Alphabetpublic LMM.xState getIniState()
WFSA
getIniState in interface WFSA<LMM.xState,Symbol,LMM.xTransition>public double getFinProb(LMM.xState state)
WFSA
getFinProb in interface WFSA<LMM.xState,Symbol,LMM.xTransition>public LMM.xTransition[] getTrans(LMM.xState from)
WFSA
getTrans in interface WFSA<LMM.xState,Symbol,LMM.xTransition>from - The source State
array must be returned.public LMM.xTransition getRandomTrans(LMM.xState from)
WFSA
getRandomTrans in interface WFSA<LMM.xState,Symbol,LMM.xTransition>from - The source State
public LMM.xTransition[] getTrans(LMM.xState from,
Symbol symbol)
NdWFSA
getTrans in interface NdWFSA<LMM.xState,Symbol,LMM.xTransition>from - the source Statesymbol - the observed symbol
array must be returned.public void initTrainCounts(double initCount)
WFSA model
at any layer.
initTrainCounts in interface WFSA<LMM.xState,Symbol,LMM.xTransition>initCount - initial posterior probability count
public void incrementTrainCount(LMM.xState state,
double count)
LMMSate. These counts are related to the final probability
of a State.
incrementTrainCount in interface WFSA<LMM.xState,Symbol,LMM.xTransition>state - the final LMMSatecount - the training count.
public void incrementTrainCount(LMM.xTransition t,
double count)
LMMTransition. The
count contributes to all (final or internal) Transition-s that
generated the MetaTransition
incrementTrainCount in interface WFSA<LMM.xState,Symbol,LMM.xTransition>t - the Transitioncount - the training count.public void dumpTrainCounts()
WFSA model at any layer.
dumpTrainCounts in interface WFSA<LMM.xState,Symbol,LMM.xTransition>public java.lang.String toXML()
toXML in interface WFSA<LMM.xState,Symbol,LMM.xTransition>public static java.lang.String getPathInfo(Path<LMM.xState,LMM.xTransition> p)
public static void main(java.lang.String[] args)
Syntax: LMM [-uncheck] [-d int] name < -e | -s | wfsa > [a b] wfsaset [a b] [wfsaset [a b]]...
-uncheck avoids doing layer check.
-d int The index [0,n-1] of the Layer used for decoding (default to n-1, top-layer)
name The name of the resulting LMM
-e Equiprobable (see TopLayer.EQPROB).
-s Selector (see TopLayer.SELECTOR).
wsfa Use the given automaton as top Layer.
a Log scale applied to this layer probabilities.
b Log offset applied to this layer probabilities.
wsfaset Add the given automata as next Layer.
args - Command line arguments.
|
Sautrela | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||