public interface Feature
A single feature returned by the FeatureGenerator needs to support this interface.
| Modifier and Type | Method and Description |
|---|---|
Feature |
copy()
Gets a copy of the current feature
|
FeatureIdentifier |
getID()
One can quickly find out the index of the current feature according to its unique identifier
|
int |
getIndex()
The index of this feature from 0..numFeatures-1.
|
int |
getLabel()
has to be a label index from 0..numLabels-1
|
int |
getPrevLabel()
can be -1 if the feature is a state rather than an edge feature
|
double |
getValue() |
void |
setID(FeatureIdentifier id)
Sets the identitifer
|
void |
setIndex(int index)
Sets the index of the feature
|
void |
setLabel(int label)
Sets the label of the current feature
|
void |
setPrevLabel(int prevLabel)
Sets the label of the starting state of an edge feature if the current feature is an edge feature.
|
void |
setValue(double val)
Sets the value to the feature
|
FeatureIdentifier getID()
void setID(FeatureIdentifier id)
id - the feature identifierFeature copy()
int getIndex()
void setIndex(int index)
index - the index of the featureint getLabel()
void setLabel(int label)
label - the label of the featureint getPrevLabel()
void setPrevLabel(int prevLabel)
prevLabel - the label of the starting state of an edge featuredouble getValue()
void setValue(double val)
val - the value of the featureCopyright © 2018 JULIE Lab, Germany. All rights reserved.