code: def scans_for_fname(fname):
      img = load(fname)
      n_scans = img.shape[3]
      scans = np.zeros((n_scans, 1), dtype=object)
      for sno in range(n_scans):
          scans[sno] = "%s,%d" % (fname, sno + 1)
      return scans
  
file_path: nipy/nipy/interfaces/spm.py
imports: import os
  import numpy
  from nibabel import load
  from nibabel.tmpdirs import InTemporaryDirectory
  from scipy.io import savemat
  from .matlab import run_matlab_script
label_desc: Use image node_id 4 for calling a global function with example usage: scans_for_fname(fname) and returns: scans