code: def map_node(self, node):
      map_func = self.get_handler(node.kind, "map")
  
      mapped_node = map_func(node)
      # assert mapped_node is not None
  
      if isinstance(mapped_node, list):
          ret = []
          for idx, cur_node in enumerate(mapped_node):
              cur_node.name = node.name + "_" + str(idx)
              if idx == 0:
                  cur_node.input.extend(
                      [
                          self.layer_name_map[input.name]
                          for input, idx in node.parents
                      ]
                  )
              else:
                  cur_node.input.extend(
                      [node.name + "_" + str(idx - 1)]
                  )
  
              if idx == len(mapped_node) - 1:
                  cur_node.output.extend(node.output)
              else:
                  cur_node.output.extend(
                      [node.name + "_" + str(idx + 1)]
                  )
  
              self.layer_name_map[node.name] = (
                  node.name + "_" + str(len(mapped_node) - 1)
              )
              ret.append(cur_node)
          return ret
  
      # skip when mapped_node is None
      elif not mapped_node:
          input_of_next = node.get_only_parent()[0]
          next_node = node.children
          for next in next_node:
              next.parents[0] = tuple(
                  [input_of_next, next.parents[0][1]]
              )
  
      else:
          mapped_node.name = node.name
          mapped_node.input.extend(
              [
                  "%s" % (self.layer_name_map[input.name])
                  for input, idx in node.parents
              ]
          )
          mapped_node.output.extend(node.output)
          return mapped_node
  
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 6 for calling the CaffeTransformer obj's underlying member method code with example usage: obj.map_node(node) and returns: ret, mapped_node