code: def test__nonempty_info_to_type_str(self):
      ntype = normalization._nonempty_info_to_type_str(None, True, [])
      assert ntype == "None"
  
      ntype = normalization._nonempty_info_to_type_str(None, False, [])
      assert ntype == "iterable[empty]"
  
      ntype = normalization._nonempty_info_to_type_str(
          None, False, [[]]
      )
      assert ntype == "iterable-iterable[empty]"
  
      ntype = normalization._nonempty_info_to_type_str(
          None, False, [[], []]
      )
      assert ntype == "iterable-iterable-iterable[empty]"
  
      ntype = normalization._nonempty_info_to_type_str(
          None, False, [tuple(), []]
      )
      assert ntype == "iterable-iterable-iterable[empty]"
  
      ntype = normalization._nonempty_info_to_type_str(
          1, True, [tuple([1, 2])]
      )
      assert ntype == "tuple[number,size=2]"
  
      ntype = normalization._nonempty_info_to_type_str(
          1, True, [[], tuple([1, 2])]
      )
      assert ntype == "iterable-tuple[number,size=2]"
  
      ntype = normalization._nonempty_info_to_type_str(
          1, True, [tuple([1, 2, 3, 4])]
      )
      assert ntype == "tuple[number,size=4]"
  
      ntype = normalization._nonempty_info_to_type_str(
          1, True, [[], tuple([1, 2, 3, 4])]
      )
      assert ntype == "iterable-tuple[number,size=4]"
  
      with self.assertRaises(AssertionError):
          ntype = normalization._nonempty_info_to_type_str(
              1, True, [tuple([1, 2, 3])]
          )
          assert ntype == "tuple[number,size=4]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.uint8), True, []
      )
      assert ntype == "array[uint]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.float32), True, []
      )
      assert ntype == "array[float]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.int32), True, []
      )
      assert ntype == "array[int]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=bool), True, []
      )
      assert ntype == "array[bool]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.dtype("complex")), True, []
      )
      assert ntype == "array[c]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.uint8), True, [[]]
      )
      assert ntype == "iterable-array[uint]"
  
      ntype = normalization._nonempty_info_to_type_str(
          np.zeros((4, 4, 3), dtype=np.uint8), True, [[], []]
      )
      assert ntype == "iterable-iterable-array[uint]"
  
      cls_names = [
          "Keypoint",
          "KeypointsOnImage",
          "BoundingBox",
          "BoundingBoxesOnImage",
          "Polygon",
          "PolygonsOnImage",
          "HeatmapsOnImage",
          "SegmentationMapsOnImage",
      ]
      clss = [
          ia.Keypoint(x=1, y=1),
          ia.KeypointsOnImage([], shape=(1, 1, 3)),
          ia.BoundingBox(x1=1, y1=2, x2=3, y2=4),
          ia.BoundingBoxesOnImage([], shape=(1, 1, 3)),
          ia.Polygon([(1, 1), (1, 2), (2, 2)]),
          ia.PolygonsOnImage([], shape=(1,)),
          ia.HeatmapsOnImage(
              np.zeros((1, 1, 1), dtype=np.float32), shape=(1, 1, 3)
          ),
          ia.SegmentationMapsOnImage(
              np.zeros((1, 1, 1), dtype=np.int32), shape=(1, 1, 3)
          ),
      ]
      for cls_name, cls in zip(cls_names, clss):
          ntype = normalization._nonempty_info_to_type_str(
              cls, True, []
          )
          assert ntype == cls_name
  
          ntype = normalization._nonempty_info_to_type_str(
              cls, True, [[]]
          )
          assert ntype == "iterable-%s" % (cls_name,)
  
          ntype = normalization._nonempty_info_to_type_str(
              cls, True, [[], tuple()]
          )
          assert ntype == "iterable-iterable-%s" % (cls_name,)
  
imports: from __future__ import print_function, division, absolute_import
  import sys
  import numpy
  import six.moves
  import imgaug
  import imgaug.augmentables.normalization
  from imgaug.testutils import reseed
label_desc: Use image node_id 17 for calling the TestNormalization obj's underlying member method code with example usage: obj.test__nonempty_info_to_type_str() without return types