class_docstr: Tests the correctness of the Y = JointMap({nested}) transformation.
code: def testBijectorWithDeepStructure(self):
      bij = joint_map.JointMap(
          {
              "a": exp.Exp(),
              "bc": joint_map.JointMap(
                  [scale.Scale(2.0), shift.Shift(3.0)]
              ),
          }
      )
  
      a = np.asarray(
          [[[1, 2], [2, 3]]], dtype=np.float32
      )  # shape=[1, 2, 2]
      b = np.asarray([[0, 4]], dtype=np.float32)  # shape=[1, 2]
      c = np.asarray([[5, 6]], dtype=np.float32)  # shape=[1, 2]
  
      inputs = {
          "a": a,
          "bc": [b, c],
      }  # Could be inputs to forward or inverse.
      event_ndims = {"a": 1, "bc": [0, 0]}
  
      self.assertStartsWith(
          bij.name, "jointmap_of_exp_and_jointmap_of_"
      )
      self.assertAllCloseNested(
          {"a": np.exp(a), "bc": [b * 2.0, c + 3]},
          self.evaluate(bij.forward(inputs)),
      )
      self.assertAllCloseNested(
          {"a": np.log(a), "bc": [b / 2.0, c - 3]},
          self.evaluate(bij.inverse(inputs)),
      )
  
      fldj = self.evaluate(
          bij.forward_log_det_jacobian(inputs, event_ndims)
      )
      self.assertEqual((1, 2), fldj.shape)
      self.assertAllClose(np.sum(a, axis=-1) + np.log(2), fldj)
  
      ildj = self.evaluate(
          bij.inverse_log_det_jacobian(inputs, event_ndims)
      )
      self.assertEqual((1, 2), ildj.shape)
      self.assertAllClose(-np.log(a).sum(axis=-1) - np.log(2), ildj)
  
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.bijectors import bijector_test_util
  from tensorflow_probability.python.bijectors import exp
  from tensorflow_probability.python.bijectors import invert
  from tensorflow_probability.python.bijectors import joint_map
  from tensorflow_probability.python.bijectors import ldj_ratio
  from tensorflow_probability.python.bijectors import reshape
  from tensorflow_probability.python.bijectors import scale
  from tensorflow_probability.python.bijectors import shift
  from tensorflow_probability.python.bijectors import softplus
  from tensorflow_probability.python.internal import test_util
label_desc: Use image node_id 3 for calling the JointMapBijectorTest obj's underlying member method code with example usage: obj.testBijectorWithDeepStructure() without return types