code: def test_merge_graph_defs(self):
      expected_proto = """
              node {
                name: "graph_1/X"
                op: "Input"
              }
              node {
                name: "graph_1/W"
                op: "Input"
              }
              node {
                name: "graph_1/Y"
                op: "MatMul"
                input: "graph_1/X"
                input: "graph_1/W"
              }
              node {
                name: "graph_2/A"
                op: "Input"
              }
              node {
                name: "graph_2/B"
                op: "Input"
              }
              node {
                name: "graph_2/C"
                op: "MatMul"
                input: "graph_2/A"
                input: "graph_2/B"
              }
              node {
                name: "graph_3/A"
                op: "Input"
              }
              node {
                name: "graph_3/B"
                op: "Input"
              }
              versions {
                producer: 21
              }
          """
  
      graph_def_a = GraphDef()
      text_format.Parse(
          """
                  node {
                    name: "X"
                    op: "Input"
                  }
                  node {
                    name: "W"
                    op: "Input"
                  }
                  node {
                    name: "Y"
                    op: "MatMul"
                    input: "X"
                    input: "W"
                  }
                  versions {
                    producer: 21
                  }
              """,
          graph_def_a,
      )
  
      graph_def_b = GraphDef()
      text_format.Parse(
          """
                  node {
                    name: "A"
                    op: "Input"
                  }
                  node {
                    name: "B"
                    op: "Input"
                  }
                  node {
                    name: "C"
                    op: "MatMul"
                    input: "A"
                    input: "B"
                  }
                  versions {
                    producer: 21
                  }
              """,
          graph_def_b,
      )
  
      graph_def_c = GraphDef()
      text_format.Parse(
          """
                  node {
                    name: "A"
                    op: "Input"
                  }
                  node {
                    name: "B"
                    op: "Input"
                  }
                  versions {
                    producer: 21
                  }
              """,
          graph_def_c,
      )
  
      self.assertProtoEquals(
          expected_proto,
          graph_util.merge_graph_defs(
              [graph_def_a, graph_def_b, graph_def_c]
          ),
      )
  
file_path: tensorboard/tensorboard/plugins/graph/graph_util_test.py
imports: from google.protobuf import text_format
  import tensorflow
  from tensorboard.compat.proto.graph_pb2 import GraphDef
  from tensorboard.plugins.graph import graph_util
label_desc: Use image node_id 1 for calling the GraphUtilTest obj's underlying member method code with example usage: obj.test_merge_graph_defs() without return types