code: def code_as_str(code):
      if code is None:
          return None
      if isinstance(code, str):
          return code
      if callable(code):
          return "\n".join(getsource(code).splitlines()[1:])
      raise AssertionError(
          "`code` param should be a string or a function definition"
      )
  
imports: from copy import deepcopy
  from functools import partial
  from io import StringIO
  from inspect import getsource
  from pprint import pformat
  import sys
  import bindings
  from custom import get_customizations_for, reformat_block
label_desc: Use image node_id 2 for calling a global function with example usage: code_as_str(code) and returns: None, code, str