Skip to content
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 setting precision for rate_fmt #1625

Open
gsemet opened this issue Oct 21, 2024 · 0 comments
Open

Allow setting precision for rate_fmt #1625

gsemet opened this issue Oct 21, 2024 · 0 comments

Comments

@gsemet
Copy link

gsemet commented Oct 21, 2024

Hello,

I would be nice to be able to set the precision for the rate_fmt parameter in format_meter. Especially the default value is hardcoded:

image

I would like to change it to "5.0f(no need to have 2 digits precisions, this free 3 characters in the line).

Proposal:

new parameter to the tqdm function example:

for fi in tqdm(zip_ref.infolist(), desc="Extracting ", unit="files", rate_fmt=f'{rate:5.0f}') if rate else '?') + unit + '/s')
...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant