|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.stanford.nlp.sequences.Clique
public class Clique
This class is meant to represent a clique in a (directed or undirected) linear-chain graphical model. It encodes the relative indices that are included in a clique with respect to the current index (0). For instance if you have a clique that is current label and two-ago label, then the relative indices clique would look like [-2, 0]. The relativeIndices[] array should be sorted. Cliques are immutable. Also, for two cliques, c1 and c2, (c1 == c2) iff c1.equals(c2).
Field Summary | |
---|---|
protected static Map<edu.stanford.nlp.sequences.Clique.CliqueEqualityWrapper,Clique> |
interner
|
protected static long |
serialVersionUID
|
Method Summary | |
---|---|
int |
hashCode()
|
int |
indexOfRelativeIndex(int relativeIndex)
For a particular relative index, returns which element in the Clique it is. |
Clique |
leftMessage()
|
int |
maxLeft()
Convenience method for finding the most far left relative index. |
int |
maxRight()
Convenience method for finding the most far right relative index. |
Object |
readResolve()
|
int |
relativeIndex(int i)
|
Clique |
rightMessage()
|
Clique |
shift(int shiftAmount)
|
int |
size()
The number of nodes in the clique. |
String |
toString()
|
static Clique |
valueOf(Clique c,
int offset)
|
static Clique |
valueOf(int[] relativeIndices)
relativeIndices should be sorted. |
static Clique |
valueOf(int maxLeft,
int maxRight)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static final long serialVersionUID
protected static Map<edu.stanford.nlp.sequences.Clique.CliqueEqualityWrapper,Clique> interner
Method Detail |
---|
public static Clique valueOf(int maxLeft, int maxRight)
public static Clique valueOf(int[] relativeIndices)
public static Clique valueOf(Clique c, int offset)
public int maxLeft()
public int maxRight()
public int size()
public int relativeIndex(int i)
public int indexOfRelativeIndex(int relativeIndex)
public String toString()
toString
in class Object
public Clique leftMessage()
public Clique rightMessage()
public Clique shift(int shiftAmount)
public int hashCode()
hashCode
in class Object
public Object readResolve()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |