According to https://github.com/tqdm/tqdm?tab=readme-ov-file#nested-progress-bars and https://github.com/tqdm/tqdm/blob/master/examples/parallel_bars.py,
with futures.ProcessPoolExecutor(
max_workers=PROCESSES,
initializer=tqdm.tqdm.set_lock,
initargs=(tqdm.tqdm.get_lock(),),
) as executor:
to share the same tqdm.tqdm._lock = TqdmDefaultWriteLock()
among the processes.