code: def test_non_sequence_sparse_one_hot():
      i = C.input_variable(())
      sparse_one_hot = C.one_hot(i, num_classes=3, sparse_output=True)
      indices = np.asarray([2, 0, 1])
      result = sparse_one_hot.eval({i: indices})
      result_indices = result.dot(np.array([0, 1, 2]))
      assert np.array_equal(result_indices, indices)
  
imports: import numpy
  import scipy
  import pytest
  import cntk
  from .ops_test_utils import cntk_device
  from cntk.axis import Axis
  from ..None import constant
  from cntk.tests.test_utils import _to_dense
label_desc: Use image node_id 6 for calling a global function with example usage: test_non_sequence_sparse_one_hot() without return types