code: def save_to_path(
      path: Path, graphs: Iterable[ArrayDict], splits: ArrayDict
  ):
      """Save all generated data as OGB does."""
  
      # Combine all graph data into a single dictionary.
      graphs_dict = combine_graph_data(graphs)
  
      # Create directories for output.
      data_path = path / "pcba/raw"
      data_path.mkdir(parents=True, exist_ok=True)
  
      split_path = path / "pcba/split/scaffold"
      split_path.mkdir(parents=True, exist_ok=True)
  
      # Save each column as a separate compressed CSV file.
      for column, column_vals in graphs_dict.items():
          column_save_name = data_path / get_save_name(column)
          column_df = pd.DataFrame(column_vals)
          column_df.to_csv(
              column_save_name,
              compression="gzip",
              header=False,
              index=None,
          )
  
      # Save each split as a separate compressed CSV file.
      for split, split_indices in splits.items():
          split_save_name = split_path / ("%s.csv.gz" % split)
          split_df = pd.DataFrame(split_indices)
          split_df.to_csv(
              split_save_name,
              compression="gzip",
              header=False,
              index=None,
          )
  
file_path: datasets/tensorflow_datasets/datasets/ogbg_molpcba/dummy_data_generation.py
imports: import collections
  import itertools
  import random
  from typing import Dict, Iterable, List, Text
  from absl import app
  from absl import flags
  from etils import epath
  import numpy
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.utils import resource_utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import pandas
label_desc: Use image node_id 7 for calling a global function with example usage: save_to_path(path, graphs, splits) without return types