code: def testLog1p(self):
      # Check that we can tell that log1p is a good idea
  
      def bad_log1p(x):
          # Extra indirection to fool Grappler in TF1
          return tf.math.log(((1.0 + x) - 1.0) + 1.0)
  
      small = tf.constant(1e-7, dtype=tf.float32)
      self.assertGreater(
          self.evaluate(nt.excess_wrong_bits(bad_log1p, small)), 21
      )
  
      self.assertLessEqual(
          self.evaluate(nt.excess_wrong_bits(tf.math.log1p, small)), 0
      )
  
imports: import tensorflow.compat.v2
  from tensorflow_probability.python.internal import numerics_testing
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 2 for calling the NumericsTestingTest obj's underlying member method code with example usage: obj.testLog1p() and returns: tf