code: def transpose(v, before_op):
      """
      Transpose the last 2 dims.
      v: Var (must be a tensor)
      """
      perm = list(range(v.rank))
      perm[-2], perm[-1] = perm[-1], perm[-2]
      return mb.transpose(x=v, perm=perm, before_op=before_op)
  
file_path: turicreate/src/external/coremltools_wrap/coremltools/coremltools/converters/mil/mil/passes/matmul_weight_bias_fusion.py
imports: from __future__ import print_function
  from __future__ import division
  from __future__ import absolute_import
  import numpy
  from coremltools.converters.mil.mil.passes.pass_registry import register_pass
  from coremltools.converters.mil.mil import Builder
label_desc: Use image node_id 2 for calling a global function with example usage: transpose(v, before_op) and returns: mb