code: def _cleanup():
      # check for processes which have finished
      for p in list(_children):
          if (
              child_popen := p._popen
          ) and child_popen.poll() is not None:
              _children.discard(p)
  
imports: import os
  import sys
  import signal
  import itertools
  import threading
  from _weakrefset import WeakSet
label_desc: Use image node_id 4 for calling a global function with example usage: _cleanup() without return types