code: def test_paths_benchmark(self):
      download_url(
          "https://storage.googleapis.com/mledu-datasets/"
          "cats_and_dogs_filtered.zip",
          expanduser("~") + "/.avalanche/data",
          "cats_and_dogs_filtered.zip",
      )
      archive_name = os.path.join(
          expanduser("~") + "/.avalanche/data",
          "cats_and_dogs_filtered.zip",
      )
      extract_archive(
          archive_name, to_path=expanduser("~") + "/.avalanche/data/"
      )
  
      dirpath = (
          expanduser("~")
          + "/.avalanche/data/cats_and_dogs_filtered/train"
      )
  
      train_experiences = []
      for rel_dir, label in zip(["cats", "dogs"], [0, 1]):
          filenames_list = os.listdir(os.path.join(dirpath, rel_dir))
  
          experience_paths = []
          for name in filenames_list:
              instance_tuple = (
                  os.path.join(dirpath, rel_dir, name),
                  label,
              )
              experience_paths.append(instance_tuple)
          train_experiences.append(experience_paths)
  
      generic_benchmark = paths_benchmark(
          train_experiences,
          [train_experiences[0]],  # Single test set
          task_labels=[0, 0],
          complete_test_set_only=True,
          train_transform=ToTensor(),
          eval_transform=ToTensor(),
      )
  
      self.assertEqual(2, len(generic_benchmark.train_stream))
      self.assertEqual(1, len(generic_benchmark.test_stream))
  
imports: import os
  import tempfile
  import unittest
  from os.path import expanduser
  import torch
  from torchvision.datasets import MNIST
  from torchvision.datasets.utils import download_url, extract_archive
  from torchvision.transforms import ToTensor
  from tests.unit_tests_utils import DummyImageDataset
  from avalanche.benchmarks import dataset_benchmark, filelist_benchmark, tensors_benchmark, paths_benchmark, data_incremental_benchmark
  from avalanche.benchmarks.datasets import default_dataset_location
  from avalanche.benchmarks.scenarios.deprecated.generic_benchmark_creation import create_lazy_generic_benchmark, LazyStreamDefinition
  from avalanche.benchmarks.utils import _make_taskaware_classification_dataset, _make_taskaware_tensor_classification_dataset
  from tests.unit_tests_utils import common_setups
label_desc: Use image node_id 3 for calling the HighLevelGeneratorTests obj's underlying member method code with example usage: obj.test_paths_benchmark() without return types