Supersonic is an Open-Source library for creating progress indicators (e.g. progress bars). It is super fast and super customizable.
Use this command to install Supersonic: pip install supersonic
After you have installed Supersonic, you can test if it has been successfully installed by running import supersonic
in python. If Supersonic was installed successfully, it should show no errors.
import supersonic as ss
import time
## Arguments
### t (the first argument) - Prefix text
### total - Total
### pdigits - Number of digits of the percentage to show
### ascii - True: Ascii, False: Unicode
### bar_length - Progress bar length
# Supersonic 1.2 now supports context managers!
with ss.sonic("Testing", total=1000, pdigits=1, ascii=False, bar_length=20) as p:
for i in range(1000):
p.progress() #or p.stat(i+1)
time.sleep(0.01)
A great thing about Supersonic is that you can extend it's capability with Extensions. You can find out more about Extensions here: supersonic/exts/README.md
supersonic.
supersonic(total=100, pdigits=1, ascii=True, bar_length=15)
supersonic.
sonic(total=100, pdigits=1, ascii=True, bar_length=15)
supersonic.supersonic
is a wrapper around supersonic.custom
that let's you create progress bars without creating your own layout. If you want full control over the final product, checkout supersonic.custom
.
supersonic. custom(*arrangement, total=100)
Example:
supersonic.custom(Percentage(), " |", Bar(), "| done")
# Result:
# 50% |########## | done
Current progress.
show(), update()
Clear last status and show.
clear()
Clear last status.
stat(stat)
Set status to a specific value stat
.
progress(by=1)
Increase the current status by a specific value by
.
done()
Finished task!
supersonic.ext. Extension()
The base class for all Supersonic Extensions. If you want to make your own extensions, see here: supersonic/exts/README.md
Checkout my website at http://www.WhatsYourIdea.com/