class_docstr: A class for saving graphs and split in OGB-compatible manner
  Create submission_datasetname/ directory, and output the following two files:
      - datasetname.zip (OGB-compatible zipped dataset folder)
      - meta_dict.pt (torch files storing all the necessary dataset meta-information)
class_docstr_tok: ["A","class","for","saving","graphs","and","split","in","OGB-compatible","manner","Create","submission_datasetname\/","directory",",","and","output","the","following","two","files",":","-","datasetname.zip","(","OGB-compatible","zipped","dataset","folder",")","-","meta_dict.pt","(","torch","files","storing","all","the","necessary","dataset","meta-information",")"]
docstr: Save dataset split
      split_dict: must contain three keys: 'train', 'valid', 'test', where the values are the split indices stored in numpy.
      split_name (str): the name of the split
docstr_tok: ["Save","dataset","split","split_dict",":","must","contain","three","keys",":","'train","'",",","'valid","'",",","'test","'",",","where","the","values","are","the","split","indices","stored","in","numpy",".","split_name","(","str",")",":","the","name","of","the","split"]
code: def save_split(self, split_dict, split_name):
      """
      Save dataset split
          split_dict: must contain three keys: 'train', 'valid', 'test', where the values are the split indices stored in numpy.
          split_name (str): the name of the split
      """
  
      self.split_dir = osp.join(self.dataset_dir, "split", split_name)
      os.makedirs(self.split_dir, exist_ok=True)
  
      # verify input
      if not "train" in split_dict:
          raise ValueError("'train' needs to be given in save_split")
      if not "valid" in split_dict:
          raise ValueError("'valid' needs to be given in save_split")
      if not "test" in split_dict:
          raise ValueError("'test' needs to be given in save_split")
  
      if not all_numpy(split_dict):
          raise RuntimeError(
              "split_dict must only contain list/dict of numpy arrays, int, or float"
          )
  
      ## directly save split_dict
      ## compatible with ogb>=v1.2.3
      torch.save(split_dict, osp.join(self.split_dir, "split_dict.pt"))
  
      self.split_name = split_name
      self._save_split_done = True
  
imports: import torch
  import pandas
  import os
  import os.path
  from datetime import date
  import shutil
  from tqdm.auto import tqdm
  import numpy
  from ogb.io.read_graph_raw import read_binary_graph_raw, read_binary_heterograph_raw
  from ogb.utils.torch_util import all_numpy
label_desc: Use image node_id 7 for calling the DatasetSaver obj's underlying member method code with example usage: obj.save_split(split_dict, split_name) without return types