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

Refactor progress bars #1272

Merged
merged 2 commits into from
Jan 9, 2024
Merged

Commits on Jan 8, 2024

  1. Refactor progress bars

    tqdm progress bars are used in a couple of places. They don't play so well in
    non-interactive jobs, testing, ... . They also cause trouble with nbspinx
    (ICB-DCM#1246, ICB-DCM#1271).
    Progress bars can be disabled for specific tasks, but not globally (or at
    least not very conveniently).
    Since recently, tqdm can be controlled via environment variables (e.g.,
    disabling all progress bars or changing update frequency). However,
    this works by changing the argument defaults, so it only works if we don't
    pass explicit `disable=...`. Therefore, this PR introduces some wrapper that
    checks whether the user explicitly enabled/disabled progress bars. If not,
    we go with the tqdm default, which means showing all progress bars unless
    globally disabled. An additional `enabled` argument is added for convenience.
    dweindl committed Jan 8, 2024
    Configuration menu
    Copy the full SHA
    1a6a777 View commit details
    Browse the repository at this point in the history
  2. Update pypesto/util.py

    Co-authored-by: Dilan Pathirana <59329744+dilpath@users.noreply.github.com>
    dweindl and dilpath authored Jan 8, 2024
    Configuration menu
    Copy the full SHA
    98c287f View commit details
    Browse the repository at this point in the history