code: def _tensorlist_stack():
      def _impl(inputs, attr, params, prelude):
          dtype_str = attr["element_dtype"].name
          input_ta_shape = get_tensor_array_shape(
              inputs[0], dtype_str, prelude
          )
  
          if input_ta_shape is None:
              stack_func = prelude.get_global_var(
                  "tensor_array_stack", dtype_str
              )
              out = stack_func(inputs[0])
          else:
              if "num_elements" in attr:
                  num_elements = attr["num_elements"]
              static_tensor_array_ops = StaticTensorArrayOps(
                  prelude, dtype_str, input_ta_shape, num_elements
              )
              static_tensor_array_ops.register()
              stack_func = prelude.get_global_var_static(
                  "tensor_array_stack",
                  dtype_str,
                  input_ta_shape,
                  num_elements,
              )
              out_tensor = stack_func(inputs[0])
              out_shape = (
                  (num_elements,) + input_ta_shape
                  if num_elements and num_elements == 1
                  else (Any(),) + input_ta_shape
              )
              static_tensor_array_ops = StaticTensorArrayOps(
                  prelude, dtype_str, out_shape
              )
              static_tensor_array_ops.register()
              get_data_func = prelude.get_global_var_static(
                  "tensor_get_data", dtype_str, out_shape
              )
              out = get_data_func(out_tensor)
  
          return out
  
      return _impl
  
file_path: tvm/python/tvm/relay/frontend/tensorflow2_ops.py
imports: import tvm
  from tvm.relay.prelude import StaticTensorArrayOps, get_tensor_array_shape
  from ..None import op
  from ..ty import Any
  from .common import infer_value
  from .common import infer_type
  from .tensorflow_ops import _get_more_static_shape_rank
label_desc: Use image node_id 6 for calling a global function with example usage: _tensorlist_stack() and returns: _impl, out