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

tqdm #38

Open
cmacdonald opened this issue Apr 16, 2021 · 3 comments
Open

tqdm #38

cmacdonald opened this issue Apr 16, 2021 · 3 comments

Comments

@cmacdonald
Copy link
Contributor

Sean, there is some peculiar tqdm setups in CEDR. Could we remove the leave=false and the ncols; perhaps set the units and some descriptions?

If you agree, I can submit a PR.

@seanmacavaney
Copy link
Contributor

seanmacavaney commented Apr 17, 2021

Yes, adding units and writing better descriptions would be helpful.

The leave and ncols settings are important for the usability of the tool on the command line. Removing ncols makes the tqdms really ugly (and the tool borderline unusable if you dare resize your console), and setting leave=False makes it much easier to scan the train/validation performance over time without dead tqdms getting in the way (which themselves no longer provide much/any value).

I know that ncols in notebooks produces some pretty ugly bars (it's the number of pixels, not the number of characters). What effect does leave=False have? Is there an easy way to detect that it's running in a notebook? If so, these could be set conditionally.

@cmacdonald
Copy link
Contributor Author

cmacdonald commented Apr 17, 2021

leave=False means the progress bar dissapears after use. If tqdm is obtained in imported in one single place, it could be overwritten?

@seanmacavaney
Copy link
Contributor

That sounds fair. So tqdm could be set with CLI defaults in CEDR, and then PyTerrier could overwrite that reference.

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

2 participants