code: def testGradients(self):
      with self.session():
          for _ in range(5):  # To test various random permutations
              input_val = self._SparseTensorValue_5x6(
                  np.random.permutation(6)
              )
              sp_input = sparse_tensor.SparseTensor(
                  input_val.indices,
                  input_val.values,
                  input_val.dense_shape,
              )
              sp_output = sparse_ops.sparse_reorder(sp_input)
  
              err = gradient_checker.compute_gradient_error(
                  sp_input.values,
                  input_val.values.shape,
                  sp_output.values,
                  input_val.values.shape,
                  x_init_value=input_val.values,
              )
              self.assertLess(err, 1e-11)
  
imports: from absl.testing import parameterized
  import numpy
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors
  from tensorflow.python.framework import sparse_tensor
  from tensorflow.python.framework import tensor_spec
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import gen_sparse_ops
  from tensorflow.python.ops import gradient_checker
  from tensorflow.python.ops import sparse_ops
  import tensorflow.python.ops.sparse_grad
  from tensorflow.python.platform import test
label_desc: Use image node_id 9 for calling the SparseReorderTest obj's underlying member method code with example usage: obj.testGradients() without return types