class_docstr: Pass in a custom dataset that conforms to the format.
  
  Args:
      transforms (list): Transforms for image.
      dataset_root (str): The dataset directory.
      num_classes (int): Number of classes.
      mode (str, optional): which part of dataset to use. it is one of ('train', 'val', 'test'). Default: 'train'.
      train_path (str, optional): The train dataset file. When mode is 'train', train_path is necessary.
          The contents of train_path file are as follow:
          image1.jpg ground_truth1.png
          image2.jpg ground_truth2.png
      val_path (str. optional): The evaluation dataset file. When mode is 'val', val_path is necessary.
          The contents is the same as train_path
      test_path (str, optional): The test dataset file. When mode is 'test', test_path is necessary.
          The annotation file is not necessary in test_path file.
      separator (str, optional): The separator of dataset list. Default: ' '.
      edge (bool, optional): Whether to compute edge while training. Default: False
  
      Examples:
  
          import paddleseg.transforms as T
          from paddleseg.datasets import Dataset
  
          transforms = [T.RandomPaddingCrop(crop_size=(512,512)), T.Normalize()]
          dataset_root = 'dataset_root_path'
          train_path = 'train_path'
          num_classes = 2
          dataset = Dataset(transforms = transforms,
                            dataset_root = dataset_root,
                            num_classes = 2,
                            train_path = train_path,
                            mode = 'train')
code: def __len__(self):
      return len(self.file_list)
  
file_path: PaddleSeg/paddleseg/datasets/dataset.py
imports: import os
  import paddle
  import numpy
  from PIL import Image
  from paddleseg.cvlibs import manager
  from paddleseg.transforms import Compose
  import paddleseg.transforms.functional
label_desc: Use image node_id 3 for calling the Dataset obj's underlying member method code with example usage: obj.__len__() and returns: len