code: def test_sparse_bincount_col_reduce_count(self, dtype):
      num_rows = 128
      num_cols = 27
      size = 100
      np.random.seed(42)
      inp = np.random.randint(
          0, size, (num_rows, num_cols), dtype=dtype
      )
      np_out = np.reshape(
          np.concatenate(
              [
                  np.bincount(inp[j, :], minlength=size)
                  for j in range(num_rows)
              ],
              axis=0,
          ),
          (num_rows, size),
      )
      # from_dense will filter out 0s.
      inp = inp + 1
      # from_dense will cause OOM in GPU.
      with ops.device("/CPU:0"):
          inp_sparse = sparse_ops.from_dense(inp)
      self.assertAllEqual(
          np_out,
          self.evaluate(
              gen_math_ops.sparse_bincount(
                  indices=inp_sparse.indices,
                  values=inp_sparse.values - 1,
                  dense_shape=inp_sparse.dense_shape,
                  size=size,
                  weights=[],
              )
          ),
      )
  
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 errors
  from tensorflow.python.framework import errors_impl
  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 bincount_ops
  from tensorflow.python.ops import gen_math_ops
  from tensorflow.python.ops import random_ops
  from tensorflow.python.ops import sparse_ops
  from tensorflow.python.ops.ragged import ragged_factory_ops
  from tensorflow.python.ops.ragged import ragged_tensor
  from tensorflow.python.platform import googletest
label_desc: Use image node_id 5 for calling the SparseBincountOpTest obj's underlying member method code with example usage: obj.test_sparse_bincount_col_reduce_count(dtype) without return types