def print_perf_info(self, result_list, output_file=None):
        result_list = filter(lambda x: isinstance(x, FlashTestResult), result_list)

        print("\r\n\r\n------ Analyzer Performance ------", file=output_file)
        perf_format_str = "{:<10}{:<12}{:<18}{:<18}"
        print(perf_format_str.format("Target", "Analyzer", "Rate", "Time"),
              file=output_file)
        print("", file=output_file)
        for result in result_list:
            if result.passed:
                analyze_rate = "%f KB/s" % (result.analyze_rate / float(1000))
                analyze_time = "%s s" % result.analyze_time
            else:
                analyze_rate = "Fail"
                analyze_time = "Fail"
            print(perf_format_str.format(result.board.target_type,
                                         result.analyze, analyze_rate,
                                         analyze_time),
                  file=output_file)
        print("", file=output_file)

        print("\r\n\r\n------ Test Rate ------", file=output_file)
        rate_format_str = "{:<10}{:<20}{:<20}{:<20}"
        print(rate_format_str.format("Target", "Chip Erase", "Page Erase",
                                     "Page Erase (Same data)"),
              file=output_file)
        print("", file=output_file)
        for result in result_list:
            if result.passed:
                chip_erase_rate = "%f KB/s" % (result.chip_erase_rate / float(1000))
                page_erase_rate = "%f KB/s" % (result.page_erase_rate / float(1000))
                page_erase_rate_same = "%f KB/s" % (result.page_erase_rate_same / float(1000))
            else:
                chip_erase_rate = "Fail"
                page_erase_rate = "Fail"
                page_erase_rate_same = "Fail"
            print(rate_format_str.format(result.board.target_type,
                                         chip_erase_rate, page_erase_rate,
                                         page_erase_rate_same),
                  file=output_file)
        print("", file=output_file)
dataset/ETHPy150Open mbedmicro/pyOCD/test/flash_test.py/FlashTest.print_perf_info/original