code: def system_resources() -> dict[str, t.Any]:
      res: dict[str, t.Any] = {}
      for resource_kind, resource in _RESOURCE_REGISTRY.items():
          res[resource_kind] = resource.from_system()
      return res
  
imports: from __future__ import annotations
  import functools
  import logging
  import math
  import os
  import re
  import typing
  from abc import ABC
  from abc import abstractmethod
  import psutil
  from ..exceptions import BentoMLConfigException
label_desc: Use image node_id 2 for calling a global function with example usage: system_resources() and returns: res