class_docstr: A generic CompositeTensor, used for constructing tests.
class_docstr_tok: ["A","generic","CompositeTensor",",","used","for","constructing","tests","."]
code: def _type_spec(self):
      component_specs = nest.map_structure(
          type_spec.type_spec_from_value, self.components
      )
      return self._type_spec_class(component_specs, self.metadata)
  
imports: import gc
  import sys
  import weakref
  from absl.testing import parameterized
  import numpy
  from tensorflow.python.framework import composite_tensor
  from tensorflow.python.framework import constant_op
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import indexed_slices
  from tensorflow.python.framework import sparse_tensor
  from tensorflow.python.framework import test_util
  from tensorflow.python.framework import type_spec
  from tensorflow.python.ops.ragged import ragged_factory_ops
  from tensorflow.python.platform import googletest
  from tensorflow.python.util import nest
label_desc: Use image node_id 2 for calling the CT obj's underlying member method code with example usage: obj._type_spec() and returns: self