Examples of MotifDataGenerator


Examples of com.facebook.LinkBench.generators.MotifDataGenerator

  public void testTimingMotif() {
    System.err.println("Testing motif generator");
    System.err.println("=========================");
    DataGenFactory fact = new DataGenFactory() {
      public DataGenerator make(double param) {
        MotifDataGenerator gen = new MotifDataGenerator();
        gen.init(08, param);
        return gen;
      }
    };
    testTiming(fact, 128);
    testTiming(fact, 1024);
View Full Code Here

Examples of com.facebook.LinkBench.generators.MotifDataGenerator

   *
   * Currently difficult to automatically verify output.
   */
  @Test
  public void testMotif() {
    MotifDataGenerator gen = new MotifDataGenerator();

    System.err.println("uniqueness 0.25");
    gen.init(0, 8, 0.25);
    byte data[] = gen.fill(new Random(), new byte[64]);
    printByteGrid(data);

    System.err.println("uniqueness 0.0");
    gen.init(0, 8, 0.0);
    data = gen.fill(new Random(), new byte[64]);
    printByteGrid(data);

    System.err.println("uniqueness 0.05");
    gen.init(0, 8, 0.05);
    data = gen.fill(new Random(), new byte[64]);
    printByteGrid(data);

    System.err.println("uniqueness 1.0");
    gen.init(0, 8, 1.0);
    data = gen.fill(new Random(), new byte[64]);
    printByteGrid(data);
  }
View Full Code Here

Examples of com.facebook.LinkBench.generators.MotifDataGenerator

   * compressing a long stream of the data
   * @throws IOException
   */
  @Test
  public void testCompressibility() throws IOException {
    MotifDataGenerator gen = new MotifDataGenerator();
    gen.init(0, 255, 0.5);
    System.err.println("\nUniqueness=0.5 Range=255\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);

    gen.init(0, 127, 0.5);
    System.err.println("\nUniqueness=0.5 Range=127\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);

    gen.init(0, 255, 0.0);
    System.err.println("\nUniqueness=0.0 Range=255\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);

    gen.init(0, 255, 1.0);
    System.err.println("\nUniqueness=1.0 Range=255\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);
    gen.init(0, 255, 1.0);

    gen.init(0, 127, 1.0);
    System.err.println("\nUniqueness=1.0 Range=127\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);

    gen.init(0, 1, 1.0);
    System.err.println("\nUniqueness=1.0 Range=1\n===============");
    testCompressibility(gen, 1024, 10000);
    testCompressibility(gen, 64, 1);
  }
View Full Code Here

Examples of com.facebook.LinkBench.generators.MotifDataGenerator

    gen.init(50, 75);
    return gen;
  }

  private static MotifDataGenerator makeMotifObj() {
    MotifDataGenerator gen = new MotifDataGenerator();
    int start = 50;
    int end = 220;
    double uniqueness = 0.63;
    gen.init(start, end, uniqueness);
    return gen;
  }
View Full Code Here

Examples of com.facebook.LinkBench.generators.MotifDataGenerator

    gen.init(50, 75);
    return gen;
  }

  private static MotifDataGenerator makeMotifAssoc() {
    MotifDataGenerator gen = new MotifDataGenerator();
    int start = 32;
    int end = 100;
    double uniqueness = 0.225;
    int motifSize = 128;
    gen.init(start, end, uniqueness, motifSize);
    return gen;
  }
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.