class_docstr: A collection of callbacks added to a Tornado IOLoop that can be removed
  as a group.
class_docstr_tok: ["A","collection","of","callbacks","added","to","a","Tornado","IOLoop","that","can","be","removed","as","a","group","."]
code: def __init__(self, io_loop: IOLoop) -> None:
      self._loop = io_loop
      # dicts from callback to remove callable. These are separate only because
      # it's allowed to add the same callback as multiple kinds of callback at once.
      self._next_tick_callback_removers = {}
      self._timeout_callback_removers = {}
      self._periodic_callback_removers = {}
      self._removers_lock = threading.Lock()
  
      self._next_tick_removers_by_callable = defaultdict(set)
      self._timeout_removers_by_callable = defaultdict(set)
      self._periodic_removers_by_callable = defaultdict(set)
  
imports: from __future__ import annotations
  import logging
  import sys
  import threading
  from collections import defaultdict
  from traceback import format_exception
  from typing import TYPE_CHECKING, Any, Awaitable, Callable, Union
  import tornado
  from tornado import gen
  from ..core.types import ID
label_desc: Use image node_id 1 to create a new _CallbackGroup object  with example: obj = _CallbackGroup(io_loop)