code: def set_default(ctx):
      """Returns a contextmanager with `ctx` as the default execution context."""
      try:
          _default_ctx_stack.push(ctx)
          yield
      finally:
          _default_ctx_stack.pop()
  
imports: import contextlib
  from tensorflow.python.framework.experimental import thread_local_stack
label_desc: Use image node_id 2 for calling a global function with example usage: set_default(ctx) without return types