Relative Content

Tag Archive for python-multiprocessingtqdm

TQDM: Track loop inside ProcessPoolExecutor job

I have some number of jobs that have been submitted to a ProcessPoolExecutor. I want to track the progress of each job with tqdm. However, when I run the code below, the progress bars constantly swap places. I believe this is because *handwavey asynchronicity explanation* but I don’t know the method to get around that. I imagine I could theoretically pipeline the progress bar up to the parent process, but I’m not familiar enough with concurrent or tqdm to do that. What’s the pythonic answer?

TQDM: Track loop inside ProcesPoolExecutor job

I have some number of jobs that have been submitted to a ProcessPoolExecutor. I want to track the progress of each job with tqdm. However, when I run the code below, the progress bars constantly swap places. I believe this is because *handwavey asynchronicity explanation* but I don’t know the method to get around that. I imagine I could theoretically pipeline the progress bar up to the parent process, but I’m not familiar enough with concurrent or tqdm to do that. What’s the pythonic answer?