{"id":15014809,"url":"https://github.com/evfro/ipypb","last_synced_at":"2025-04-09T19:23:30.310Z","repository":{"id":72682003,"uuid":"134061161","full_name":"evfro/ipypb","owner":"evfro","description":"Python progress bar with rich output that uses native ipython functionality. Widget-free. Works even in JupyterLab.","archived":false,"fork":false,"pushed_at":"2019-02-10T13:35:57.000Z","size":49,"stargazers_count":39,"open_issues_count":3,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-23T21:22:23.943Z","etag":null,"topics":["ipython","jupyter-notebook","jupyterlab","native","progress","progress-bar","progressbar"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/evfro.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-05-19T12:47:28.000Z","updated_at":"2024-09-05T07:18:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"4bc8e84c-916b-456b-b5dd-1d5c50a9ee35","html_url":"https://github.com/evfro/ipypb","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evfro%2Fipypb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evfro%2Fipypb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evfro%2Fipypb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/evfro%2Fipypb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/evfro","download_url":"https://codeload.github.com/evfro/ipypb/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248095958,"owners_count":21046952,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ipython","jupyter-notebook","jupyterlab","native","progress","progress-bar","progressbar"],"created_at":"2024-09-24T19:46:07.469Z","updated_at":"2025-04-09T19:23:30.279Z","avatar_url":"https://github.com/evfro.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Interactive ProgressBar\nPython progress bar that uses native ipython functionality. Widget-free. Works even in JupyterLab.\n\nThe reason for creating this package is that other progress bars use custom bar objects and/or widget tools, ignoring the builtin `IPython` functionality. This makes them unusable in \"clean\" environments like JupyterLab. In contrast, `ipypb` can run even in very restricted environments.\n\nAnother useful feature of `ipypb` is that the progress bar information is available even after closing a notebook and killing its ipython kernel. Once you launch this notebook again, you'll see the same progress bar information as before closing instead of widjet-related erorrs like `Failed to display Jupyter Widget of type HBox`, as shown below:\n\n![tqdm - display failure](https://user-images.githubusercontent.com/5283394/52354932-66a7ec80-2a42-11e9-9c10-d314c2bb2f5f.png)\n\nAlso have a look at this [NBViewer example](https://nbviewer.jupyter.org/github/evfro/ipypb/blob/master/examples/Usage%20examples.ipynb).\n\n# Notes\nCurrently at beta stage.\n\nSimple usage example:\n```python\nfrom time import sleep\nfrom ipypb import track\n\nfor i in track(range(10)):\n    sleep(0.1)\n```\nA few other conveniences are available. For example, you can use `ipypb` as a python's range-like function:\n```python\nfrom ipypb import irange\n\nfor i in irange(1, 10, 2): # same as range(1, 10, 2) but with progressbar\n    # \u003cdo stuff\u003e\n    ...\n```\nIt may also be helpful to use the factory method `ipb`, which handles different usage scenarios and returns either `track` or `irange` instance depending on input arguments. Another usage example is when you already have a bunch of code with [`tqdm`](https://github.com/tqdm/tqdm) and want to \nreplace it with `ipypb`:\n```python\nfrom ipypb import ipb\n\ntqdm_notebook = ipb\n# or if you run it in interactive shell\ntqdm = ipb\n```\nIt will automatically process keyword arguments to ensure compatibility with `tqdm`'s API. Note, that `ipb` offers a common interface for both notebook and terminal environments.\n\n## Asynchronous flow\nIt's also possible to use `ipypb` for tracking tasks that are executed asyncrhonously or in parallel. The major use case is when the order of executed tasks from a task pool doesn't correspond to the desired order for displaying a progress. In this case, you can instruct `ipypb` to preserve the desired order by submitting a description of the progress hierarchy. Below is an example for simple heirarchy consisting of three levels: `i \u003c-- j \u003c-- k`. Progress on each parent level depends on full exectunion of its sublevels. Note how levels `k:1` and `k:2` get moved to the group `j:0` they belong to, even though initially they appear in the end, below the `j:1` group:\n\n![ipypb - async flow](https://user-images.githubusercontent.com/5283394/52353228-26933a80-2a3f-11e9-927a-6bd114f87abe.gif)\n\n**Note**: this feature is currently in provisional state, which means that its API main change in future releases. In order to test it, do \n```python\nfrom ipypb import chain\n```\n\n# Install\n`pip install --upgrade ipypb`\n\n# Requirements\nPython 3.6+ and IPython v.5.6+ excluding v.6.1 and v.6.2\n\n# Limitations\n- The feature to erase progressbar when loop is over is not yet supported.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevfro%2Fipypb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fevfro%2Fipypb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fevfro%2Fipypb/lists"}