code: def __init__(self, root_dir, label_file, fp16=False, is_bin=True):
      super(CommonDataset, self).__init__()
      self.root_dir = root_dir
      self.label_file = label_file
      self.fp16 = fp16
      with open(label_file, "r") as fin:
          self.full_lines = fin.readlines()
  
      self.delimiter = "\t"
      self.is_bin = is_bin
  
      self.num_samples = len(self.full_lines)
      logging.info(
          "read label file finished, total num: {}".format(
              self.num_samples
          )
      )
  
imports: import pickle
  import paddle
  import os
  import cv2
  import six
  import random
  import paddle
  import numpy
  import logging
  from PIL import Image
  from io import BytesIO
  from datasets.kv_helper import read_img_from_bin
label_desc: Use image node_id 1 to create a new CommonDataset object from inherited base classes: paddle.io with example: obj = CommonDataset(root_dir, label_file, fp16, is_bin)