class_docstr: Central tqdm manager run on the driver.
  
  This class holds a collection of BarGroups and updates their `pos_offset` as
  needed to ensure individual progress bars do not collide in position, kind of
  like a virtual memory manager.
class_docstr_tok: ["Central","tqdm","manager","run","on","the","driver",".","This","class","holds","a","collection","of","BarGroups","and","updates","their","`","pos_offset","`","as","needed","to","ensure","individual","progress","bars","do","not","collide","in","position",",","kind","of","like","a","virtual","memory","manager","."]
code: def _get_or_allocate_bar_group(self, state: ProgressBarState):
      ptuple = (state["ip"], state["pid"])
      if ptuple not in self.bar_groups:
          offset = sum(
              p.slots_required() for p in self.bar_groups.values()
          )
          self.bar_groups[ptuple] = _BarGroup(
              state["ip"], state["pid"], offset
          )
      return self.bar_groups[ptuple]
  
imports: import builtins
  import copy
  import json
  import logging
  import os
  import sys
  import threading
  import time
  import uuid
  from typing import Any, Dict, Iterable, Optional
  import colorama
  import ray
  from ray._private.ray_constants import env_bool
  from ray.util.debug import log_once
label_desc: Use image node_id 6 for calling the _BarManager obj's underlying member method code with example usage: obj._get_or_allocate_bar_group(state) and returns: self