code: def Ava(
      frame_paths_file: str,
      frame_labels_file: str,
      video_path_prefix: str = "",
      label_map_file: Optional[str] = None,
      clip_sampler: Callable = ClipSampler,
      video_sampler: Type[
          torch.utils.data.Sampler
      ] = torch.utils.data.RandomSampler,
      transform: Optional[Callable[[dict], Any]] = None,
  ) -> None:
      """
      Args:
          frame_paths_file (str): Path to a file containing relative paths
              to all the frames in the video. Each line in the file is of the
              form <original_vido_id video_id frame_id rel_path labels>
          frame_labels_file (str): Path to the file containing containing labels
              per key frame. Acceptible file formats are,
              Type 1:
                  <original_vido_id, frame_time_stamp, bbox_x_1, bbox_y_1, ...
                  bbox_x_2, bbox_y_2, action_lable, detection_iou>
              Type 2:
                  <original_vido_id, frame_time_stamp, bbox_x_1, bbox_y_1, ...
                  bbox_x_2, bbox_y_2, action_lable, person_label>
          video_path_prefix (str): Path to be augumented to the each relative frame
              path to get the global frame path.
          label_map_file (str): Path to a .pbtxt containing class id's
              and class names. If not set, label_map is not loaded and bbox labels are
              not pruned based on allowable class_id's in label_map.
          clip_sampler (ClipSampler): Defines how clips should be sampled from each
                  video.
          video_sampler (Type[torch.utils.data.Sampler]): Sampler for the internal
                  video container. This defines the order videos are decoded and,
                  if necessary, the distributed split.
          transform (Optional[Callable]): This callable is evaluated on the clip output
              and the corresponding bounding boxes before the clip and the bounding boxes
              are returned. It can be used for user defined preprocessing and
              augmentations to the clips. If transform is None, the clip and bounding
              boxes are returned as it is.
      """
      labeled_video_paths = AvaLabeledVideoFramePaths.from_csv(
          frame_paths_file,
          frame_labels_file,
          video_path_prefix,
          label_map_file,
      )
      return LabeledVideoDataset(
          labeled_video_paths=labeled_video_paths,
          clip_sampler=TimeStampClipSampler(clip_sampler),
          transform=transform,
          video_sampler=video_sampler,
          decode_audio=False,
      )
  
file_path: pytorchvideo/pytorchvideo/data/ava.py
imports: from __future__ import annotations
  import os
  from collections import defaultdict
  from typing import Any, Callable, Dict, Optional, Set, Tuple, Type
  import torch
  from iopath.common.file_io import g_pathmgr
  from pytorchvideo.data.clip_sampling import ClipInfo, ClipSampler
  from pytorchvideo.data.labeled_video_dataset import LabeledVideoDataset
label_desc: Use image node_id 1 for calling a global function with example usage: Ava(frame_paths_file, frame_labels_file, video_path_prefix, label_map_file, clip_sampler, video_sampler, transform) and returns: LabeledVideoDataset