class_docstr: A data structure interface of tracking task in MMDetection. It is used
  as interfaces between different components.
  
  This data structure can be viewd as a wrapper of multiple DetDataSample to
  some extent. Specifically, it only contains a property:
  ``video_data_samples`` which is a list of DetDataSample, each of which
  corresponds to a single frame. If you want to get the property of a single
  frame, you must first get the corresponding ``DetDataSample`` by indexing
  and then get the property of the frame, such as ``gt_instances``,
  ``pred_instances`` and so on. As for metainfo, it differs from
  ``DetDataSample`` in that each value corresponds to the metainfo key is a
  list where each element corresponds to information of a single frame.
  
  Examples:
      >>> import torch
      >>> from mmengine.structures import InstanceData
      >>> from mmdet.structures import DetDataSample, TrackDataSample
      >>> track_data_sample = TrackDataSample()
      >>> # set the 1st frame
      >>> frame1_data_sample = DetDataSample(metainfo=dict(
      ...         img_shape=(100, 100), frame_id=0))
      >>> frame1_gt_instances = InstanceData()
      >>> frame1_gt_instances.bbox = torch.zeros([2, 4])
      >>> frame1_data_sample.gt_instances = frame1_gt_instances
      >>> # set the 2nd frame
      >>> frame2_data_sample = DetDataSample(metainfo=dict(
      ...         img_shape=(100, 100), frame_id=1))
      >>> frame2_gt_instances = InstanceData()
      >>> frame2_gt_instances.bbox = torch.ones([3, 4])
      >>> frame2_data_sample.gt_instances = frame2_gt_instances
      >>> track_data_sample.video_data_samples = [frame1_data_sample,
      ...                                         frame2_data_sample]
      >>> # set metainfo for track_data_sample
      >>> track_data_sample.set_metainfo(dict(key_frames_inds=[0]))
      >>> track_data_sample.set_metainfo(dict(ref_frames_inds=[1]))
      >>> print(track_data_sample)
      <TrackDataSample(
  
          META INFORMATION
          key_frames_inds: [0]
          ref_frames_inds: [1]
  
          DATA FIELDS
          video_data_samples: [<DetDataSample(
  
                  META INFORMATION
                  img_shape: (100, 100)
  
                  DATA FIELDS
                  gt_instances: <InstanceData(
  
                          META INFORMATION
  
                          DATA FIELDS
                          bbox: tensor([[0., 0., 0., 0.],
                                      [0., 0., 0., 0.]])
                      ) at 0x7f639320dcd0>
              ) at 0x7f64bd223340>, <DetDataSample(
  
                  META INFORMATION
                  img_shape: (100, 100)
  
                  DATA FIELDS
                  gt_instances: <InstanceData(
  
                          META INFORMATION
  
                          DATA FIELDS
                          bbox: tensor([[1., 1., 1., 1.],
                                      [1., 1., 1., 1.],
                                      [1., 1., 1., 1.]])
                      ) at 0x7f64bd128b20>
              ) at 0x7f64bd1346d0>]
      ) at 0x7f64bd2237f0>
      >>> print(len(track_data_sample))
      2
      >>> key_data_sample = track_data_sample.get_key_frames()
      >>> print(key_data_sample[0].frame_id)
      0
      >>> ref_data_sample = track_data_sample.get_ref_frames()
      >>> print(ref_data_sample[0].frame_id)
      1
      >>> frame1_data_sample = track_data_sample[0]
      >>> print(frame1_data_sample.gt_instances.bbox)
      tensor([[0., 0., 0., 0.],
              [0., 0., 0., 0.]])
      >>> # Tensor-like methods
      >>> cuda_track_data_sample = track_data_sample.to('cuda')
      >>> cuda_track_data_sample = track_data_sample.cuda()
      >>> cpu_track_data_sample = track_data_sample.cpu()
      >>> cpu_track_data_sample = track_data_sample.to('cpu')
      >>> fp16_instances = cuda_track_data_sample.to(
      ...     device=None, dtype=torch.float16, non_blocking=False,
      ...     copy=False, memory_format=torch.preserve_format)
code: def __len__(self):
      return (
          len(self._video_data_samples)
          if hasattr(self, "_video_data_samples")
          else 0
      )
  
imports: from typing import List, Optional, Sequence
  import numpy
  import torch
  from mmengine.structures import BaseDataElement
  from .det_data_sample import DetDataSample
label_desc: Use image node_id 7 for calling the TrackDataSample obj's underlying member method code with example usage: obj.__len__() and returns: unknown