code: def test_mahalanobis():
      x = np.random.rand(100) / 100
      A = np.random.rand(100, 100) / 100
      A = np.dot(A.transpose(), A) + np.eye(100)
      mah = np.dot(x, np.dot(np.linalg.inv(A), x))
      assert_almost_equal(mah, multiple_mahalanobis(x, A), decimal=1)
  
file_path: nipy/nipy/algorithms/statistics/tests/test_utils.py
imports: import numpy
  import pytest
  import scipy.linalg
  from numpy.testing import assert_almost_equal, assert_array_almost_equal, assert_array_equal
  from scipy.stats import norm
  from ..utils import check_cast_bin8, multiple_fast_inv, multiple_mahalanobis, z_score
label_desc: Use image node_id 2 for calling a global function with example usage: test_mahalanobis() without return types