code: def test__len__(self, dataset_type):
      with tempfile.TemporaryDirectory(
          prefix=f"{TestEpicKitchenDataset}"
      ) as tempdir:
          tempdir = Path(tempdir)
  
          video_info_file = tempdir / "test_video_info.csv"
          save_dataclass_objs_to_headered_csv(
              list(MOCK_VIDEO_INFOS.values()), video_info_file
          )
          action_file = tempdir / "action_video_info.csv"
          actions = []
          for action_list in self.ACTIONS_DATAS.values():
              for action in action_list:
                  actions.append(action)
          save_dataclass_objs_to_headered_csv(actions, action_file)
  
          video_data_manifest_file_path = (
              tempdir / "video_data_manifest_file_path.json"
          )
          with ExitStack() as stack:
              if dataset_type == VideoDatasetType.Frame:
                  video_data_dict = get_flat_video_frames(
                      tempdir, "jpg"
                  )
              elif dataset_type == VideoDatasetType.EncodedVideo:
                  video_data_dict = get_encoded_video_infos(
                      tempdir, stack
                  )
  
              save_dataclass_objs_to_headered_csv(
                  list(video_data_dict.values()),
                  video_data_manifest_file_path,
              )
  
              dataset = EpicKitchenDataset(
                  video_info_file_path=str(video_info_file),
                  actions_file_path=str(action_file),
                  clip_sampler=lambda x, y: [
                      VideoClipInfo(str(i), i * 2.0, i * 2.0 + 0.9)
                      for i in range(0, 7)
                  ],
                  video_data_manifest_file_path=str(
                      video_data_manifest_file_path
                  ),
                  dataset_type=dataset_type,
              )
  
              self.assertEqual(len(dataset), 7)
  
file_path: pytorchvideo/tests/test_data_epic_kitchen_dataset.py
imports: import tempfile
  import unittest
  import unittest.mock
  from contextlib import ExitStack
  from pathlib import Path
  import torch
  from parameterized import parameterized
  from pytorchvideo.data.dataset_manifest_utils import VideoClipInfo, VideoDatasetType
  from pytorchvideo.data.epic_kitchen import ActionData, EpicKitchenDataset
  from pytorchvideo.data.utils import save_dataclass_objs_to_headered_csv
  from utils import get_encoded_video_infos, get_flat_video_frames, MOCK_VIDEO_IDS, MOCK_VIDEO_INFOS
label_desc: Use image node_id 2 for calling the TestEpicKitchenDataset obj's underlying member method code with example usage: obj.test__len__(dataset_type) without return types