cc.mallet.grmm.util
Class LabelsAssignment

java.lang.Object
  extended by cc.mallet.grmm.types.AbstractFactor
      extended by cc.mallet.grmm.types.Assignment
          extended by cc.mallet.grmm.util.LabelsAssignment
All Implemented Interfaces:
Factor, AlphabetCarrying, java.io.Serializable, java.lang.Cloneable

public class LabelsAssignment
extends Assignment
implements AlphabetCarrying

A special kind of assignment for Variables that can be arranged in a LabelsSequence. This is an Adaptor to adapt LabelsSequences to Assignments.

$Id: LabelsAssignment.java,v 1.1 2007/10/22 21:37:58 mccallum Exp $

See Also:
Serialized Form

Field Summary
 
Fields inherited from class cc.mallet.grmm.types.AbstractFactor
vars
 
Constructor Summary
LabelsAssignment(LabelsSequence lbls)
           
 
Method Summary
 Alphabet getAlphabet()
           
 Alphabet[] getAlphabets()
           
 LabelsSequence getLabelsSequence()
           
 LabelAlphabet getOutputAlphabet(int lvl)
           
 Label labelOfVar(Variable var)
           
 int maxTime()
           
 int numSlices()
           
 LabelsSequence toLabelsSequence(Assignment assn)
           
 Variable varOfIndex(int t, int j)
           
 
Methods inherited from class cc.mallet.grmm.types.Assignment
addRow, addRow, addRow, addRow, addRow, almostEquals, asList, asTable, containsVar, dump, dump, dumpNumeric, dumpToString, duplicate, extractMaxInternal, get, get, getColumnInt, getDouble, getDouble, getObject, getObject, getRow, getVariable, getVars, isNaN, lookupValueInternal, makeFromSingleIndex, marginalizeInternal, normalize, numRows, numVariables, restriction, sample, setDouble, setRow, setRow, setValue, setValue, singleIndex, singleIndex, size, slice, subAssn, toDoubleArray, union
 
Methods inherited from class cc.mallet.grmm.types.AbstractFactor
almostEquals, argmax, assignmentIterator, delogify, divideBy, entropy, exponentiate, extractMax, extractMax, extractMax, isInLogSpace, log, logify, logValue, logValue, logValue, marginalize, marginalize, marginalize, marginalizeOut, marginalizeOut, multiply, multiplyBy, phi, prettyOutputString, setVarSet, sum, value, value, varSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LabelsAssignment

public LabelsAssignment(LabelsSequence lbls)
Method Detail

varOfIndex

public Variable varOfIndex(int t,
                           int j)

labelOfVar

public Label labelOfVar(Variable var)

maxTime

public int maxTime()

numSlices

public int numSlices()

getLabelsSequence

public LabelsSequence getLabelsSequence()

toLabelsSequence

public LabelsSequence toLabelsSequence(Assignment assn)

getOutputAlphabet

public LabelAlphabet getOutputAlphabet(int lvl)

getAlphabet

public Alphabet getAlphabet()
Specified by:
getAlphabet in interface AlphabetCarrying

getAlphabets

public Alphabet[] getAlphabets()
Specified by:
getAlphabets in interface AlphabetCarrying