code: def testEmpty(self, dt_shape, expected, lengths=None, padding=None):
      dt = array_ops.zeros(dt_shape)
      for ragged_rank in range(1, len(dt_shape) - 1):
          rt = RaggedTensor.from_tensor(
              dt, lengths, padding, ragged_rank
          )
          self.assertEqual(type(rt), RaggedTensor)
          self.assertEqual(rt.ragged_rank, ragged_rank)
          self.assertTrue(dt.shape.is_compatible_with(rt.shape))
          self.assertAllEqual(rt, expected)
          self.assertAllEqual(
              rt,
              RaggedTensor.from_nested_row_splits(
                  rt.flat_values, rt.nested_row_splits, validate=True
              ),
          )
  
file_path: tensorflow/tensorflow/python/ops/ragged/ragged_from_tensor_op_test.py
imports: from absl.testing import parameterized
  import numpy
  from tensorflow.python.eager import context
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import test_util
  from tensorflow.python.ops import array_ops
  from tensorflow.python.ops import math_ops
  from tensorflow.python.ops.ragged.ragged_tensor import RaggedTensor
  from tensorflow.python.platform import googletest
label_desc: Use image node_id 4 for calling the RaggedTensorFromTensorOpTest obj's underlying member method code with example usage: obj.testEmpty(dt_shape, expected, lengths, padding) without return types