|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.cmu.sphinx.result.Sausage
public class Sausage
A Sausage is a sequence of confusion sets, one for each position in an utterance.
| Constructor Summary | |
|---|---|
Sausage(int size)
Construct a new sausage. |
|
| Method Summary | |
|---|---|
void |
addWordHypothesis(int position,
java.lang.String word,
double confidence,
LogMath logMath)
|
void |
addWordHypothesis(int position,
WordResult word)
Add a word hypothesis to a given word slot in the sausage. |
int |
countWordHypotheses()
|
void |
dumpAISee(java.lang.String fileName,
java.lang.String title)
Write this sausage to an aisee format text file. |
void |
fillInBlanks(LogMath logMath)
Adds skip elements for each word slot in which the word posteriors do not add up to linear 1. |
Path |
getBestHypothesis()
Returns the best hypothesis of the result. |
Path |
getBestHypothesisNoFiller()
Get the best hypothesis path discarding any filler words. |
java.lang.String |
getBestHypothesisString()
Get a string representing the best path through the sausage. |
java.util.Set<WordResult> |
getBestWordHypothesis(int pos)
Get the word hypothesis with the highest posterior for a word slot |
double |
getBestWordHypothesisPosterior(int pos)
Get the the highest posterior for a word slot |
ConfusionSet |
getConfusionSet(int pos)
Get the confusion set stored in a given word slot. |
java.util.Iterator<ConfusionSet> |
iterator()
Get an iterator for the sausage. |
void |
removeFillers()
Remove all filler words from the sausage. |
int |
size()
size of this sausage in word slots. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public Sausage(int size)
size - The number of word slots in the sausage| Method Detail |
|---|
public java.util.Iterator<ConfusionSet> iterator()
iterator in interface java.lang.Iterable<ConfusionSet>public void fillInBlanks(LogMath logMath)
logMath - the log math object to use for probability computations
public void addWordHypothesis(int position,
WordResult word)
position - the position to add a hypothesis toword - the word to add
public void addWordHypothesis(int position,
java.lang.String word,
double confidence,
LogMath logMath)
public Path getBestHypothesis()
ConfidenceResult
getBestHypothesis in interface ConfidenceResultConfidenceResult.getBestHypothesis()public Path getBestHypothesisNoFiller()
public void removeFillers()
public java.lang.String getBestHypothesisString()
public java.util.Set<WordResult> getBestWordHypothesis(int pos)
pos - the word slot to look at
public double getBestWordHypothesisPosterior(int pos)
pos - the word slot to look at
public ConfusionSet getConfusionSet(int pos)
getConfusionSet in interface ConfidenceResultpos - the word slot to look at.
public int countWordHypotheses()
public int size()
size in interface ConfidenceResult
public void dumpAISee(java.lang.String fileName,
java.lang.String title)
fileName - The file to write to.title - the title to give the graph.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||