code: def get_collapse_graph(as_string=False):
      edges = pd.DataFrame(
          {
              "src": [0, -1, 1, 2, 3, 3, 4, 3, 0, 6, 2, 8, -1, 1, 6],
              "dst": [-1, 1, 2, 3, 4, 7, 5, 5, 6, 5, 8, 3, 9, 9, 10],
          }
      )
      nodes = pd.DataFrame(
          {
              "node": [0, 1, 2, 3, 4, 5, 6, 7, -1, 8, 9, 10],
              "level": [0, 1, 1, 1, 2, 2, 1, 1, 0, 1, 2, 1],
          }
      )
      if as_string:
          g = (
              CGFull()
              .edges(edges.astype(str), "src", "dst")
              .nodes(nodes.astype(str), "node")
          )
      else:
          g = CGFull().edges(edges, "src", "dst").nodes(nodes, "node")
      return g
  
file_path: pygraphistry/graphistry/tests/test_compute_collapse.py
imports: import pandas
  from common import NoAuthTestCase
  from graphistry.tests.test_compute import CGFull
label_desc: Use image node_id 1 for calling a global function with example usage: get_collapse_graph(as_string) and returns: g