|
|
|||||||||||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectde.lmu.ifi.dbs.elki.logging.AbstractLoggable
de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable
de.lmu.ifi.dbs.elki.normalization.AbstractNormalization<V>
de.lmu.ifi.dbs.elki.normalization.AttributeWiseMinMaxNormalization<V>
V
- vector typepublic class AttributeWiseMinMaxNormalization<V extends RealVector<V,?>>
Class to perform and undo a normalization on real vectors with respect to given minimum and maximum in each dimension.
Field Summary | |
---|---|
private double[] |
maxima
Stores the maximum in each dimension. |
static OptionID |
MAXIMA_ID
OptionID for MAXIMA_PARAM |
private DoubleListParameter |
MAXIMA_PARAM
Parameter for maximum. |
private double[] |
minima
Stores the minimum in each dimension. |
static OptionID |
MINIMA_ID
OptionID for MINIMA_PARAM |
private DoubleListParameter |
MINIMA_PARAM
Parameter for minimum. |
Fields inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
---|
optionHandler |
Fields inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
---|
debug, logger |
Constructor Summary | |
---|---|
AttributeWiseMinMaxNormalization()
Sets minima and maxima parameter to the optionhandler. |
Method Summary | |
---|---|
private void |
determineMinMax(List<Pair<V,Associations>> objectAndAssociationsList)
Determines the minima and maxima values in each dimension of the given featureVectors. |
private void |
determineMinMax(V[] featureVectors)
Determines the minima and maxima values in each dimension of the given featureVectors. |
private double |
factor(int dimension)
Returns a factor for normalization in a certain dimension. |
private void |
initMinMax(int dimensionality)
Initializes the min and max array. |
List<V> |
normalize(List<V> featureVectors)
Performs a normalization on a set of feature vectors. |
List<Pair<V,Associations>> |
normalizeObjects(List<Pair<V,Associations>> objectAndAssociationsList)
Performs a normalization on a list of database objects and their associations. |
List<V> |
restore(List<V> featureVectors)
Transforms a set of feature vectores to the original attribute ranges. |
V |
restore(V featureVector)
Transforms a feature vector to the original attribute ranges. |
List<String> |
setParameters(List<String> args)
Sets the attributes of the class accordingly to the given parameters. |
String |
toString(String pre)
Returns a string representation of this normalization. |
LinearEquationSystem |
transform(LinearEquationSystem linearEquationSystem)
Transforms a linear equation system describing linear dependencies derived on the normalized space into a linear equation system describing linear dependencies quantitatively adapted to the original space. |
private void |
updateMinMax(V featureVector)
Updates the min and max array according to the specified feature vector. |
Methods inherited from class de.lmu.ifi.dbs.elki.normalization.AbstractNormalization |
---|
toString |
Methods inherited from class de.lmu.ifi.dbs.elki.utilities.optionhandling.AbstractParameterizable |
---|
addOption, addParameterizable, addParameterizable, checkGlobalParameterConstraints, collectOptions, getAttributeSettings, getParameters, rememberParametersExcept, removeOption, removeParameterizable, shortDescription |
Methods inherited from class de.lmu.ifi.dbs.elki.logging.AbstractLoggable |
---|
debugFine, debugFiner, debugFinest, exception, progress, verbose, warning |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface de.lmu.ifi.dbs.elki.utilities.optionhandling.Parameterizable |
---|
checkGlobalParameterConstraints, collectOptions, getParameters, shortDescription |
Field Detail |
---|
public static final OptionID MINIMA_ID
MINIMA_PARAM
public static final OptionID MAXIMA_ID
MAXIMA_PARAM
private final DoubleListParameter MINIMA_PARAM
private final DoubleListParameter MAXIMA_PARAM
private double[] maxima
private double[] minima
Constructor Detail |
---|
public AttributeWiseMinMaxNormalization()
Method Detail |
---|
public List<Pair<V,Associations>> normalizeObjects(List<Pair<V,Associations>> objectAndAssociationsList) throws NonNumericFeaturesException
Normalization
objectAndAssociationsList
- the list of database objects and their associations
NonNumericFeaturesException
- if feature vectors differ in length or values are not
suitable to normalizationpublic List<V> normalize(List<V> featureVectors) throws NonNumericFeaturesException
Normalization
featureVectors
- a set of feature vectors to be normalized
NonNumericFeaturesException
- if feature vectors differ in length or values are not
suitable to normalizationpublic V restore(V featureVector) throws NonNumericFeaturesException
Normalization
featureVector
- a feature vector to be transformed into original space
NonNumericFeaturesException
- feature vector is not compatible with values initialized
during normalizationpublic List<V> restore(List<V> featureVectors) throws NonNumericFeaturesException
Normalization
featureVectors
- a set of feature vectors to be transformed into original space
NonNumericFeaturesException
- if feature vectors differ in length or are not compatible
with values initialized during normalizationpublic LinearEquationSystem transform(LinearEquationSystem linearEquationSystem)
Normalization
linearEquationSystem
- the linear equation system to be transformed
public String toString(String pre)
pre
- the prefix of each new line
public List<String> setParameters(List<String> args) throws ParameterException
setParameters
in interface Parameterizable
setParameters
in class AbstractParameterizable
args
- parameters to set the attributes accordingly to
IllegalArgumentException
- in case of wrong parameter-setting
ParameterException
- in case of wrong parameter-settingprivate double factor(int dimension)
dimension
- the dimension to get a factor for normalization
private void determineMinMax(V[] featureVectors)
featureVectors
- the list of feature vectorsprivate void determineMinMax(List<Pair<V,Associations>> objectAndAssociationsList)
objectAndAssociationsList
- the list of feature vectors and their
associationsprivate void initMinMax(int dimensionality)
dimensionality
- the dimensionality of the feature vectors to be
normalizedprivate void updateMinMax(V featureVector)
featureVector
- the feature vector
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |