code: def get_data_size(data: BaseData) -> int:
      r"""Given a :class:`torch_geometric.data.Data` object, get its theoretical
      memory usage in bytes.
  
      Args:
          data (torch_geometric.data.Data or torch_geometric.data.HeteroData):
              The :class:`~torch_geometric.data.Data` or
              :class:`~torch_geometric.data.HeteroData` graph object.
      """
      data_ptrs = set()
  
      def _get_size(obj: Any) -> int:
          if isinstance(obj, Tensor):
              if obj.data_ptr() in data_ptrs:
                  return 0
              data_ptrs.add(obj.data_ptr())
              return obj.numel() * obj.element_size()
          elif isinstance(obj, SparseTensor):
              return _get_size(obj.csr())
          elif isinstance(obj, Sequence) and not isinstance(obj, str):
              return sum([_get_size(x) for x in obj])
          elif isinstance(obj, Mapping):
              return sum([_get_size(x) for x in obj.values()])
          else:
              return 0
  
      return sum([_get_size(store) for store in data.stores])
  
imports: import gc
  import os
  import os.path
  import random
  import subprocess
  import sys
  import warnings
  from collections.abc import Mapping, Sequence
  from typing import Any, Tuple
  import torch
  from torch import Tensor
  from torch_geometric.data.data import BaseData
  from torch_geometric.typing import SparseTensor
label_desc: Use image node_id 3 for calling a global function with example usage: get_data_size(data) and returns: sum, unknown, int, _get_size, sum, sum, int