code: def affine_offset(shape, transform):
      """Calculate an offset given an array's shape and an affine transform
  
      shape - the shape of the array to be transformed
      transform - the transform to be performed
  
      Return an offset for scipy.ndimage.affine_transform that does not
      transform the location of the center of the image (the image rotates
      or is flipped about the center).
      """
      c = (numpy.array(shape[:2]) - 1).astype(float) / 2.0
      return -numpy.dot(transform - numpy.identity(2), c)
  
imports: import numpy
  import scipy.ndimage
  from cellprofiler_core.constants.measurement import IMAGE, COLTYPE_FLOAT
  from cellprofiler_core.image import Image
  from cellprofiler_core.module import Module
  from cellprofiler_core.setting import Binary
  from cellprofiler_core.setting import Coordinates
  from cellprofiler_core.setting.choice import Choice
  from cellprofiler_core.setting.subscriber import ImageSubscriber
  from cellprofiler_core.setting.text import ImageName, Float
label_desc: Use image node_id 1 for calling a global function with example usage: affine_offset(shape, transform) and returns: unknown