code: def imread(filename, as_grey=False):
      """
      img = imread(filename, as_grey=False)
  
      Reads an image from file `filename`
  
      Implementation is based on FreeImage.
  
      Parameters
      ----------
        filename : file name
        as_grey : Whether to convert to grey scale image (default: no)
  
      Returns
      -------
        img : ndarray
      """
      img = read(filename)
      if as_grey and len(img.shape) == 3:
          # these are the values that wikipedia says are typical
          transform = np.array([0.30, 0.59, 0.11])
          return np.dot(img, transform)
      return img
  
imports: import sys
  import os
  import ctypes
  import ctypes.util
  import numpy
label_desc: Use image node_id 14 for calling a global function with example usage: imread(filename, as_grey) and returns: img, np