code: def testTensorSpecSample(self, dtype):
      if dtype == tf.string or dtype == tf.bool:
          self.skipTest("Not compatible with string or bool type.")
      spec = tensor_spec.TensorSpec((2, 3), dtype)
      sample = tensor_spec.sample_spec_nest(spec)
      bounded = tensor_spec.BoundedTensorSpec.from_spec(spec)
  
      sample_ = self.evaluate(sample)
      self.assertTrue(
          np.all(sample_ >= bounded.minimum),
          (sample_.min(), sample_.max()),
      )
      self.assertTrue(
          np.all(sample_ <= bounded.maximum),
          (sample_.min(), sample_.max()),
      )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from absl.testing import parameterized
  import numpy
  import tensorflow
  from tf_agents.specs import array_spec
  from tf_agents.specs import tensor_spec
  from tf_agents.trajectories import time_step
label_desc: Use image node_id 4 for calling the BoundedTensorSpecSampleTest obj's underlying member method code with example usage: obj.testTensorSpecSample(dtype) without return types