code: def test_transpose(self):
      class CustomizeModel(tl.models.Model):
          def __init__(self):
              super(CustomizeModel, self).__init__()
              self.transpose1 = tl.layers.Transpose()
              self.transpose2 = tl.layers.Transpose([2, 1, 0])
              self.transpose3 = tl.layers.Transpose([0, 2, 1])
              self.transpose4 = tl.layers.Transpose(conjugate=True)
  
          def forward(self, x):
              return (
                  self.transpose1(x),
                  self.transpose2(x),
                  self.transpose3(x),
                  self.transpose4(x),
              )
  
      real = np.random.random([8, 4, 3]).astype(np.float32)
      comp = np.random.random([8, 4, 3]).astype(np.float32)
      complex_data = real + 1j * comp
      model = CustomizeModel()
      print(model.transpose1)
      print(model.transpose2)
      print(model.transpose3)
      print(model.transpose4)
      model.train()
      out1, out2, out3, out4 = model(self.data)
      self.assertEqual(out1.get_shape().as_list(), [3, 4, 8])
      self.assertEqual(out2.get_shape().as_list(), [3, 4, 8])
      self.assertEqual(out3.get_shape().as_list(), [8, 3, 4])
      self.assertEqual(out4.get_shape().as_list(), [3, 4, 8])
      self.assertTrue(np.array_equal(out1.numpy(), out4.numpy()))
  
      out1, out2, out3, out4 = model(complex_data)
      self.assertEqual(out1.get_shape().as_list(), [3, 4, 8])
      self.assertEqual(out2.get_shape().as_list(), [3, 4, 8])
      self.assertEqual(out3.get_shape().as_list(), [8, 3, 4])
      self.assertEqual(out4.get_shape().as_list(), [3, 4, 8])
      self.assertTrue(
          np.array_equal(np.conj(out1.numpy()), out4.numpy())
      )
  
file_path: TensorLayer/tests/layers/test_layers_shape.py
imports: import os
  import unittest
  import numpy
  import tensorflow
  import tensorlayer
  from tests.utils import CustomTestCase
label_desc: Use image node_id 5 for calling the Layer_Shape_Test obj's underlying member method code with example usage: obj.test_transpose() and returns: self,  self,  self,  self