code: def _get_pretty_string(obj) -> str:
      """
      Return a prettier version of obj.
  
      Parameters
      ----------
      obj : object
          Object to pretty print
  
      Returns
      -------
      str
          Pretty print object repr
      """
      sio = StringIO()
      pprint.pprint(obj, stream=sio)
      return sio.getvalue()
  
imports: from __future__ import annotations
  import datetime
  import inspect
  from io import StringIO
  import itertools
  import pprint
  import struct
  import sys
  from typing import ChainMap, TypeVar
  import numpy
  from pandas._libs.tslibs import Timestamp
  from pandas.errors import UndefinedVariableError
label_desc: Use image node_id 4 for calling a global function with example usage: _get_pretty_string(obj) and returns: sio