code: def image2nibabel(img, affine=np.eye(4)):
      """
      Loads a RGB or Grayscale Image from a file and stores it in a 5D array,
      moving the color channels to the last axis for color images.
      """
      return ImageAsNibabel(img, affine)
  
file_path: NiftyNet/niftynet/io/image_loader.py
imports: from collections import OrderedDict
  import nibabel
  import numpy
  import tensorflow
  from niftynet.utilities.util_import import require_module
label_desc: Use image node_id 9 for calling a global function with example usage: image2nibabel(img, affine) and returns: ImageAsNibabel