Examples of newCall()


Examples of org.apache.mahout.common.TimingStatistics.newCall()

    printStats(stats, measure.getClass().getName(), "Rand.fn(Seq)", "minDistance = " + result + ' ');
    result = 0;
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        double minDistance = Double.MAX_VALUE;
        for (int u = 0; u < opsPerUnit; u++) {
          double distance = measure.distance(vectors[2][i], vectors[0][u]);
          if (distance < minDistance) {
            minDistance = distance;
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

                                                                                + ' ');
    result = 0;
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        double minDistance = Double.MAX_VALUE;
        for (int u = 0; u < opsPerUnit; u++) {
          double distance = measure.distance(vectors[2][i], vectors[1][u]);
          if (distance < minDistance) {
            minDistance = distance;
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

 
  public void createBenchmark() {
    TimingStatistics stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[0][i] = new DenseVector(randomVectors.get(i));
        call.end();
      }
    }
    printStats(stats, "Create (copy)", "DenseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    printStats(stats, "Create (copy)", "DenseVector");
   
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[1][i] = new RandomAccessSparseVector(randomVectors.get(i));
        call.end();
      }
    }
    printStats(stats, "Create (copy)", "RandSparseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    printStats(stats, "Create (copy)", "RandSparseVector");
   
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[2][i] = new SequentialAccessSparseVector(randomVectors.get(i));
        call.end();
      }
    }
    printStats(stats, "Create (copy)", "SeqSparseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

 
  public void cloneBenchmark() {
    TimingStatistics stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[0][i] = vectors[0][i].clone();
        call.end();
      }
    }
    printStats(stats, "Clone", "DenseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    printStats(stats, "Clone", "DenseVector");
   
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[1][i] = vectors[1][i].clone();
        call.end();
      }
    }
    printStats(stats, "Clone", "RandSparseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    printStats(stats, "Clone", "RandSparseVector");
   
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vectors[2][i] = vectors[2][i].clone();
        call.end();
      }
    }
    printStats(stats, "Clone", "SeqSparseVector");
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    VectorWritable vec = new VectorWritable();
   
    TimingStatistics stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vec.set(vectors[0][i]);
        writer.append(one, vec);
        call.end();
      }
    }
View Full Code Here

Examples of org.apache.mahout.common.TimingStatistics.newCall()

    writer = new SequenceFile.Writer(fs, conf,
      new Path("/tmp/randsparse-vector"), IntWritable.class, VectorWritable.class);
    stats = new TimingStatistics();
    for (int l = 0; l < loop; l++) {
      for (int i = 0; i < numVectors; i++) {
        TimingStatistics.Call call = stats.newCall();
        vec.set(vectors[1][i]);
        writer.append(one, vec);
        call.end();
      }
    }
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.