Package org.apache.mahout.math.list

Examples of org.apache.mahout.math.list.IntArrayList.quickSort()


  /* Y' Y */
  private Matrix getYtransposeY(OpenIntObjectHashMap<Vector> Y) {

    IntArrayList indexes = Y.keys();
    indexes.quickSort();
    int numIndexes = indexes.size();

    double[][] YtY = new double[numFeatures][numFeatures];

    // Compute Y'Y by dot products between the 'columns' of Y
View Full Code Here


  /* Y' Y */
  private Matrix YtransposeY(OpenIntObjectHashMap<Vector> Y) {

    Matrix compactedY = new DenseMatrix(Y.size(), numFeatures);
    IntArrayList indexes = Y.keys();
    indexes.quickSort();

    int row = 0;
    for (int index : indexes.elements()) {
      compactedY.assignRow(row++, Y.get(index));
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.