Skip to content

Progress bars#2552

Open
sdrave wants to merge 11 commits into
mainfrom
rich_progress
Open

Progress bars#2552
sdrave wants to merge 11 commits into
mainfrom
rich_progress

Conversation

@sdrave

@sdrave sdrave commented Apr 23, 2026

Copy link
Copy Markdown
Member

This PR adds experimental support for progress bars throughout pyMOR. Since there might still be issues with the generated output on different platforms, progress bars are disabled by default. To enable, set the PYMOR_PROGRESS environment variable to 1.

Multiple tasks can be tracked at the same time using individual progress bars. Finished bars are removed after some time or when a new task is started.

  • Adds ProgressDisplay abstract base class and Task objects.
  • The track and add_task allow adding progress bars to the current active ProgressDisplay.
  • Implements ProgressDisplay using rich.
  • Use progress bars for various algorithms (gram_schmidt, ei_greedy, deim, interpolate_operators, reduction_error_analysis, DummyPool.map).

@sdrave sdrave added the pr:new-feature Introduces a new feature label Apr 23, 2026
@codecov

codecov Bot commented Apr 23, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 66.47727% with 59 lines in your changes missing coverage. Please review.
✅ Project coverage is 87.29%. Comparing base (648a321) to head (406bb7f).
⚠️ Report is 43 commits behind head on main.

Files with missing lines Patch % Lines
src/pymor/tools/progress.py 52.54% 56 Missing ⚠️
src/pymor/core/logger.py 71.42% 2 Missing ⚠️
src/pymor/parallel/dummy.py 80.00% 1 Missing ⚠️
Additional details and impacted files
Flag Coverage Δ
github_actions 78.28% <65.90%> (-0.33%) ⬇️
gitlab_ci 87.99% <66.47%> (-0.13%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/pymor/algorithms/ei.py 88.28% <100.00%> (+0.09%) ⬆️
src/pymor/algorithms/error.py 79.04% <ø> (-0.30%) ⬇️
src/pymor/algorithms/gram_schmidt.py 98.00% <100.00%> (+0.06%) ⬆️
src/pymor/algorithms/greedy.py 93.69% <100.00%> (+2.78%) ⬆️
src/pymor/parallel/basic.py 81.17% <100.00%> (ø)
src/pymor/parallel/interface.py 79.48% <100.00%> (ø)
src/pymordemos/burgers_ei.py 99.13% <100.00%> (-0.02%) ⬇️
src/pymor/parallel/dummy.py 82.50% <80.00%> (-1.29%) ⬇️
src/pymor/core/logger.py 76.84% <71.42%> (-0.32%) ⬇️
src/pymor/tools/progress.py 52.54% <52.54%> (ø)

... and 19 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@artpelling

Copy link
Copy Markdown
Member

finally!

@artpelling artpelling added this to the 2026.1 milestone May 29, 2026
@sdrave sdrave marked this pull request as ready for review June 1, 2026 11:36
@sdrave

sdrave commented Jun 1, 2026

Copy link
Copy Markdown
Member Author

@HenKlei, @pmli, this is done now from my perspective. Before merging: Could you play with this a little to see if things work as expected for you, for instance by running the thermalblock demo. Also, feel free to add support for a few more algorithms.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr:new-feature Introduces a new feature

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants