code: def positive_definite_matrix(N, M=None):
      """return an array of M positive-definite matrices with shape (N, N)"""
      if M is None:
          V = np.random.random((N, N))
          V = np.dot(V, V.T)
      else:
          V = np.random.random((M, N, N))
          for i in range(M):
              V[i] = np.dot(V[i], V[i].T)
      return V
  
file_path: astroML/astroML/utils/tests/test_utils.py
imports: import numpy
  from numpy.testing import assert_array_almost_equal, assert_allclose
  from astroML.utils import log_multivariate_gaussian, convert_2D_cov, completeness_contamination, split_samples
label_desc: Use image node_id 1 for calling a global function with example usage: positive_definite_matrix(N, M) and returns: V