code: def test_valid_axis(self):
      for axes_value in [1, 2], [[1], [2]], [[], []], 0:
          np_a = np.ones((3, 3))
          np_b = np.array([2, 3, 1])[None, None]
          np_ans = np.tensordot(np_a, np_b, axes_value)
  
          tf_a = array_ops.ones((3, 3), dtype=dtypes.float32)
          tf_b = constant_op.constant([2, 3, 1], dtype=dtypes.float32)[
              None, None
          ]
          tf_ans = math_ops.tensordot(tf_a, tf_b, axes_value)
  
          self.assertAllEqual(tf_ans.shape, np_ans.shape)
          self.assertAllEqual(self.evaluate(tf_ans), np_ans)
  
file_path: tensorflow-upstream/tensorflow/python/kernel_tests/math_ops/tensordot_op_test.py
imports: import numpy
  from tensorflow.python.eager import context
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import errors_impl
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.platform import test
label_desc: Use image node_id 3 for calling the TensordotTest obj's underlying member method code with example usage: obj.test_valid_axis() without return types