public class CompositeSenone extends ScoreCachingSenone
senones
for a
given state. CompositeSenones are used when the exact context of a senone is not known. The CompositeSenone
represents all the possible senones.
This class currently only needs to be public for testing purposes.
Note that all scores are maintained in LogMath log base
Constructor and Description |
---|
CompositeSenone(Senone[] senones,
float weight)
Constructs a CompositeSenone given the set of constituent senones
|
Modifier and Type | Method and Description |
---|---|
float[] |
calculateComponentScore(Data feature)
Calculate scores for each component in the senone's distribution.
|
float |
calculateScore(Data feature)
Calculates the composite senone score.
|
static CompositeSenone |
create(java.util.Collection<Senone> senoneCollection,
float weight)
a factory method that creates a CompositeSenone from a list of senones.
|
void |
dump(java.lang.String msg)
Dumps this senone
|
boolean |
equals(java.lang.Object o)
Determines if two objects are equal
|
long |
getID()
Gets the ID for this senone
|
float[] |
getLogMixtureWeights() |
MixtureComponent[] |
getMixtureComponents()
Returns the mixture components associated with this Gaussian
|
Senone[] |
getSenones()
Returns the set of senones that compose this composite senone.
|
int |
hashCode()
Returns the hashcode for this object
|
java.lang.String |
toString()
Retrieves a string form of this object
|
getScore
public CompositeSenone(Senone[] senones, float weight)
senones
- the set of constituent senonesweight
- weigth for compositionpublic static CompositeSenone create(java.util.Collection<Senone> senoneCollection, float weight)
senoneCollection
- the Collection of senonesweight
- weigthpublic void dump(java.lang.String msg)
msg
- annotation for the dumppublic float calculateScore(Data feature)
calculateScore
in class ScoreCachingSenone
feature
- the feature vector to score this senone againstpublic float[] calculateComponentScore(Data feature)
feature
- the current featurepublic Senone[] getSenones()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
o
- the object to compare to this.public int hashCode()
hashCode
in class java.lang.Object
public long getID()
public java.lang.String toString()
toString
in class java.lang.Object
public MixtureComponent[] getMixtureComponents()
Senone
public float[] getLogMixtureWeights()