Shortcuts

ProgressBar

class mmengine.utils.ProgressBar(task_num=0, bar_width=50, start=True, file=<_io.TextIOWrapper name='<stdout>' mode='w' encoding='utf-8'>)[source]

A progress bar which can print the progress.

Parameters
  • task_num (int) – Number of total steps. Defaults to 0.

  • bar_width (int) – Width of the progress bar. Defaults to 50.

  • start (bool) – Whether to start the progress bar in the constructor. Defaults to True.

  • file (callable) – Progress bar output mode. Defaults to “sys.stdout”.

Examples

>>> import mmengine
>>> import time
>>> bar = mmengine.ProgressBar(10)
>>> for i in range(10):
>>>    bar.update()
>>>    time.sleep(1)
update(num_tasks=1)[source]

update progressbar.

Parameters

num_tasks (int) – Update step size.

Read the Docs v: stable
Versions
latest
stable
v0.10.2
v0.10.1
v0.10.0
v0.9.1
v0.9.0
v0.8.5
v0.8.4
v0.8.3
v0.8.2
v0.8.1
v0.8.0
v0.7.4
v0.7.3
v0.7.2
v0.7.1
v0.7.0
v0.6.0
v0.5.0
v0.4.0
v0.3.0
v0.2.0
Downloads
epub
On Read the Docs
Project Home
Builds

Free document hosting provided by Read the Docs.