code: def test_sparse_dot():
      s1 = SparseNDArray(s1_data)
      s2 = SparseNDArray(s2_data)
      v1_s = SparseNDArray(v1, shape=(3,))
      v2_s = SparseNDArray(v2, shape=(2,))
  
      assert_array_equal(mls.dot(s1, s2.T), s1.dot(s2.T))
      assert_array_equal(s1.dot(d1), s1.dot(d1))
      assert_array_equal(d1.dot(s1.T), d1.dot(s1.T.toarray()))
  
      assert_array_equal(s1 @ s2.T, s1_data @ s2_data.T)
  
      assert_array_equal(
          mls.tensordot(s1, s2.T, axes=(1, 0)), s1.dot(s2.T)
      )
      assert_array_equal(
          mls.tensordot(s1, d1, axes=(1, -1)), s1.dot(d1)
      )
      assert_array_equal(
          mls.tensordot(d1, s1.T, axes=(0, 0)), d1.dot(s1.T.toarray())
      )
  
      assert_array_equal(mls.dot(s1, v1_s), s1.dot(v1_data))
      assert_array_equal(mls.dot(s2, v1_s), s2.dot(v1_data))
      assert_array_equal(mls.dot(v2_s, s1), v2_data.dot(s1_data.A))
      assert_array_equal(mls.dot(v2_s, s2), v2_data.dot(s2_data.A))
      assert_array_equal(
          mls.dot(v1_s, v1_s), v1_data.dot(v1_data), almost=True
      )
      assert_array_equal(
          mls.dot(v2_s, v2_s), v2_data.dot(v2_data), almost=True
      )
  
      assert_array_equal(
          mls.dot(v2_s, s1, sparse=False), v2_data.dot(s1_data.A)
      )
      assert_array_equal(
          mls.dot(v1_s, v1_s, sparse=False), v1_data.dot(v1_data)
      )
  
imports: import pickle
  import numpy
  import pytest
  import scipy.sparse
  from ...None import sparse
  from ..None import SparseNDArray, SparseVector, SparseMatrix
  from ..core import issparse
label_desc: Use image node_id 12 for calling a global function with example usage: test_sparse_dot() without return types