code: def test_integral2():
      f = np.arange(80 * 16).reshape((80, 16)) % 7
      fi = surf.integral(f.copy())
      assert fi[-1, -1] == f.sum()
      for y, x in np.indices(f.shape).reshape((2, -1)).T:
          assert fi[y, x] == f[: y + 1, : x + 1].sum()
  
file_path: mahotas/mahotas/tests/test_surf.py
imports: import numpy
  import mahotas
  import mahotas.features.surf
  from mahotas.features import _surf
  from .utils import luispedro_jpg
  import pytest
label_desc: Use image node_id 2 for calling a global function with example usage: test_integral2() without return types