code: def _transform_cut_coords(cut_coords, direction, affine):
      """Transform cut_coords back in image space.
  
      Parameters
      ----------
      cut_coords : 1D array of length n_cuts
          The coordinates to be transformed.
  
      direction : string
          Sectional direction; possible values are "x", "y", or "z".
  
      affine : 2D array of shape (4, 4)
          The affine for the image.
  
      Returns
      -------
      cut_coords : 1D array of length n_cuts
         The original cut_coords transformed image space.
  
      """
      # make kwargs
      axis = "xyz".index(direction)
      kwargs = {}
      for name in "xyz":
          kwargs[name] = np.zeros(len(cut_coords))
      kwargs[direction] = cut_coords
      kwargs["affine"] = affine
  
      # We need atleast_1d to make sure that when n_cuts is 1 we do
      # get an iterable
      cut_coords = coord_transform(**kwargs)[axis]
      return np.atleast_1d(cut_coords)
  
file_path: nilearn/nilearn/plotting/find_cuts.py
imports: import numbers
  import warnings
  import numpy
  from scipy.ndimage import center_of_mass, find_objects, label
  from nilearn.image import get_data
  from .._utils import check_niimg_3d, check_niimg_4d
  from .._utils.extmath import fast_abs_percentile
  from .._utils.ndimage import largest_connected_component
  from .._utils.niimg import safe_get_data
  from .._utils.numpy_conversions import as_ndarray
  from ..image import iter_img, new_img_like, reorder_img
  from ..image.image import smooth_array
  from ..image.resampling import coord_transform, get_mask_bounds
label_desc: Use image node_id 3 for calling a global function with example usage: _transform_cut_coords(cut_coords, direction, affine) and returns: np