code: def is_inside_generated_code():
      """Tests whether the caller is generated code. Implementation-specific."""
      frame = inspect.currentframe()
      try:
          frame = frame.f_back
  
          internal_stack_functions = (
              "converted_call",
              "_call_unconverted",
          )
          # Walk up the stack until we're out of the internal functions.
          while (
              frame is not None
              and frame.f_code.co_name in internal_stack_functions
          ):
              frame = frame.f_back
          if frame is None:
              return False
  
          return "ag__" in frame.f_locals
      finally:
          del frame
  
imports: import contextlib
  import imp
  import inspect
  import sys
  import unittest
  import six
  from nvidia.dali._autograph.core import config
  from nvidia.dali._autograph.core import converter
  from nvidia.dali._autograph.impl import api
  from nvidia.dali._autograph.utils import hooks
label_desc: Use image node_id 2 for calling a global function with example usage: is_inside_generated_code() and returns: unknown, False