code: def _compare(self, input_shape, block_shape, crops, crops_dtype):
      input_shape = list(input_shape)
      input_shape[0] *= np.prod(block_shape)
      x = (
          np.random.normal(0, 1, np.prod(input_shape))
          .astype(np.float32)
          .reshape(input_shape)
      )
      self._checkGrad(x, block_shape, crops, crops_dtype)
  
imports: from absl.testing import parameterized
  import numpy
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import gen_array_ops
  from tensorflow.python.ops import gradient_checker
  from tensorflow.python.platform import test
label_desc: Use image node_id 2 for calling the BatchToSpaceNDGradientTest obj's underlying member method code with example usage: obj._compare(input_shape, block_shape, crops, crops_dtype) without return types