Is it possible to access the current item in a for loop in the prefix of a progressbar (the desc keyword argument). That is, to get something like this to work:
from tqdm import tqdm
for x in tqdm(['a' ,'b', 'c'], desc='item {}'.format(x)):
pass
That code produces a NameError: name 'x' is not defined at the line of the for loop. Could it be made instead to create a progressbar where the prefix updates with x in the for loop.
item a: 100%|███████████████████████████████████████| 1/3 [00:00<?, ?it/s]
item b: 100%|███████████████████████████████████████| 2/3 [00:00<?, ?it/s]
item c: 100%|███████████████████████████████████████| 3/3 [00:00<?, ?it/s]