code: def __init__(self, dim, kdim):
      base_axis = dim - kdim - 1
      up_to_base = tuple(range(0, base_axis))
      self.axes = (
          up_to_base + (dim - 1,) + tuple(range(base_axis, dim - 1))
      )
      self.inv_axes = (
          up_to_base + tuple(range(base_axis + 1, dim)) + (base_axis,)
      )
  
imports: from __future__ import division
  from six.moves import range
  import itertools
  import numpy
label_desc: Use image node_id 1 to create a new ChannelLastToFirstTranspose object from inherited base classes: object with example: obj = ChannelLastToFirstTranspose(dim, kdim)