code: def process(self):
      if self._dataset_name == "MNIST":
          plk_file = "mnist_75sp"
      elif self._dataset_name == "CIFAR10":
          plk_file = "cifar10_150sp"
  
      with open(
          os.path.join(
              self.raw_path,
              "superpixels",
              f"{plk_file}_{self.split}.pkl",
          ),
          "rb",
      ) as f:
          self.labels, self.sp_data = pickle.load(f)
          self.labels = F.tensor(self.labels)
  
      self.Adj_matrices = []
      self.node_features = []
      self.edges_lists = []
      self.edge_features = []
  
      for index, sample in enumerate(
          tqdm(self.sp_data, desc=f"Processing {self.split} dataset")
      ):
          mean_px, coord = sample[:2]
          coord = coord / self.img_size
  
          if self.use_feature:
              A = compute_adjacency_matrix_images(
                  coord, mean_px
              )  # using super-pixel locations + features
          else:
              A = compute_adjacency_matrix_images(
                  coord, mean_px, False
              )  # using only super-pixel locations
          edges_list, edge_values_list = compute_edges_list(A)
  
          N_nodes = A.shape[0]
  
          mean_px = mean_px.reshape(N_nodes, -1)
          coord = coord.reshape(N_nodes, 2)
          x = np.concatenate((mean_px, coord), axis=1)
  
          edge_values_list = edge_values_list.reshape(-1)
  
          self.node_features.append(x)
          self.edge_features.append(edge_values_list)
          self.Adj_matrices.append(A)
          self.edges_lists.append(edges_list)
  
      for index in tqdm(
          range(len(self.sp_data)), desc=f"Dump {self.split} dataset"
      ):
          N = self.node_features[index].shape[0]
  
          src_nodes = []
          dst_nodes = []
          for src, dsts in enumerate(self.edges_lists[index]):
              # handling for 1 node where the self loop would be the only edge
              if N == 1:
                  src_nodes.append(src)
                  dst_nodes.append(dsts)
              else:
                  dsts = dsts[dsts != src]
                  srcs = [src] * len(dsts)
                  src_nodes.extend(srcs)
                  dst_nodes.extend(dsts)
  
          src_nodes = F.tensor(src_nodes)
          dst_nodes = F.tensor(dst_nodes)
  
          g = dgl_graph((src_nodes, dst_nodes), num_nodes=N)
          g.ndata["feat"] = F.zerocopy_from_numpy(
              self.node_features[index]
          ).to(F.float32)
          g.edata["feat"] = (
              F.zerocopy_from_numpy(self.edge_features[index])
              .to(F.float32)
              .unsqueeze(1)
          )
  
          self.graphs.append(g)
  
imports: import os
  import pickle
  import numpy
  from scipy.spatial.distance import cdist
  from tqdm import tqdm
  from ..None import backend
  from ..convert import graph
  from .dgl_dataset import DGLDataset
  from .utils import download, extract_archive, load_graphs, save_graphs, Subset
label_desc: Use image node_id 7 for calling the SuperPixelDataset obj's underlying member method code with example usage: obj.process() without return types