code: def driver_allocated_memory() -> int:
      r"""Returns total GPU memory allocated by Metal driver for the process in bytes.
  
      .. note::
         The returned size includes cached allocations in MPSAllocator pools
         as well as allocations from MPS/MPSGraph frameworks.
      """
      return torch._C._mps_driverAllocatedMemory()
  
file_path: pytorch/torch/mps/__init__.py
imports: import torch
  from ..None import Tensor
  from .None import profiler
  from .event import Event
label_desc: Use image node_id 10 for calling a global function with example usage: driver_allocated_memory() and returns: torch