@JsonObject(value="FeatureVector")
public class FeatureVector
extends java.lang.Object
implements java.io.Serializable
Constructor and Description |
---|
FeatureVector(WellPosition well,
double[] values)
Creates an instance for the specified well assuming all features are numbers.
|
FeatureVector(WellPosition well,
double[] values,
boolean[] vocabularyFeatureFlags,
java.lang.String[] vocabularyTerms)
Creates an instance for the specified well.
|
Modifier and Type | Method and Description |
---|---|
java.util.List<java.lang.Object> |
getValueObjects()
Returns the feature vector as a list of objects.
|
double[] |
getValues()
Returns the array of numerical features.
|
boolean[] |
getVocabularyFeatureFlags()
Return the array of flags specifying the type of feature where
true means
vocabulary-based feature and false numerical feature. |
java.lang.String[] |
getVocabularyTerms()
Returns the array of vocabulary-based features.
|
WellPosition |
getWellPosition()
Returns the well position on a plate.
|
java.lang.String |
toString() |
public FeatureVector(WellPosition well, double[] values)
public FeatureVector(WellPosition well, double[] values, boolean[] vocabularyFeatureFlags, java.lang.String[] vocabularyTerms)
values
- Array with values of numerical features.vocabularyFeatureFlags
- Array telling which feature is a numerical one (
false
) or a vocabulary term (true
).vocabularyTerms
- Array with values of vocabulary-based features.java.lang.IllegalArgumentException
- if all arrays have not the same length.public WellPosition getWellPosition()
public double[] getValues()
Double.NaN
it means either
an unknown value of the numerical feature or a vocabulary-based feature.public final boolean[] getVocabularyFeatureFlags()
true
means
vocabulary-based feature and false
numerical feature.public final java.lang.String[] getVocabularyTerms()
null
it means
either an unknown value of the vocabulary-base feature or a numerical feature.public java.util.List<java.lang.Object> getValueObjects()
null
if the feature is unknown.public java.lang.String toString()
toString
in class java.lang.Object