code: def testSampleDeterministicScalarVsVector(self):
      prob = [0.2, 0.6]
      dist = continuous_bernoulli.ContinuousBernoulli(
          probs=prob, validate_args=True
      )
      n = 1000
  
      def _seed(seed=None):
          seed = test_util.test_seed() if seed is None else seed
          if tf.executing_eagerly():
              tf1.set_random_seed(seed)
          return seed
  
      seed = _seed()
      self.assertAllClose(
          self.evaluate(dist.sample(n, _seed(seed=seed))),
          self.evaluate(dist.sample([n], _seed(seed=seed))),
      )
      n = tf1.placeholder_with_default(np.int32(1000), shape=None)
      seed = _seed()
      sample1 = dist.sample(n, _seed(seed=seed))
      sample2 = dist.sample([n], _seed(seed=seed))
      sample1, sample2 = self.evaluate([sample1, sample2])
      self.assertAllClose(sample1, sample2)
  
imports: import numpy
  from scipy import special
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import continuous_bernoulli
  from tensorflow_probability.python.distributions import kullback_leibler
  from tensorflow_probability.python.internal import tensorshape_util
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 19 for calling the ContinuousBernoulliTest obj's underlying member method code with example usage: obj.testSampleDeterministicScalarVsVector() and returns: seed