code: def testSampleBatch(self):
      action_spec = tensor_spec.BoundedTensorSpec(
          [_ACTION_SIZE], tf.float32, 0.0, 1.0
      )
      sampler = (
          qtopt_cem_actions_sampler_continuous.GaussianActionsSampler(
              action_spec=action_spec,
              sample_rejecters=dummy_sample_rejecter,
          )
      )
  
      mean = tf.constant(_MEAN)
      var = tf.constant(_VAR)
      mean = tf.broadcast_to(mean, [_BATCH, _ACTION_SIZE])
      var = tf.broadcast_to(var, [_BATCH, _ACTION_SIZE])
  
      actions = sampler.sample_batch_and_clip(_NUM_SAMPLES, mean, var)
  
      actions_ = self.evaluate(actions)
      self.assertEqual(
          (_BATCH, _NUM_SAMPLES, _ACTION_SIZE), actions_.shape
      )
      self.assertTrue((actions_ <= action_spec.maximum).all())
      self.assertTrue((actions_ >= action_spec.minimum).all())
  
file_path: agents/tf_agents/policies/samplers/qtopt_cem_actions_sampler_continuous_test.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import tensorflow
  from tf_agents.policies.samplers import qtopt_cem_actions_sampler_continuous
  from tf_agents.specs import tensor_spec
label_desc: Use image node_id 1 for calling the ActionsSamplerTest obj's underlying member method code with example usage: obj.testSampleBatch() without return types