code: def plot_children(fig, box, level=0, printit=True):
      """
      Simple plotting to show where boxes are
      """
      import matplotlib
      import matplotlib.pyplot as plt
  
      if isinstance(fig, matplotlib.figure.Figure):
          ax = fig.add_axes([0.0, 0.0, 1.0, 1.0])
          ax.set_facecolor([1.0, 1.0, 1.0, 0.7])
          ax.set_alpha(0.3)
          fig.draw(fig.canvas.get_renderer())
      else:
          ax = fig
  
      import matplotlib.patches as patches
  
      colors = plt.rcParams["axes.prop_cycle"].by_key()["color"]
      if printit:
          print("Level:", level)
      for child in box.children:
          rect = child.get_rect()
          if printit:
              print(child)
          ax.add_patch(
              patches.Rectangle(
                  (child.left.value(), child.bottom.value()),  # (x,y)
                  child.width.value(),  # width
                  child.height.value(),  # height
                  fc="none",
                  alpha=0.8,
                  ec=colors[level],
              )
          )
          if level > 0:
              name = child.name.split(".")[-1]
              if level % 2 == 0:
                  ax.text(
                      child.left.value(),
                      child.bottom.value(),
                      name,
                      size=12 - level,
                      color=colors[level],
                  )
              else:
                  ax.text(
                      child.right.value(),
                      child.top.value(),
                      name,
                      ha="right",
                      va="top",
                      size=12 - level,
                      color=colors[level],
                  )
  
          plot_children(ax, child, level=level + 1, printit=printit)
  
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import itertools
  import kiwisolver
  import logging
  import numpy
  import warnings
  import matplotlib
label_desc: Use image node_id 23 for calling a global function with example usage: plot_children(fig, box, level, printit) without return types