@Test public void testSampler() { Iterable<Integer> sample = MemPipeline.collectionOf(1, 2, 3, 4, 5, 6, 7, 8, 9, 10) .sample(0.2, 123998).materialize(); List<Integer> sampleValues = ImmutableList.copyOf(sample); assertEquals(ImmutableList.of(6, 7), sampleValues); }
public static <S> PCollection<S> sample(PCollection<S> input, double probability) { return sample(input, System.currentTimeMillis(), probability); }
Sample { public static <S> PCollection<S> sample(PCollection<S> input, double probability) { return sample(input, System.currentTimeMillis(), probability); } }
Sample { public static <S> PCollection<S> sample(PCollection<S> input, double probability) { return sample(input, System.currentTimeMillis(), probability); }  }
Sample { public static <S> PCollection<S> sample(PCollection<S> input, double probability) { return sample(input, System.currentTimeMillis(), probability); }  static PCollection<S> sample(PCollection<S> input, double probability); static PCollection<S> sample(PCollection<S> input, long seed, double probability); }
Sample { public static <S> PCollection<S> sample(PCollection<S> input, double probability) { return sample(input, System.currentTimeMillis(), probability); }  static PCollection<S> sample(PCollection<S> input, double probability); static PCollection<S> sample(PCollection<S> input, long seed, double probability);  }