public class SequencePath extends Object implements Comparable<SequencePath>, Serializable
Modifier and Type | Field and Description |
---|---|
static String |
SEQDELIM
This delimiter is used in the construction of artificial features
representing transitions for the
SequenceClassificationLearningAlgorithm
|
Constructor and Description |
---|
SequencePath() |
Modifier and Type | Method and Description |
---|---|
void |
add(SequenceEmission sequenceLabel) |
int |
compareTo(SequencePath o) |
Label |
getAssignedLabel(int i) |
List<SequenceEmission> |
getAssignedSequnceLabels() |
String |
getHistoryBefore(int targetId,
int historySize)
This method generate a string representing an artificial feature used in
the labeling process.
|
Double |
getScore() |
void |
setAssignedSequenceLabels(List<SequenceEmission> assignedLabels) |
void |
setScore(Double score) |
String |
toString() |
public static final String SEQDELIM
SequenceClassificationLearningAlgorithm
- See Also:
- Constant Field Values
-
Method Detail
-
add
public void add(SequenceEmission sequenceLabel)
- Parameters:
sequenceLabel
- A sequence label to be added at the end of this list
-
compareTo
public int compareTo(SequencePath o)
- Specified by:
compareTo
in interface Comparable<SequencePath>
-
getAssignedLabel
public Label getAssignedLabel(int i)
- Parameters:
i
- the index of the targeted element
- Returns:
- the label assigned to the i-th element
-
getAssignedSequnceLabels
public List<SequenceEmission> getAssignedSequnceLabels()
- Returns:
- The collection of
SequenceLabel
s produced during the
sequence labeling process
-
getHistoryBefore
public String getHistoryBefore(int targetId,
int historySize)
This method generate a string representing an artificial feature used in
the labeling process. In particular it reflects the $h$ labels preceding
a targeted element.
- Parameters:
targetId
- the index of the element whose previous labels are requiredhistorySize
- the number of labels to return
- Returns:
- a string that is the concatenation of labels preceding a targeted
element in the sequence
-
getScore
public Double getScore()
- Returns:
- the score assigned to this labeling
-
setAssignedSequenceLabels
public void setAssignedSequenceLabels(List<SequenceEmission> assignedLabels)
- Parameters:
assignedLabels
- The collection of SequenceLabel
s produced during
the sequence labeling process
-
setScore
public void setScore(Double score)
- Parameters:
score
- the score assigned to this labeling
Copyright © 2018 Semantic Analytics Group @ Uniroma2. All rights reserved.