New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow to pass second iterable to tqdm() to display custom progress? #1545
Comments
I think a more general solution is to pass in a lambda expression (or function) which takes the current item as the argument. For example,
@JohannesWiesner, it is too restrictive to pass in a list for displaying the current item because |
@xuancong84 Will try that, thanks! What is |
@JohannesWiesner It is my proposal, so not implemented yet. Would be glad if the developer can implement in this way. |
read the [known issues]
environment, where applicable:
Hi! I already posted a thread on SO but I think I have to specify my question further. I would like to separate the internal logic of my function from the optional progress output using tqdm. Specifically I would like to print the current amount of data copied if wished by the user. For that, it would be nice, if I could use
tqdm(my_iterable)
to "activate" the progress bar but then also pass a second iterable to it (cumulative file sizes) that is used to show the progress. Here's an example:The text was updated successfully, but these errors were encountered: