def testZipfSampleMultipleTimes(self):
    n = 1000
    seed = test_util.test_seed()
    power = 1.5
    zipf1 = tfd.Zipf(power=power, name='zipf1', validate_args=True)
    tf.random.set_seed(seed)
    samples1 = self.evaluate(zipf1.sample(n, seed=seed))
    zipf2 = tfd.Zipf(power=power, name='zipf2', validate_args=True)
    tf.random.set_seed(seed)
    samples2 = self.evaluate(zipf2.sample(n, seed=seed))
    self.assertAllEqual(samples1, samples2)
def testZipfSampleMultipleTimes(self):
    n = 1000
    seed = test_util.test_seed()
    power = 1.5
    zipf1 = tfd.Zipf(power=power, name='zipf1', validate_args=True)
    tf.random.set_seed(seed)
    samples1 = self.evaluate(zipf1.sample(n, seed=seed))
    zipf2 = tfd.Zipf(power=power, name='zipf2', validate_args=True)
    tf.random.set_seed(seed)
    samples2 = self.evaluate(zipf2.sample(n, seed=seed))
    self.assertAllEqual(samples1, samples2)