code: def save_metrics(path):
      cpu_load = psutil.cpu_percent()
      cpu_mem = psutil.virtual_memory().used
      timestamp = time.time()
      with open(path, "a") as f:
          entry = "time: {} CPU: {} mem: {} {} \n".format(
              timestamp, cpu_load, cpu_mem, get_gpus_summary()
          )
  
          f.write(entry)
  
imports: import os
  import sys
  import subprocess
  import argparse
  import json
  import psutil
  import time
  import six
  import signal
  import pdb
  from apscheduler.schedulers.background import BackgroundScheduler
  from studio import fs_tracker, model
  from studio.util import logs
  from studio.queues.local_queue import LocalQueue
  from studio.util.gpu_util import get_available_gpus, get_gpu_mapping, get_gpus_summary
  from studio.artifacts.artifact import Artifact
  from studio.experiments.experiment import Experiment
  from studio.util.util import sixdecode, str2duration, retry, parse_verbosity, check_for_kb_interrupt
label_desc: Use image node_id 8 for calling a global function with example usage: save_metrics(path) without return types