code: def expand_data_dim(dataset):
      """Expand the dimension of data."""
      train_index = dataset.train_index
      train_label = np.expand_dims(dataset.y[train_index], -1)
      train_index = np.expand_dims(train_index, -1)
  
      val_index = dataset.val_index
      val_label = np.expand_dims(dataset.y[val_index], -1)
      val_index = np.expand_dims(val_index, -1)
  
      test_index = dataset.test_index
      test_label = np.expand_dims(dataset.y[test_index], -1)
      test_index = np.expand_dims(test_index, -1)
  
      return {
          "train_index": train_index,
          "train_label": train_label,
          "val_index": val_index,
          "val_label": val_label,
          "test_index": test_index,
          "test_label": test_label,
      }
  
file_path: PGL/legacy/examples/sgc/sgc.py
imports: import os
  import argparse
  import numpy
  import random
  import time
  import pgl
  from pgl import data_loader
  from pgl.utils.logger import log
  from pgl.utils import paddle_helper
  import paddle.fluid
label_desc: Use image node_id 2 for calling a global function with example usage: expand_data_dim(dataset) and returns: dict