code: def testScalar2D(self):
      with self.session():
          data = np.array(
              [
                  [0, 1, 2],
                  [3, 4, 5],
                  [6, 7, 8],
                  [9, 10, 11],
                  [12, 13, 14],
              ]
          )
          for dtype in _TEST_TYPES:
              for itype in _INDEX_TYPES:
                  for axis in range(data.ndim):
                      with self.subTest(
                          dtype=dtype, itype=itype, axis=axis
                      ):
                          params_np = self._buildParams(data, dtype)
                          params = constant_op.constant(params_np)
                          indices = constant_op.constant(2, dtype=itype)
                          gather_t = array_ops.gather(
                              params, indices, axis=axis
                          )
                          gather_val = self.evaluate(gather_t)
                          self.assertAllEqual(
                              np.take(params_np, 2, axis=axis),
                              gather_val,
                          )
                          expected_shape = (
                              data.shape[:axis] + data.shape[axis + 1 :]
                          )
                          self.assertEqual(
                              expected_shape, gather_t.get_shape()
                          )
  
imports: from absl.testing import parameterized
  import numpy
  from tensorflow.python.eager import backprop
  from tensorflow.python.eager import def_function
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors
  from tensorflow.python.framework import indexed_slices
  from tensorflow.python.framework import ops
  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 gradient_checker_v2
  from tensorflow.python.ops import gradients_impl
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops import ref_variable
  from tensorflow.python.ops import resource_variable_ops
  from tensorflow.python.ops import variables
  from tensorflow.python.platform import test
label_desc: Use image node_id 3 for calling the GatherTest obj's underlying member method code with example usage: obj.testScalar2D() without return types