code: def to_python_float(t):
      if hasattr(t, "item"):
          return t.item()
      return t[0]
  
imports: import torch
  from deepspeed import comm
  from deepspeed.utils import logger
label_desc: Use image node_id 1 for calling a global function with example usage: to_python_float(t) and returns: t, t