code: def test_dgemm():
      A = np.random.rand(n1, n2)
      B = np.random.rand(n2, n1)
      C = np.random.rand(n1, n1)
      C2 = np.random.rand(n2, n2)
      alpha = np.double(np.random.rand(1))
      beta = np.double(np.random.rand(1))
      # Test: A*B
      Dgold = alpha * np.dot(A, B) + beta * C
      D = blas_dgemm(0, 0, alpha, A, B, beta, C)
      assert_almost_equal(Dgold, D)
      # Test: A^t B^t
      Dgold = alpha * np.dot(A.T, B.T) + beta * C2
      D = blas_dgemm(1, 1, alpha, A, B, beta, C2)
      assert_almost_equal(Dgold, D)
  
file_path: nipy/nipy/labs/bindings/tests/test_blas3.py
imports: import numpy
  from numpy.testing import assert_almost_equal
  from ..None import blas_dgemm, blas_dsymm, blas_dsyr2k, blas_dsyrk, blas_dtrmm, blas_dtrsm
label_desc: Use image node_id 1 for calling a global function with example usage: test_dgemm() without return types