code: def test_as_grey():
      filename = path.join(
          path.dirname(__file__), "..", "demos", "data", "luispedro.jpg"
      )
      im = mh.imread(filename, as_grey=1)
      assert im.ndim == 2
  
file_path: mahotas/mahotas/tests/test_io.py
imports: import numpy
  from mahotas.io import error_imread, error_imsave
  from os import path
  import mahotas
  import pytest
label_desc: Use image node_id 4 for calling a global function with example usage: test_as_grey() without return types