class_docstr: Attributes:
  layer_list - a list of layer names in the Keras model
  connection_map - a map where the key is a layer, the value is a list of its successors
  reverse_connection_map - a map where the key is a layer, the value is a list of its predecessors
  keras_layer_map - a map where the key is a layer name, the value is Keras layer
  model - a reference of the keras model.
  blob_names - blob names for each one of the edge.
class_docstr_tok: ["Attributes",":","layer_list","-","a","list","of","layer","names","in","the","Keras","model","connection_map","-","a","map","where","the","key","is","a","layer",",","the","value","is","a","list","of","its","successors","reverse_connection_map","-","a","map","where","the","key","is","a","layer",",","the","value","is","a","list","of","its","predecessors","keras_layer_map","-","a","map","where","the","key","is","a","layer","name",",","the","value","is","Keras","layer","model","-","a","reference","of","the","keras","model",".","blob_names","-","blob","names","for","each","one","of","the","edge","."]
docstr: Insert the new_layer, whose keras layer parameters are stored in
  new_keras_layer, between src and snk.
docstr_tok: ["Insert","the","new_layer",",","whose","keras","layer","parameters","are","stored","in","new_keras_layer",",","between","src","and","snk","."]
code: def _insert_layer_between(self, src, snk, new_layer, new_keras_layer):
      """Insert the new_layer, whose keras layer parameters are stored in
      new_keras_layer, between src and snk.
      """
      if snk is None:
          insert_pos = self.layer_list.index(src) + 1
      else:
          insert_pos = self.layer_list.index(snk)  # insert position
      self.layer_list.insert(insert_pos, new_layer)
      self.keras_layer_map[new_layer] = new_keras_layer
      if src is None:  # snk is an input layer
          self._add_edge(new_layer, snk)
      elif snk is None:  # src is an output layer
          self._add_edge(src, new_layer)
      else:
          self._add_edge(src, new_layer)
          self._add_edge(new_layer, snk)
          self._remove_edge(src, snk)
  
      # if layer is an output layer, change the output layer tag
      if src in self.output_layers:
          idx = self.output_layers.index(src)
          self.output_layers[idx] = new_layer
  
imports: import keras
  import numpy
  import six
  from distutils.version import StrictVersion
label_desc: Use image node_id 29 for calling the NetGraph obj's underlying member method code with example usage: obj._insert_layer_between(src, snk, new_layer, new_keras_layer) without return types