org.nd4j.linalg.util
Class FeatureUtil
- java.lang.Object
-
- org.nd4j.linalg.util.FeatureUtil
-
public class FeatureUtil extends java.lang.ObjectFeature matrix related utils
-
-
Constructor Summary
Constructors Constructor and Description FeatureUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method and Description static voidnormalizeMatrix(INDArray toNormalize)static voidscaleByMax(INDArray toScale)Divides each row by its maxstatic INDArraytoOutcomeMatrix(int[] index, int numOutcomes)Creates an out come vector from the specified inputsstatic INDArraytoOutcomeVector(int index, int numOutcomes)Creates an out come vector from the specified inputs
-
-
-
Method Detail
-
toOutcomeVector
public static INDArray toOutcomeVector(int index, int numOutcomes)
Creates an out come vector from the specified inputs- Parameters:
index- the index of the labelnumOutcomes- the number of possible outcomes- Returns:
- a binary label matrix used for supervised learning
-
toOutcomeMatrix
public static INDArray toOutcomeMatrix(int[] index, int numOutcomes)
Creates an out come vector from the specified inputs- Parameters:
index- the index of the labelnumOutcomes- the number of possible outcomes- Returns:
- a binary label matrix used for supervised learning
-
normalizeMatrix
public static void normalizeMatrix(INDArray toNormalize)
-
scaleByMax
public static void scaleByMax(INDArray toScale)
Divides each row by its max- Parameters:
toScale- the matrix to divide by its row maxes
-
-
DMelt 3.0 © DataMelt by jWork.ORG