code: def __init__(self, shapenet, mode, num_points, normal_channel=True):
      super(ShapeNetDataset, self).__init__()
      self.mode = mode
      self.num_points = num_points
      if not normal_channel:
          self.dim = 3
      else:
          self.dim = 6
  
      if mode == "train":
          self.file_list = shapenet.train_file_list
      elif mode == "valid":
          self.file_list = shapenet.val_file_list
      elif mode == "test":
          self.file_list = shapenet.test_file_list
      elif mode == "trainval":
          self.file_list = (
              shapenet.train_file_list + shapenet.val_file_list
          )
      else:
          raise "Not supported `mode`"
  
      data_list = []
      label_list = []
      category_list = []
      print("Loading data from split " + self.mode)
      for fn in tqdm.tqdm(self.file_list, ascii=True):
          with open(fn) as f:
              data = np.array(
                  [t.split("\n")[0].split(" ") for t in f.readlines()]
              ).astype(np.float)
          data_list.append(data[:, 0 : self.dim])
          label_list.append(data[:, 6].astype(np.int))
          category_list.append(shapenet.synset_dict[fn.split("/")[-2]])
      self.data = data_list
      self.label = label_list
      self.category = category_list
  
imports: import json
  import os
  from zipfile import ZipFile
  import dgl
  import numpy
  import tqdm
  from dgl.data.utils import download, get_download_dir
  from scipy.sparse import csr_matrix
  from torch.utils.data import Dataset
label_desc: Use image node_id 1 to create a new ShapeNetDataset object from inherited base classes: Dataset with example: obj = ShapeNetDataset(shapenet, mode, num_points, normal_channel)