code: def load(filename):
      """Load NIfTI2 single or pair image from `filename`
  
      Parameters
      ----------
      filename : str
          filename of image to be loaded
  
      Returns
      -------
      img : Nifti2Image or Nifti2Pair
          nifti2 single or pair image instance
  
      Raises
      ------
      ImageFileError
          if `filename` doesn't look like nifti2;
      OSError
          if `filename` does not exist.
      """
      try:
          img = Nifti2Image.load(filename)
      except ImageFileError:
          return Nifti2Pair.load(filename)
      return img
  
imports: import numpy
  from .analyze import AnalyzeHeader
  from .batteryrunners import Report
  from .filebasedimages import ImageFileError
  from .nifti1 import Nifti1Header, Nifti1Image, Nifti1Pair
  from .spatialimages import HeaderDataError
label_desc: Use image node_id 1 for calling a global function with example usage: load(filename) and returns: img, Nifti2Pair