docstr: Check that chains of Identity nodes are correctly pruned.
  
  Create a chain of four nodes, A, B, C, and D where A inputs B, B inputs C,
  and C inputs D. Nodes B and C are "Identity" and should be pruned, resulting
  in the nodes A and D, where A inputs D.
docstr_tok: ["Check","that","chains","of","Identity","nodes","are","correctly","pruned",".","Create","a","chain","of","four","nodes",",","A",",","B",",","C",",","and","D","where","A","inputs","B",",","B","inputs","C",",","and","C","inputs","D.","Nodes","B","and","C","are","``","Identity","''","and","should","be","pruned",",","resulting","in","the","nodes","A","and","D",",","where","A","inputs","D","."]
code: def testRemoveIdentityChains(self):
      """Check that chains of Identity nodes are correctly pruned.
  
      Create a chain of four nodes, A, B, C, and D where A inputs B, B inputs C,
      and C inputs D. Nodes B and C are "Identity" and should be pruned, resulting
      in the nodes A and D, where A inputs D.
      """
      graph_def = graph_pb2.GraphDef()
      graph_def.node.extend(
          [
              self.create_node_def("Aop", "A", ["B"]),
              self.create_node_def("Identity", "B", ["C"]),
              self.create_node_def("Identity", "C", ["D"]),
              self.create_node_def("Dop", "D", []),
          ]
      )
  
      expected_graph_def = graph_pb2.GraphDef()
      expected_graph_def.node.extend(
          [
              self.create_node_def("Aop", "A", ["D"]),
              self.create_node_def("Dop", "D", []),
          ]
      )
  
      self.assertProtoEquals(
          expected_graph_def,
          graph_util.remove_training_nodes(graph_def),
      )
  
imports: from tensorflow.core.framework import attr_value_pb2
  from tensorflow.core.framework import function_pb2
  from tensorflow.core.framework import graph_pb2
  from tensorflow.core.framework import node_def_pb2
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import function
  from tensorflow.python.framework import graph_util
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor_util
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import gen_state_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import variable_v1
  from tensorflow.python.platform import test
  from tensorflow.python.util import compat
label_desc: Use image node_id 13 for calling the GraphUtilTest obj's underlying member method code with example usage: obj.testRemoveIdentityChains() without return types