MCPcopy Create free account
hub / github.com/ipython/ipython / __init__

Method __init__

IPython/core/display.py:795–807  ·  view source on GitHub ↗

Creates a new progressbar Parameters ---------- total : int maximum size of the progressbar

(self, total)

Source from the content-addressed store, hash-verified

793 """Progressbar supports displaying a progressbar like element
794 """
795 def __init__(self, total):
796 """Creates a new progressbar
797
798 Parameters
799 ----------
800 total : int
801 maximum size of the progressbar
802 """
803 self.total = total
804 self._progress = 0
805 self.html_width = '60ex'
806 self.text_width = 60
807 self._display_id = hexlify(os.urandom(8)).decode('ascii')
808
809 def __repr__(self):
810 fraction = self.progress / self.total

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected