Fastprogress

1.1.5 · active · verified Sat Apr 11

Fastprogress is a Python library providing fast and simple progress bars for Jupyter Notebooks and console applications. It features nested progress bars and plotting options, often used within the fastai ecosystem. The library is actively maintained with frequent minor releases, most recently v1.1.5, and has a cadence of several updates per year.

Warnings

Install

Imports

Quickstart

This example demonstrates a nested progress bar. `master_bar` handles the outer loop, and `progress_bar` handles the inner loop, linked via the `parent` argument. Comments can be updated, and `mb.write()` adds persistent messages.

from fastprogress.fastprogress import master_bar, progress_bar
import time

mb = master_bar(range(10))
mb.write('Starting main loop...')
for i in mb:
    mb.main_bar.comment = f'Processing outer item {i+1}/10'
    for j in progress_bar(range(100), parent=mb):
        time.sleep(0.01) # Simulate some work
    mb.child.comment = f'Inner loop for item {i+1} complete'
    mb.write(f'Finished outer loop iteration {i+1}.')
mb.write('All loops complete.')

view raw JSON →