code: def emit_DepthwiseConv(self, IR_node):
      # depth-wise convolution
  
      input_name = self.IR_graph.get_parent(IR_node.name, [0]).real_name
      kernel_channels = 1
      is_deconv = False
      has_bias = IR_node.get_attr("use_bias", False)
  
      depth_multiplier = IR_node.get_attr("kernel_shape")[-1]
  
      W = self.weights_dict[IR_node.name]["weights"]
      height, width, channels, n_filters = W.shape
      output_shape = None
      W = np.reshape(W, (height, width, 1, channels * depth_multiplier))
      b = self.weights_dict[IR_node.name]["bias"] if has_bias else None
  
      # Dilations
      dilations = IR_node.get_attr("dilations", [1, 1])
  
      padding = self._get_padding(IR_node)
  
      if isinstance(padding, list):
          border_mode = "valid"
          # see protobuf
          padding_top, padding_left, padding_bottom, padding_right = (
              padding[1],
              padding[2],
              padding[5],
              padding[6],
          )
      else:
          border_mode = "same"
          padding_top, padding_left, padding_bottom, padding_right = (
              0,
              0,
              0,
              0,
          )
  
      output_channels = W.shape[-1]
      groups = W.shape[-1]
      stride_height, stride_width = (
          IR_node.get_attr("strides")[1],
          IR_node.get_attr("strides")[2],
      )
  
      self.builder.add_convolution(
          name=IR_node.real_name,
          kernel_channels=kernel_channels,
          output_channels=output_channels,
          height=height,
          width=width,
          stride_height=stride_height,
          stride_width=stride_width,
          border_mode=border_mode,
          groups=groups,
          W=W,
          b=b,
          has_bias=has_bias,
          is_deconv=is_deconv,
          output_shape=output_shape,
          padding_top=padding_top,
          padding_left=padding_left,
          padding_bottom=padding_bottom,
          padding_right=padding_right,
          input_name=input_name,
          output_name=IR_node.real_name,
          dilation_factors=dilations,
      )
  
imports: from __future__ import division
  import os
  import numpy
  from six import string_types
  from mmdnn.conversion.common.IR.IR_graph import IRGraph, IRGraphNode
  import mmdnn.conversion.common.IR.graph_pb2
  from mmdnn.conversion.common.IR.graph_pb2 import NodeDef, GraphDef, DataType
  from mmdnn.conversion.common.DataStructure.emitter import Emitter
  from mmdnn.conversion.common.utils import *
  from mmdnn.conversion.coreml.coreml_utils import _infer_coreml_input_shape
  from coremltools.models.neural_network import NeuralNetworkBuilder
  from coremltools.models import datatypes
  from coremltools.models import MLModel
  from coremltools.models.utils import save_spec
label_desc: Use image node_id 10 for calling the CoreMLEmitter obj's underlying member method code with example usage: obj.emit_DepthwiseConv(IR_node) without return types