code: def _is_jupyter_kernel_output(stream):
      if WIN:
          # TODO: Couldn't test on Windows, should't try to support until
          # someone tests the details wrt colorama.
          return
  
      while isinstance(
          stream, (_FixupStream, _NonClosingTextIOWrapper)
      ):
          stream = stream._stream
  
      return stream.__class__.__module__.startswith("ipykernel.")
  
imports: import codecs
  import io
  import os
  import re
  import sys
  from weakref import WeakKeyDictionary
label_desc: Use image node_id 9 for calling a global function with example usage: _is_jupyter_kernel_output(stream) and returns: stream