Package org.apache.mahout.clustering.kernel

Examples of org.apache.mahout.clustering.kernel.TriangularKernelProfile


    } else {
      log.info("Running with default arguments");
      Path output = new Path("output");
      Configuration conf = new Configuration();
      HadoopUtil.delete(conf, output);
      run(conf, new Path("testdata"), output, new EuclideanDistanceMeasure(), new TriangularKernelProfile(), 47.6, 1,
          0.5, 10);
    }
  }
View Full Code Here


 
  public static void main(String[] args) throws Exception {
    t1 = 1.5;
    t2 = 0.5;
    DistanceMeasure measure = new EuclideanDistanceMeasure();
    IKernelProfile kernelProfile = new TriangularKernelProfile();
    significance = 0.02;
   
    Path samples = new Path("samples");
    Path output = new Path("output");
    Configuration conf = new Configuration();
View Full Code Here

 
  @Test
  public void testMeanShift() throws Exception {
    ClusteringTestUtils.writePointsToFile(sampleData, getTestTempFilePath("testdata/file1"), fs, conf);
    DistanceMeasure measure = new EuclideanDistanceMeasure();
    IKernelProfile kernelProfile = new TriangularKernelProfile();
    MeanShiftCanopyDriver.run(conf, testdata, output, measure, kernelProfile, 2.1, 1.0, 0.001, 10, false, true, true);
    int numIterations = 10;
    Path clustersIn = new Path(output, "clusters-2");
    RepresentativePointsDriver.run(conf, clustersIn, new Path(output, "clusteredPoints"), output, measure,
        numIterations, true);
View Full Code Here

  }
 
  @Test
  public void testMeanShift() throws Exception {
    DistanceMeasure measure = new CosineDistanceMeasure();
    IKernelProfile kernelProfile = new TriangularKernelProfile();
    Path output = getTestTempDirPath("output");
    Configuration conf = new Configuration();
    MeanShiftCanopyDriver.run(conf, getTestTempDirPath("testdata"), output,
        measure, kernelProfile, 0.5, 0.01, 0.05, 10, false, true, true);
    // run ClusterDumper
View Full Code Here

 
  @Test
  public void testMeanShift() throws Exception {
    ClusteringTestUtils.writePointsToFile(sampleData, new Path(testdata, "file1"), fs, conf);
    DistanceMeasure measure = new EuclideanDistanceMeasure();
    IKernelProfile kernelProfile = new TriangularKernelProfile();
    Configuration conf = new Configuration();
    MeanShiftCanopyDriver.run(conf, testdata, output, measure, kernelProfile, 2.1, 1.0, 0.001, 10, false, true, true);
    int numIterations = 10;
    Path clustersIn = new Path(output, "clusters-8-final");
    RepresentativePointsDriver.run(conf, clustersIn, new Path(output, "clusteredPoints"), output, measure,
View Full Code Here

   * test datapoints are clustered in a reasonable manner.
   */
  @Test
  public void testReferenceImplementation() {
    MeanShiftCanopyClusterer clusterer = new MeanShiftCanopyClusterer(
        new EuclideanDistanceMeasure(), new TriangularKernelProfile(), 4.0,
        1.0, 0.5, true);
    List<MeanShiftCanopy> canopies = Lists.newArrayList();
    // add all points to the canopies
    int nextCanopyId = 0;
    for (Vector aRaw : raw) {
View Full Code Here

TOP

Related Classes of org.apache.mahout.clustering.kernel.TriangularKernelProfile

Copyright © 2018 www.massapicom. 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.