def show_progress(self, n, total_runs):
if self.report_progress:<EOL><INDENT>percentage, logger_name, log_level = self.report_progress<EOL>if logger_name == '<STR_LIT>':<EOL><INDENT>logger = '<STR_LIT>'<EOL><DEDENT>else:<EOL><INDENT>logger = logging.getLogger(logger_name)<EOL><DEDENT>if n == -<NUM_LIT:1>:<EOL><INDENT>digits = int(math.log10(total_runs + <NUM_LIT:0.1>)) + <NUM_LIT:1><EOL>self._format_string = '<STR_LIT>' + '<STR_LIT>' % digits + '<STR_LIT>'<EOL><DEDENT>fmt_string = self._format_string % (n + <NUM_LIT:1>, total_runs) + '<STR_LIT:%s>'<EOL>reprint = log_level == <NUM_LIT:0><EOL>progressbar(n, total_runs, percentage_step=percentage,<EOL>logger=logger, log_level=log_level,<EOL>fmt_string=fmt_string, reprint=reprint)<EOL><DEDENT>
Displays a progressbar