code: def transform_graph(self):
      for node in self.graph.nodes:
          self.layer_name_map[node.name] = node.name
  
      ret = []
      for node in self.graph.nodes:
          mapped_node = self.map_node(node)
          if isinstance(mapped_node, list):
              ret.extend([n for n in mapped_node])
          elif mapped_node:
              ret.append(mapped_node)
  
      name = get_upper_case(get_lower_case(self.graph.name))
      return Graph(name, ret)
  
imports: from __future__ import unicode_literals
  from google.protobuf import text_format
  import numpy
  from mmdnn.conversion.caffe.graph import GraphBuilder, NodeKind, LAYER_IN_TRAIN_PROTO
  from mmdnn.conversion.caffe.mapper import NodeMapper, get_handler_name
  from mmdnn.conversion.caffe.resolver import get_caffe_resolver, has_pycaffe
  from mmdnn.conversion.caffe.errors import print_stderr, ConversionError
  from mmdnn.conversion.caffe.common_graph import Graph
  from mmdnn.conversion.caffe.utils import get_lower_case, get_upper_case
label_desc: Use image node_id 4 for calling the CaffeTransformer obj's underlying member method code with example usage: obj.transform_graph() and returns: Graph