class_docstr: The classic Sugiyama layout aka layered layout.
  
  - See https://en.wikipedia.org/wiki/Layered_graph_drawing
  - Excellent explanation: https://www.youtube.com/watch?v=Z0RGCWxvCxA
  
  
  **Attributes**
      - dirvh (int): the current aligment state for alignment policy:
               dirvh=0 -> dirh=+1, dirv=-1: leftmost upper
               dirvh=1 -> dirh=-1, dirv=-1: rightmost upper
               dirvh=2 -> dirh=+1, dirv=+1: leftmost lower
               dirvh=3 -> dirh=-1, dirv=+1: rightmost lower
      - order_iter (int): the default number of layer placement iterations
      - order_attr (str): set attribute name used for layer ordering
      - xspace (int): horizontal space between vertices in a layer
      - yspace (int): vertical space between layers
      - dw (int): default width of a vertex
      - dh (int): default height of a vertex
      - g (GraphBase): the graph component reference
      - layers (list[sugiyama.layer.Layer]): the list of layers
      - layoutVertices (dict): associate vertex (possibly dummy) with their sugiyama attributes
      - ctrls (dict): associate edge with all its vertices (including dummies)
      - dag (bool): the current acyclic state
      - init_done (bool): True if things were initialized
  
  **Example**
  
      ::
  
          g = nx.generators.connected_watts_strogatz_graph(1000, 2, 0.3)
          # render
          SugiyamaLayout.draw(g)
          # positions
          positions_dictionary = SugiyamaLayout.arrange(g)
code: def _coord_horizontal_compact(self):
      limit = getrecursionlimit()
      layer_count = len(self.layers) + 10
      if layer_count > limit:
          setrecursionlimit(layer_count)
      dirh, dirv = self.dirh, self.dirv
      g = self.layoutVertices
      sub_layer = self.layers[::-dirv]
      # recursive placement of blocks:
      for layer in sub_layer:
          for v in layer[::dirh]:
              if g[v].root is v:
                  self.__place_block(v)
      setrecursionlimit(limit)
      # mirror all nodes if right-aligned:
      if dirh == -1:
          for layer in sub_layer:
              for v in layer:
                  x = g[v].X
                  if x:
                      g[v].X = -x
      # then assign x-coord of its root:
      inf = float("infinity")
      rb = inf
      for layer in sub_layer:
          for v in layer[::dirh]:
              g[v].x[self.dirvh] = g[g[v].root].X
              rs = g[g[v].root].sink
              s = g[rs].shift
              if s < inf:
                  g[v].x[self.dirvh] += dirh * s
              rb = min(rb, g[v].x[self.dirvh])
      # normalize to 0, and reinit root/align/sink/shift/X
      for layer in self.layers:
          for v in layer:
              # g[v].x[dirvh] -= rb
              g[v].root = g[v].align = g[v].sink = v
              g[v].shift = inf
              g[v].X = None
  
imports: import pandas, typing
  from sys import getrecursionlimit, setrecursionlimit
  from graphistry.layout.graph import Vertex, GraphBase, Graph, Edge
  from graphistry.layout.utils import DummyVertex, LayoutVertex, Rectangle, size_median
  from graphistry.layout.utils.layer import Layer
label_desc: Use image node_id 29 for calling the SugiyamaLayout obj's underlying member method code with example usage: obj._coord_horizontal_compact() without return types