code: def test_cmp_ndimage():
      R = (255 * np.random.rand(128, 256)).astype(np.uint16)
      R += np.arange(256, dtype=np.uint16)
      m0, m1 = mahotas.center_of_mass(R)
      n0, n1 = ndimage.center_of_mass(R)
      assert np.abs(n0 - m0) < 1.0
      assert np.abs(n1 - m1) < 1.0
  
file_path: mahotas/mahotas/tests/test_center_of_mass.py
imports: import numpy
  from scipy import ndimage
  import mahotas.center_of_mass
label_desc: Use image node_id 3 for calling a global function with example usage: test_cmp_ndimage() without return types