spkit.utils.ProgBar

spkit.utils.ProgBar(i, N, title='', style=2, L=50, selfTerminate=False, sym='▓', color='blue')

Progress Bar : Utilities

Progress Bar

▇ ▓ ▒ ░ ▉

Parameters:
i: int, float
  • current index

N: int, float,
  • Final number

sym: symbol, default=’▓’
  • symbol as bar {▇ ▓ ▒ ░ ▉}

color: str,
  • one of {‘green’,’blue’,’cyan’,’red’,’yellow’}

title: str,
  • title to show end of the bar

style: int, {1,2}, default=2
  • different styles

L: int {100,50}
  • length of Bar

selfTerminate: bool, default=True
  • if i>N, it terminates

Returns:
displaybars

See also

ProgBar

Examples

>>> #sp.utils.ProgBar
>>> import time
>>> import numpy as np
>>> import spkit as sp
>>> N = 340 
>>> for i in range(N):
>>>     sp.utils.ProgBar(i,N, style=2,sym='▓',color='blue',title='example-1')
100%|▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓|340\340| example-1
Done!