class_docstr: Tests correctness of the Y = g(X) = expm1(X) transformation.
class_docstr_tok: ["Tests","correctness","of","the","Y","=","g","(","X",")","=","expm1","(","X",")","transformation","."]
code: def testBijector(self):
      bijector = expm1.Expm1()
      self.assertStartsWith(bijector.name, "expm1")
      x = [[[-1.0], [1.4]]]
      y = np.expm1(x)
      self.assertAllClose(y, self.evaluate(bijector.forward(x)))
      self.assertAllClose(x, self.evaluate(bijector.inverse(y)))
      self.assertAllClose(
          -np.squeeze(np.log1p(y), axis=-1),
          self.evaluate(
              bijector.inverse_log_det_jacobian(y, event_ndims=1)
          ),
      )
      self.assertAllClose(
          self.evaluate(
              -bijector.inverse_log_det_jacobian(
                  np.expm1(x), event_ndims=1
              )
          ),
          self.evaluate(
              bijector.forward_log_det_jacobian(x, event_ndims=1)
          ),
      )
  
file_path: probability/tensorflow_probability/python/bijectors/expm1_test.py
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.bijectors import bijector_test_util
  from tensorflow_probability.python.bijectors import expm1
  from tensorflow_probability.python.bijectors import invert
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 1 for calling the Expm1BijectorTest obj's underlying member method code with example usage: obj.testBijector() without return types