From 98a66be77a17e4590cc789b019126c8713315619 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 12 Sep 2024 16:22:44 +0200 Subject: [PATCH 01/21] port wmops webpage creation script to python --- .../genWebpageData_WMOPS.py | 50 +++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100644 ci/complexity_measurements/genWebpageData_WMOPS.py diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py new file mode 100644 index 0000000000..89b7c44448 --- /dev/null +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -0,0 +1,50 @@ +import argparse + + +RUNS_KEYS_COMMON = ["fullDate", "shortDate", "revision"] +RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ + "worstCaseEnc", + "worstCaseDec", + "worstCaseCodec", + "worstCaseEncRs", + "worstCaseDecRs", + "worstCaseCodecRs", + "fixpointScalingFac", + "logFile", +] + +RUNS_KEYS = { + "wmops": RUNS_KEYS_WMOPS, +} +RUNS_LINE_IDX = { + "wmops": [2, 1, 0, 4, 6, 8, 12, 14, 16, 10, 18], +} + + +def main(wmops_log): + with open(wmops_log) as f: + wmops_log_lines = f.readlines() + + wmops_runs = [ + create_runs_string(line.strip().split(" "), "wmops") for line in wmops_log_lines + ] + wmops_runs_string = ",\n".join(wmops_runs) + + print(wmops_runs_string) + + +def create_runs_string(line: list[str], which: str) -> str: + keys = RUNS_KEYS[which] + vals = [line[i] for i in RUNS_LINE_IDX[which]] + run = str(dict(zip(keys, vals))) + + return run + + +if __name__ == "__main__": + parser = argparse.ArgumentParser() + parser.add_argument("wmops_log") + + args = parser.parse_args() + + main(args.wmops_log) -- GitLab From e50dfbf89fb5ac00eea5ffe2172f76cf3722488b Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 12 Sep 2024 17:30:40 +0200 Subject: [PATCH 02/21] finish with wMOPS JS file generation --- .../genWebpageData_WMOPS.py | 92 +++++++++++++++++-- 1 file changed, 85 insertions(+), 7 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py index 89b7c44448..793d15bb36 100644 --- a/ci/complexity_measurements/genWebpageData_WMOPS.py +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -1,6 +1,8 @@ import argparse +MAX_VALUES = 40 + RUNS_KEYS_COMMON = ["fullDate", "shortDate", "revision"] RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "worstCaseEnc", @@ -20,17 +22,81 @@ RUNS_LINE_IDX = { "wmops": [2, 1, 0, 4, 6, 8, 12, 14, 16, 10, 18], } +DISPLAY_IDS = { + "wmops": [ + "requirement", + "worst case codec", + "worst case enc/dec", + "worst case enc", + "worst case dec", + "worst case codec rs", + "worst case enc/dec rs", + "worst case enc rs", + "worst case dec rs", + ] +} +DISPLAY_LINE_IDX = { + "wmops": [-1, 9, 3, 5, 7, 17, 11, 13, 15], +} +DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fillColor: "#ffffff" }}, borderWidth: 1.5, borderColor: "#BEBEBE", markingsLineWidth: .75, hoverable: true, clickable: false, shadowSize: 0, color: "{color}", id: "{id}", data: [ {data} ] }}' + +LINE_COLORS = [ + "#000000", + "#0080FF", + "#FF8000", + "#CF4B4B", + "#008040", + "#40C4FF", + "#FFC480", + "#CF8080", + "#00F040", +] + +JS_FILE_TEMPLATE = """var {var_name} = {{ + {elem_name}: {{ + description: "{description}", + direction: -1, + runs: [ + {runs} + ], + displays: [ + {displays} + ] + }} +}}; +""" + +FILE_DATA = { + "wmops": { + "var_name": "Graphs_WMOPS", + "elem_name": "wmops_worstcase", + "description": "Worst Case WMOPS", + "filename": "graphs_wmops_flc.js", + } +} + def main(wmops_log): - with open(wmops_log) as f: - wmops_log_lines = f.readlines() + FILE_DATA["wmops"]["log_file"] = wmops_log - wmops_runs = [ - create_runs_string(line.strip().split(" "), "wmops") for line in wmops_log_lines - ] - wmops_runs_string = ",\n".join(wmops_runs) + for x, data in FILE_DATA.items(): + with open(data["log_file"]) as f: + log_lines = f.readlines()[-MAX_VALUES:] - print(wmops_runs_string) + runs = [create_runs_string(line.strip().split(" "), x) for line in log_lines] + displays = [ + create_display_string(log_lines, id, idx, color) + for id, idx, color in zip(DISPLAY_IDS[x], DISPLAY_LINE_IDX[x], LINE_COLORS) + ] + wmops_js_string = JS_FILE_TEMPLATE.format( + var_name=data["var_name"], + elem_name=data["elem_name"], + description=data["description"], + runs=",\n".join(runs), + displays=",\n".join(displays), + ) + with open(data["filename"], "w") as f: + print(wmops_js_string, file=f) def create_runs_string(line: list[str], which: str) -> str: @@ -41,6 +107,18 @@ def create_runs_string(line: list[str], which: str) -> str: return run +def create_display_string(log_lines, id, idx, color): + data = list() + for i, line in enumerate(log_lines): + value = line.split(" ")[idx] + if id == "requirement": + value = 0 + data.append(f"[{i}, {value}]") + + display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) + return display + + if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("wmops_log") -- GitLab From e61cbc45078324c3eda686b5dc2e19492b7e752e Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 12 Sep 2024 17:45:25 +0200 Subject: [PATCH 03/21] add rom JS file generation --- .../genWebpageData_WMOPS.py | 96 +++++++++++++++---- 1 file changed, 76 insertions(+), 20 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py index 793d15bb36..68940c755e 100644 --- a/ci/complexity_measurements/genWebpageData_WMOPS.py +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -14,12 +14,25 @@ RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "fixpointScalingFac", "logFile", ] +RUNS_KEYS_ROM = RUNS_KEYS_COMMON + [ + "PromEnc", + "PromDec", + "PromCom", + "PromRend", + "TromEnc", + "TromDec", + "TromCom", + "TromRend", + "logFile", +] RUNS_KEYS = { "wmops": RUNS_KEYS_WMOPS, + "rom": RUNS_KEYS_ROM, } RUNS_LINE_IDX = { "wmops": [2, 1, 0, 4, 6, 8, 12, 14, 16, 10, 18], + "rom": [2, 1, 0, 4, 6, 8, 10, 12, 14, 16, 18, 20], } DISPLAY_IDS = { @@ -33,24 +46,51 @@ DISPLAY_IDS = { "worst case enc/dec rs", "worst case enc rs", "worst case dec rs", - ] + ], + "rom": [ + "requirementRom", + "TotalRomCodecScore", + "maxPROMEncScore", + "maxPROMDecScore", + "maxPROMComScore", + "maxPROMRendScore", + "maxTROMEncScore", + "maxTROMDecScore", + "maxTROMComScore", + "maxTROMRendScore", + ], } DISPLAY_LINE_IDX = { "wmops": [-1, 9, 3, 5, 7, 17, 11, 13, 15], + "rom": [-1, 3, 5, 7, 9, 11, 13, 15, 17, 19], } DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fillColor: "#ffffff" }}, borderWidth: 1.5, borderColor: "#BEBEBE", markingsLineWidth: .75, hoverable: true, clickable: false, shadowSize: 0, color: "{color}", id: "{id}", data: [ {data} ] }}' -LINE_COLORS = [ - "#000000", - "#0080FF", - "#FF8000", - "#CF4B4B", - "#008040", - "#40C4FF", - "#FFC480", - "#CF8080", - "#00F040", -] +LINE_COLORS = { + "wmops": [ + "#000000", + "#0080FF", + "#FF8000", + "#CF4B4B", + "#008040", + "#40C4FF", + "#FFC480", + "#CF8080", + "#00F040", + ], + "rom": [ + "#000000", + "#FF0000", + "#FF8000", + "#FFFF00", + "#800080", + "#0000FF", + "#0080C0", + "#004000", + "#008000", + "#00FF00", + ], +} JS_FILE_TEMPLATE = """var {var_name} = {{ {elem_name}: {{ @@ -72,12 +112,25 @@ FILE_DATA = { "elem_name": "wmops_worstcase", "description": "Worst Case WMOPS", "filename": "graphs_wmops_flc.js", - } + "references": { + "requirement": 0, + }, + }, + "rom": { + "var_name": "Graphs_ROM", + "elem_name": "rom_worstcase", + "description": "ROM", + "filename": "graphs_rom_flc.js", + "references": { + "requirementRom": 0, + }, + }, } -def main(wmops_log): +def main(wmops_log, rom_log): FILE_DATA["wmops"]["log_file"] = wmops_log + FILE_DATA["rom"]["log_file"] = rom_log for x, data in FILE_DATA.items(): with open(data["log_file"]) as f: @@ -85,8 +138,10 @@ def main(wmops_log): runs = [create_runs_string(line.strip().split(" "), x) for line in log_lines] displays = [ - create_display_string(log_lines, id, idx, color) - for id, idx, color in zip(DISPLAY_IDS[x], DISPLAY_LINE_IDX[x], LINE_COLORS) + create_display_string(log_lines, id, idx, color, data["references"]) + for id, idx, color in zip( + DISPLAY_IDS[x], DISPLAY_LINE_IDX[x], LINE_COLORS[x] + ) ] wmops_js_string = JS_FILE_TEMPLATE.format( var_name=data["var_name"], @@ -107,12 +162,12 @@ def create_runs_string(line: list[str], which: str) -> str: return run -def create_display_string(log_lines, id, idx, color): +def create_display_string(log_lines, id, idx, color, references): data = list() for i, line in enumerate(log_lines): value = line.split(" ")[idx] - if id == "requirement": - value = 0 + if id in references: + value = references[id] data.append(f"[{i}, {value}]") display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) @@ -122,7 +177,8 @@ def create_display_string(log_lines, id, idx, color): if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("wmops_log") + parser.add_argument("rom_log") args = parser.parse_args() - main(args.wmops_log) + main(args.wmops_log, args.rom_log) -- GitLab From 9e8e787049831b46b4146add72b3c3476bb0f826 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 09:20:57 +0200 Subject: [PATCH 04/21] add ram js file generation --- .../genWebpageData_WMOPS.py | 58 ++++++++++++++++--- 1 file changed, 51 insertions(+), 7 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py index 68940c755e..0c5b6ce057 100644 --- a/ci/complexity_measurements/genWebpageData_WMOPS.py +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -3,7 +3,7 @@ import argparse MAX_VALUES = 40 -RUNS_KEYS_COMMON = ["fullDate", "shortDate", "revision"] +RUNS_KEYS_COMMON = ["fullDate", "shortDate", "revision", "logFile"] RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "worstCaseEnc", "worstCaseDec", @@ -12,7 +12,6 @@ RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "worstCaseDecRs", "worstCaseCodecRs", "fixpointScalingFac", - "logFile", ] RUNS_KEYS_ROM = RUNS_KEYS_COMMON + [ "PromEnc", @@ -23,16 +22,25 @@ RUNS_KEYS_ROM = RUNS_KEYS_COMMON + [ "TromDec", "TromCom", "TromRend", - "logFile", +] +RUNS_KEYS_RAM = RUNS_KEYS_COMMON + [ + "maxTotalRamEnc", + "maxTotalRamDec", + "maxStackEnc", + "maxStackDec", + "maxHeapEnc", + "maxHeapDec", ] RUNS_KEYS = { "wmops": RUNS_KEYS_WMOPS, "rom": RUNS_KEYS_ROM, + "ram": RUNS_KEYS_RAM, } RUNS_LINE_IDX = { "wmops": [2, 1, 0, 4, 6, 8, 12, 14, 16, 10, 18], "rom": [2, 1, 0, 4, 6, 8, 10, 12, 14, 16, 18, 20], + "ram": [2, 1, 0, 4, 6, 9, 11, 14, 16, 18], } DISPLAY_IDS = { @@ -59,10 +67,23 @@ DISPLAY_IDS = { "maxTROMComScore", "maxTROMRendScore", ], + "ram": [ + "requirementRam", + "maxTotalRamCodecScore", + "maxTotalRamEncScore", + "maxTotalRamDecScore", + "maxStackCodecScore", + "maxStackEncScore", + "maxStackDecScore", + "maxHeapCodecScore", + "maxHeapEncScore", + "maxHeapDecScore", + ], } DISPLAY_LINE_IDX = { "wmops": [-1, 9, 3, 5, 7, 17, 11, 13, 15], "rom": [-1, 3, 5, 7, 9, 11, 13, 15, 17, 19], + "ram": [-1, 3, 5, 7, 8, 10, 12, 13, 15, 17], } DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fillColor: "#ffffff" }}, borderWidth: 1.5, borderColor: "#BEBEBE", markingsLineWidth: .75, hoverable: true, clickable: false, shadowSize: 0, color: "{color}", id: "{id}", data: [ {data} ] }}' @@ -90,6 +111,18 @@ LINE_COLORS = { "#008000", "#00FF00", ], + "ram": [ + "#000000", + "#FF0000", + "#FF8000", + "#FFFF00", + "#004000", + "#008000", + "#00FF00", + "#800080", + "#0000FF", + "#0080C0", + ], } JS_FILE_TEMPLATE = """var {var_name} = {{ @@ -125,12 +158,22 @@ FILE_DATA = { "requirementRom": 0, }, }, + "ram": { + "var_name": "Graphs_RAM", + "elem_name": "ram_worstcase", + "description": "Worst Case RAM", + "filename": "graphs_ram_flc.js", + "references": { + "requirementRam": 0, + }, + }, } -def main(wmops_log, rom_log): +def main(wmops_log, rom_log, ram_log): FILE_DATA["wmops"]["log_file"] = wmops_log FILE_DATA["rom"]["log_file"] = rom_log + FILE_DATA["ram"]["log_file"] = ram_log for x, data in FILE_DATA.items(): with open(data["log_file"]) as f: @@ -143,7 +186,7 @@ def main(wmops_log, rom_log): DISPLAY_IDS[x], DISPLAY_LINE_IDX[x], LINE_COLORS[x] ) ] - wmops_js_string = JS_FILE_TEMPLATE.format( + js_string = JS_FILE_TEMPLATE.format( var_name=data["var_name"], elem_name=data["elem_name"], description=data["description"], @@ -151,7 +194,7 @@ def main(wmops_log, rom_log): displays=",\n".join(displays), ) with open(data["filename"], "w") as f: - print(wmops_js_string, file=f) + print(js_string, file=f) def create_runs_string(line: list[str], which: str) -> str: @@ -178,7 +221,8 @@ if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("wmops_log") parser.add_argument("rom_log") + parser.add_argument("ram_log") args = parser.parse_args() - main(args.wmops_log, args.rom_log) + main(args.wmops_log, args.rom_log, args.ram_log) -- GitLab From 45d7abe9ba4cbadd3172c988902e5cbe03ba6f97 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 11:44:48 +0200 Subject: [PATCH 05/21] add also WMOPS_per_op handling --- .../genWebpageData_WMOPS.py | 115 ++++++++++++++++-- 1 file changed, 104 insertions(+), 11 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py index 0c5b6ce057..1164098580 100644 --- a/ci/complexity_measurements/genWebpageData_WMOPS.py +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -13,6 +13,10 @@ RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "worstCaseCodecRs", "fixpointScalingFac", ] +RUNS_KEYS_WMOPS_PER_OP = [ + "operatingPoint", + "mode", +] RUNS_KEYS_ROM = RUNS_KEYS_COMMON + [ "PromEnc", "PromDec", @@ -36,11 +40,13 @@ RUNS_KEYS = { "wmops": RUNS_KEYS_WMOPS, "rom": RUNS_KEYS_ROM, "ram": RUNS_KEYS_RAM, + "wmops_per_op": RUNS_KEYS_WMOPS_PER_OP, } RUNS_LINE_IDX = { "wmops": [2, 1, 0, 4, 6, 8, 12, 14, 16, 10, 18], "rom": [2, 1, 0, 4, 6, 8, 10, 12, 14, 16, 18, 20], "ram": [2, 1, 0, 4, 6, 9, 11, 14, 16, 18], + "wmops_per_op": [0, 4], } DISPLAY_IDS = { @@ -79,11 +85,19 @@ DISPLAY_IDS = { "maxHeapEncScore", "maxHeapDecScore", ], + "wmops_per_op": [ + "worstCaseEnc", + "worstCaseDec", + ], } DISPLAY_LINE_IDX = { "wmops": [-1, 9, 3, 5, 7, 17, 11, 13, 15], "rom": [-1, 3, 5, 7, 9, 11, 13, 15, 17, 19], "ram": [-1, 3, 5, 7, 8, 10, 12, 13, 15, 17], + "wmops_per_op": [1, 2], +} +DISPLAY_LABELS = { + "wmops_per_op": ["Encoder", "Decoder"], } DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fillColor: "#ffffff" }}, borderWidth: 1.5, borderColor: "#BEBEBE", markingsLineWidth: .75, hoverable: true, clickable: false, shadowSize: 0, color: "{color}", id: "{id}", data: [ {data} ] }}' @@ -123,12 +137,19 @@ LINE_COLORS = { "#0000FF", "#0080C0", ], + "wmops_per_op": [ + "#CF4B4B", + "#008040", + ], } JS_FILE_TEMPLATE = """var {var_name} = {{ {elem_name}: {{ description: "{description}", direction: -1, + ticks: [ + {ticks} + ], runs: [ {runs} ], @@ -167,31 +188,92 @@ FILE_DATA = { "requirementRam": 0, }, }, + "wmops_per_op": { + "var_name": "Graphs_WMOPS_perOP", + "elem_name": "wmops_worstcase_per_op", + "description": "Worst Case WMOPS per OP", + "filename": "graphs_wmops_flc_perOP.js", + "references": {}, + }, } -def main(wmops_log, rom_log, ram_log): +def main(wmops_log, wmops_per_op_log, rom_log, ram_log): FILE_DATA["wmops"]["log_file"] = wmops_log + FILE_DATA["wmops_per_op"]["log_file"] = wmops_per_op_log FILE_DATA["rom"]["log_file"] = rom_log FILE_DATA["ram"]["log_file"] = ram_log for x, data in FILE_DATA.items(): with open(data["log_file"]) as f: - log_lines = f.readlines()[-MAX_VALUES:] + log_lines = f.readlines() + + split_char = " " + ticks = [] + if x == "wmops_per_op": + split_char = ";" + # some preprocessing is needed so that the later functions work as are + # 1. need to make sure that modes are ordered by bandwidth + # 2. need to add the bandwidth indicator as a column + wb_lines, swb_lines, fb_lines = [], [], [] + for line in log_lines: + if " WB " in line: + wb_lines.append(line + ";WB") + elif " SWB " in line: + swb_lines.append(line + ";SWB") + elif " FB " in line: + fb_lines.append(line + ";FB") + log_lines = wb_lines + swb_lines + fb_lines - runs = [create_runs_string(line.strip().split(" "), x) for line in log_lines] + # generate tick positions and x axis labels from the number of lines + in_between_offset_size = 1 + wb_label_pos = len(wb_lines) / 2 + swb_label_pos = len(wb_lines) + in_between_offset_size + len(swb_lines) / 2 + fb_label_pos = ( + len(wb_lines) + + in_between_offset_size + + len(swb_lines) + + in_between_offset_size + + len(fb_lines) / 2 + ) + ticks = [ + f"['{wb_label_pos}', 'WB']", + f"['{swb_label_pos}', 'SWB']", + f"['{fb_label_pos}', 'FB']", + ] + + else: + log_lines = log_lines[-MAX_VALUES:] + + runs = [ + create_runs_string(line.strip().split(split_char), x) for line in log_lines + ] + + display_ids = DISPLAY_IDS[x] + display_line_idx = DISPLAY_LINE_IDX[x] + line_colors = LINE_COLORS[x] + display_labels = DISPLAY_LABELS.get(x, [""] * len(display_ids)) + # TODO: can be refactored now that x is passed displays = [ - create_display_string(log_lines, id, idx, color, data["references"]) - for id, idx, color in zip( - DISPLAY_IDS[x], DISPLAY_LINE_IDX[x], LINE_COLORS[x] + create_display_string( + log_lines, id, idx, color, data["references"], split_char, label, x + ) + for id, idx, color, label in zip( + display_ids, display_line_idx, line_colors, display_labels ) ] + + runs = ",\n".join(runs) + displays = ",\n".join(displays) + ticks = ",\n".join(ticks) + js_string = JS_FILE_TEMPLATE.format( var_name=data["var_name"], elem_name=data["elem_name"], description=data["description"], - runs=",\n".join(runs), - displays=",\n".join(displays), + runs=runs, + displays=displays, + ticks=ticks, ) with open(data["filename"], "w") as f: print(js_string, file=f) @@ -199,30 +281,41 @@ def main(wmops_log, rom_log, ram_log): def create_runs_string(line: list[str], which: str) -> str: keys = RUNS_KEYS[which] + vals = [line[i] for i in RUNS_LINE_IDX[which]] run = str(dict(zip(keys, vals))) return run -def create_display_string(log_lines, id, idx, color, references): +def create_display_string( + log_lines, id, idx, color, references, split_char, label, which +): data = list() for i, line in enumerate(log_lines): - value = line.split(" ")[idx] + value = line.split(split_char)[idx] if id in references: value = references[id] data.append(f"[{i}, {value}]") display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) + + if which == "wmops_per_op": + display = display.replace("show: true", "show: false") + idx_data = display.index("data:") + label_string = f"label: '{label}', " + display = display[:idx_data] + label_string + display[idx_data:] + return display if __name__ == "__main__": parser = argparse.ArgumentParser() parser.add_argument("wmops_log") + parser.add_argument("wmops_per_op_log") parser.add_argument("rom_log") parser.add_argument("ram_log") args = parser.parse_args() - main(args.wmops_log, args.rom_log, args.ram_log) + main(args.wmops_log, args.wmops_per_op_log, args.rom_log, args.ram_log) -- GitLab From 44949772a70c2826a88404a673d1e6aa7129909b Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 11:50:42 +0200 Subject: [PATCH 06/21] refactor display string creation function --- .../genWebpageData_WMOPS.py | 56 +++++++++---------- 1 file changed, 26 insertions(+), 30 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData_WMOPS.py index 1164098580..36faeab478 100644 --- a/ci/complexity_measurements/genWebpageData_WMOPS.py +++ b/ci/complexity_measurements/genWebpageData_WMOPS.py @@ -248,20 +248,7 @@ def main(wmops_log, wmops_per_op_log, rom_log, ram_log): runs = [ create_runs_string(line.strip().split(split_char), x) for line in log_lines ] - - display_ids = DISPLAY_IDS[x] - display_line_idx = DISPLAY_LINE_IDX[x] - line_colors = LINE_COLORS[x] - display_labels = DISPLAY_LABELS.get(x, [""] * len(display_ids)) - # TODO: can be refactored now that x is passed - displays = [ - create_display_string( - log_lines, id, idx, color, data["references"], split_char, label, x - ) - for id, idx, color, label in zip( - display_ids, display_line_idx, line_colors, display_labels - ) - ] + displays = create_display_strings(log_lines, data["references"], split_char, x) runs = ",\n".join(runs) displays = ",\n".join(displays) @@ -288,25 +275,34 @@ def create_runs_string(line: list[str], which: str) -> str: return run -def create_display_string( - log_lines, id, idx, color, references, split_char, label, which -): - data = list() - for i, line in enumerate(log_lines): - value = line.split(split_char)[idx] - if id in references: - value = references[id] - data.append(f"[{i}, {value}]") +def create_display_strings(log_lines, references, split_char, which): + display_ids = DISPLAY_IDS[which] + display_line_idx = DISPLAY_LINE_IDX[which] + line_colors = LINE_COLORS[which] + display_labels = DISPLAY_LABELS.get(which, [""] * len(display_ids)) + + displays = list() + for id, idx, color, label in zip( + display_ids, display_line_idx, line_colors, display_labels + ): + data = list() + for i, line in enumerate(log_lines): + value = line.split(split_char)[idx] + if id in references: + value = references[id] + data.append(f"[{i}, {value}]") + + display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) - display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) + if which == "wmops_per_op": + display = display.replace("show: true", "show: false") + idx_data = display.index("data:") + label_string = f"label: '{label}', " + display = display[:idx_data] + label_string + display[idx_data:] - if which == "wmops_per_op": - display = display.replace("show: true", "show: false") - idx_data = display.index("data:") - label_string = f"label: '{label}', " - display = display[:idx_data] + label_string + display[idx_data:] + displays.append(display) - return display + return displays if __name__ == "__main__": -- GitLab From 0b73ce8fbcc8a328c5330dcc454c2a571b8d9243 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 11:51:11 +0200 Subject: [PATCH 07/21] rename file --- .../{genWebpageData_WMOPS.py => genWebpageData.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename ci/complexity_measurements/{genWebpageData_WMOPS.py => genWebpageData.py} (100%) diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.py b/ci/complexity_measurements/genWebpageData.py similarity index 100% rename from ci/complexity_measurements/genWebpageData_WMOPS.py rename to ci/complexity_measurements/genWebpageData.py -- GitLab From 8019fa2938e81cc3b2f3573cc598f0ec721f0457 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 11:54:43 +0200 Subject: [PATCH 08/21] remove old scripts and use new one --- .../genWebpageData_Ram.csh | 504 ----------------- .../genWebpageData_Rom.csh | 535 ------------------ .../genWebpageData_WMOPS.csh | 500 ---------------- .../genWebpageData_WmopPerOperatingpoint.csh | 503 ---------------- ci/complexity_measurements/getWmops.sh | 15 +- 5 files changed, 2 insertions(+), 2055 deletions(-) delete mode 100755 ci/complexity_measurements/genWebpageData_Ram.csh delete mode 100755 ci/complexity_measurements/genWebpageData_Rom.csh delete mode 100755 ci/complexity_measurements/genWebpageData_WMOPS.csh delete mode 100755 ci/complexity_measurements/genWebpageData_WmopPerOperatingpoint.csh diff --git a/ci/complexity_measurements/genWebpageData_Ram.csh b/ci/complexity_measurements/genWebpageData_Ram.csh deleted file mode 100755 index c0e3eab411..0000000000 --- a/ci/complexity_measurements/genWebpageData_Ram.csh +++ /dev/null @@ -1,504 +0,0 @@ -#!/bin/tcsh - -# (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository. All Rights Reserved. - -# This software is protected by copyright law and by international treaties. -# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository retain full ownership rights in their respective contributions in -# the software. This notice grants no license of any kind, including but not limited to patent -# license, nor is any license granted by implication, estoppel or otherwise. - -# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making -# contributions. - -# This software is provided "AS IS", without any express or implied warranties. The software is in the -# development stage. It is intended exclusively for experts who have experience with such software and -# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability -# and fitness for a particular purpose are hereby disclaimed and excluded. - -# Any dispute, controversy or claim arising under or in relation to providing this software shall be -# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in -# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and -# the United Nations Convention on Contracts on the International Sales of Goods. - -set maxValues = 40 - -if (${#argv} != 3) then - echo usage: $0 \ \ \ - exit -endif - -set srcFile = $1 -set file_final = $2 -set file = ${file_final}_new_$$ -set graphName = $3 - - -set tmpBase = `basename $0` -set tmpFile = /tmp/${tmpBase}_$$ -rm -f ${tmpFile} -cat ${srcFile} | tail -n ${maxValues} > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -set maxNumWordsLine = 19 - -rm -f $file -touch $file - -echo "var $graphName = {" >> $file -echo ' ram_worstcase: {' >> $file -echo ' description: "Worst Case RAM",' >> $file -echo ' direction: -1,' >> $file -echo ' runs: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - @ i++ - set separator = "," - if ( $i == $nLines ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set revision = $tmp[1] - set shortDate = `echo $tmp[2] | sed -e "s/_/\ /g"` - set fullDate = `echo $tmp[3] | sed -e "s/_/\ /g"` - set maxTotalRamEnc = $tmp[5] - set maxTotalRamDec = $tmp[7] - set maxStackEnc = $tmp[10] - set maxStackDec = $tmp[12] - set maxHeapEnc = $tmp[15] - set maxHeapDec = $tmp[17] - set logFile = $tmp[19] - - echo ' {' >> $file - echo ' fullDate: "'${fullDate}'",' >> $file - echo ' shortDate: "'${shortDate}'",' >> $file - echo ' revision: "'${revision}'",' >> $file - echo ' maxTotalRamEnc: "'${maxTotalRamEnc}'",' >> $file - echo ' maxTotalRamDec: "'${maxTotalRamDec}'",' >> $file - echo ' maxStackEnc: "'${maxStackEnc}'",' >> $file - echo ' maxStackDec: "'${maxStackDec}'",' >> $file - echo ' maxHeapEnc: "'${maxHeapEnc}'",' >> $file - echo ' maxHeapDec: "'${maxHeapDec}'",' >> $file - echo ' logFile: "'${logFile}'"' >> $file - echo ' }'${separator} >> $file - -end -echo ' ],' >> $file - -# begin displays -echo ' displays: [' >> $file - -# requirement RAM -echo ' {' >> $file -echo ' lines: { show: false },' >> $file -echo ' points: { show: false, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#000000",' >> $file -echo ' id: "requirementRam",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - # TODO: add real requirement once decided on - set score = 0 - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# requirement RAM - -# maxTotalRamCodecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FF0000",' >> $file -echo ' id: "maxTotalRamCodecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[4] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTotalRamCodecScore - -# maxTotalRamEncScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FF8000",' >> $file -echo ' id: "maxTotalRamEncScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[6] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTotalRamEncScore - -# maxTotalRamDecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FFFF00",' >> $file -echo ' id: "maxTotalRamDecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[8] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTotalRamDecScore - -# maxStackCodecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#004000",' >> $file -echo ' id: "maxStackCodecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[9] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxStackCodecScore - - -# maxStackEncScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#008000",' >> $file -echo ' id: "maxStackEncScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[11] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxStackEncScore - -# maxStackDecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#00FF00",' >> $file -echo ' id: "maxStackDecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[13] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxStackDecScore - -# maxHeapCodecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#800080",' >> $file -echo ' id: "maxHeapCodecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[14] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxHeapCodecScore - -# maxHeapEncScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#0000FF",' >> $file -echo ' id: "maxHeapEncScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[16] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxHeapEncScore - -# maxHeapDecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#0080C0",' >> $file -echo ' id: "maxHeapDecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[18] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' }' >> $file -# maxHeapDecScore - -echo ' ]' >> $file -# end displays - -echo ' }' >> $file -echo '};' >> $file - -mv -f $file $file_final -rm -f $tmpFile diff --git a/ci/complexity_measurements/genWebpageData_Rom.csh b/ci/complexity_measurements/genWebpageData_Rom.csh deleted file mode 100755 index d2ed0b3f94..0000000000 --- a/ci/complexity_measurements/genWebpageData_Rom.csh +++ /dev/null @@ -1,535 +0,0 @@ -#!/bin/tcsh - -# (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository. All Rights Reserved. - -# This software is protected by copyright law and by international treaties. -# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository retain full ownership rights in their respective contributions in -# the software. This notice grants no license of any kind, including but not limited to patent -# license, nor is any license granted by implication, estoppel or otherwise. - -# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making -# contributions. - -# This software is provided "AS IS", without any express or implied warranties. The software is in the -# development stage. It is intended exclusively for experts who have experience with such software and -# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability -# and fitness for a particular purpose are hereby disclaimed and excluded. - -# Any dispute, controversy or claim arising under or in relation to providing this software shall be -# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in -# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and -# the United Nations Convention on Contracts on the International Sales of Goods. - -set maxValues = 40 - -if (${#argv} != 3) then - echo usage: $0 \ \ \ - exit -endif - -set srcFile = $1 -set file_final = $2 -set file = ${file_final}_new_$$ -set graphName = $3 - -set tmpBase = `basename $0` -set tmpFile = /tmp/${tmpBase}_$$ -rm -f ${tmpFile} -cat ${srcFile} | tail -n ${maxValues} > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -set maxNumWordsLine = 21 - -rm -f $file -touch $file - -echo "var $graphName = {" >> $file -echo ' rom_worstcase: {' >> $file -echo ' description: "ROM",' >> $file -echo ' direction: -1,' >> $file -echo ' runs: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - @ i++ - set separator = "," - if ( $i == $nLines ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - - # 1 revision, - # 2 shortDate, - # 3 fullDate, - - # 4 max_total_encdec[1], - - # 5 max_prom_enc[0], - # 6 max_prom_enc[1], - # 7 max_prom_dec[0], - # 8 max_prom_dec[1], - # 9 max_prom_com[0], - # 10 max_prom_com[1], - # 11 max_prom_rend[0], - # 12 max_prom_rend[1], - - # 13 max_trom_enc[0], - # 14 max_trom_enc[1], - # 15 max_trom_dec[0], - # 16 max_trom_dec[1], - # 17 max_trom_com[0], - # 18 max_trom_com[1], - # 19 max_trom_rend[0], - # 20 max_trom_rend[1], - - # 21 newsletterFilenameLast, - - - set revision = $tmp[1] - set shortDate = `echo $tmp[2] | sed -e "s/_/\ /g"` - set fullDate = `echo $tmp[3] | sed -e "s/_/\ /g"` - set PromEnc = $tmp[5] - set PromDec = $tmp[7] - set PromCom = $tmp[9] - set PromRend = $tmp[11] - set TromEnc = $tmp[13] - set TromDec = $tmp[15] - set TromCom = $tmp[17] - set TromRend = $tmp[19] - set logFile = $tmp[21] - - echo ' {' >> $file - echo ' fullDate: "'${fullDate}'",' >> $file - echo ' shortDate: "'${shortDate}'",' >> $file - echo ' revision: "'${revision}'",' >> $file - echo ' PromEnc: "'${PromEnc}'",' >> $file - echo ' PromDec: "'${PromDec}'",' >> $file - echo ' PromCom: "'${PromCom}'",' >> $file - echo ' PromRend: "'${PromRend}'",' >> $file - echo ' TromEnc: "'${TromEnc}'",' >> $file - echo ' TromDec: "'${TromDec}'",' >> $file - echo ' TromCom: "'${TromCom}'",' >> $file - echo ' TromRend: "'${TromRend}'",' >> $file - echo ' logFile: "'${logFile}'"' >> $file - echo ' }'${separator} >> $file - -end -echo ' ],' >> $file - -# begin displays -echo ' displays: [' >> $file - -# requirement ROM -echo ' {' >> $file -echo ' lines: { show: false },' >> $file -echo ' points: { show: false, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#000000",' >> $file -echo ' id: "requirementRom",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - # TODO: add real requirement once decided on - set score = 0 - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# requirement ROM - -# TotalRomCodecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FF0000",' >> $file -echo ' id: "TotalRomCodecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[4] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# TotalRomCodecScore - -# maxPROMEncScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FF8000",' >> $file -echo ' id: "maxPROMEncScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[6] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxPROMEncScore - -# maxPROMDecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FFFF00",' >> $file -echo ' id: "maxPROMDecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[8] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxPROMEncScore - -# maxPROMComScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#800080",' >> $file -echo ' id: "maxPROMComScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[10] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxPROMComScore - - -# maxPROMRendScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#0000FF",' >> $file -echo ' id: "maxPROMRendScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[12] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxPROMRendScore - -# maxTROMEncScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#0080C0",' >> $file -echo ' id: "maxTROMEncScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[14] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTROMEncScore - -# maxTROMDecScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#004000",' >> $file -echo ' id: "maxTROMDecScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[16] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTROMDecScore - -# maxTROMComScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#008000",' >> $file -echo ' id: "maxTROMComScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[18] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# maxTROMComScore - -# maxTROMRendScore -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#00FF00",' >> $file -echo ' id: "maxTROMRendScore",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLine ) then - continue - endif - - set score = $tmp[20] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' }' >> $file -# maxTROMRendScore - -echo ' ]' >> $file -# end displays - -echo ' }' >> $file -echo '};' >> $file - -mv -f $file $file_final -rm -f $tmpFile diff --git a/ci/complexity_measurements/genWebpageData_WMOPS.csh b/ci/complexity_measurements/genWebpageData_WMOPS.csh deleted file mode 100755 index 8e052210c8..0000000000 --- a/ci/complexity_measurements/genWebpageData_WMOPS.csh +++ /dev/null @@ -1,500 +0,0 @@ -#!/bin/tcsh - -# (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository. All Rights Reserved. - -# This software is protected by copyright law and by international treaties. -# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository retain full ownership rights in their respective contributions in -# the software. This notice grants no license of any kind, including but not limited to patent -# license, nor is any license granted by implication, estoppel or otherwise. - -# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making -# contributions. - -# This software is provided "AS IS", without any express or implied warranties. The software is in the -# development stage. It is intended exclusively for experts who have experience with such software and -# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability -# and fitness for a particular purpose are hereby disclaimed and excluded. - -# Any dispute, controversy or claim arising under or in relation to providing this software shall be -# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in -# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and -# the United Nations Convention on Contracts on the International Sales of Goods. - -set maxValues = 40 - -if (${#argv} != 3) then - echo usage: $0 \ \ \ - exit -endif - -set srcFile = $1 -set file_final = $2 -set file = ${file_final}_new_$$ -set graphName = $3 - - -set tmpBase = `basename $0` -set tmpFile = /tmp/${tmpBase}_$$ -rm -f ${tmpFile} -cat ${srcFile} | tail -n ${maxValues} > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -set maxNumWordsLineOld = 12 -set maxNumWordsLineNew = 19 - -rm -f $file -touch $file - -echo "var $graphName = {" >> $file -echo ' wmops_worstcase: {' >> $file -echo ' description: "Worst Case WMOPS",' >> $file -echo ' direction: -1,' >> $file -echo ' runs: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - @ i++ - set separator = "," - if ( $i == $nLines ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - set revision = $tmp[1] - set shortDate = `echo $tmp[2] | sed -e "s/_/\ /g"` - set fullDate = `echo $tmp[3] | sed -e "s/_/\ /g"` - set worstCaseEnc = $tmp[5] - set worstCaseDec = $tmp[7] - set worstCaseCodec = $tmp[9] - set fixpointScalingFac = $tmp[11] - if ( $numWords == $maxNumWordsLineOld ) then - set logFile = $tmp[12] - set worstCaseEncRs = "" - set worstCaseDecRs = "" - set worstCaseCodecRs = "" - else if ( $numWords < $maxNumWordsLineNew ) then - set logFile = "" - set worstCaseEncRs = "" - set worstCaseDecRs = "" - set worstCaseCodecRs = "" - else - set logFile = $tmp[19] - set worstCaseEncRs = $tmp[13] - set worstCaseDecRs = $tmp[15] - set worstCaseCodecRs = $tmp[17] - endif - - - echo ' {' >> $file - echo ' fullDate: "'${fullDate}'",' >> $file - echo ' shortDate: "'${shortDate}'",' >> $file - echo ' revision: "'${revision}'",' >> $file - echo ' worstCaseEnc: "'${worstCaseEnc}'",' >> $file - echo ' worstCaseDec: "'${worstCaseDec}'",' >> $file - echo ' worstCaseCodec: "'${worstCaseCodec}'",'>> $file - echo ' worstCaseEncRs: "'${worstCaseEncRs}'",' >> $file - echo ' worstCaseDecRs: "'${worstCaseDecRs}'",' >> $file - echo ' worstCaseCodecRs: "'${worstCaseCodecRs}'",'>> $file - echo ' fixpointScalingFac: "'${fixpointScalingFac}'",'>> $file - echo ' logFile: "'${logFile}'"' >> $file - echo ' }'${separator} >> $file - -end -echo ' ],' >> $file - -# begin displays -echo ' displays: [' >> $file - -# 135 WMOPS boundary -echo ' {' >> $file -echo ' lines: { show: false },' >> $file -echo ' points: { show: false, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: false,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#000000",' >> $file -echo ' id: "requirement",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - # TODO: add real requirement once decided on - set score = 0 - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# 135 WMOPS boundary - -# worst case codec -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#0080FF",' >> $file -echo ' id: "worst case codec",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - set score = $tmp[10] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# end worst case codec - -# worst case enc/dec -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FF8000",' >> $file -echo ' id: "worst case enc/dec",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - set score = $tmp[4] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# worst case enc/dec - -# worst case encoder -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#CF4B4B",' >> $file -echo ' id: "worst case enc",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - set score = $tmp[6] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# end worst case encoder - -# worst case decoder -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#008040",' >> $file -echo ' id: "worst case dec",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - set score = $tmp[8] - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# end worst case decoder - -########### rateswitching ############### - -# worst case codec rateswitching -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#40C4FF",' >> $file -echo ' id: "worst case codec rs",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - if ( $numWords < $maxNumWordsLineNew ) then - set score = 0 - else - set score = $tmp[18] - endif - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# end worst case codec rateswitching - -# worst case enc/dec rateswitching -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#FFC480",' >> $file -echo ' id: "worst case enc/dec rs",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - if ( $numWords < $maxNumWordsLineNew ) then - set score = 0 - else - set score = $tmp[12] - endif - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# worst case enc/dec rateswitching - -# worst case encoder rateswitching -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#CF8080",' >> $file -echo ' id: "worst case enc rs",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - if ( $numWords < $maxNumWordsLineNew ) then - set score = 0 - else - set score = $tmp[14] - endif - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' },' >> $file -# end worst case encoder rateswitching - -# worst case decoder rateswitching -echo ' {' >> $file -echo ' lines: { show: true },' >> $file -echo ' points: { show: true, fillColor: "#ffffff" },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: true,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#00F040",' >> $file -echo ' id: "worst case dec rs",' >> $file -echo ' data: [' >> $file - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - set separator = "," - if ( $i == $nLines - 1 ) then - set separator = "" - endif - - set tmp = ( $line ) - - set numWords = `echo $tmp | wc -w` - if ( $numWords < $maxNumWordsLineOld ) then - continue - endif - - if ( $numWords < $maxNumWordsLineNew ) then - set score = 0 - else - set score = $tmp[16] - endif - - echo ' ['"${i}, ${score}"']'${separator} >> $file - @ i++ - -end - -echo ' ]' >> $file -echo ' }' >> $file -# end worst case decoder rateswitching - -########### end rateswitching ############### - -echo ' ]' >> $file -# end displays - -echo ' }' >> $file -echo '};' >> $file - -mv -f $file $file_final -rm -f $tmpFile diff --git a/ci/complexity_measurements/genWebpageData_WmopPerOperatingpoint.csh b/ci/complexity_measurements/genWebpageData_WmopPerOperatingpoint.csh deleted file mode 100755 index 906d08c949..0000000000 --- a/ci/complexity_measurements/genWebpageData_WmopPerOperatingpoint.csh +++ /dev/null @@ -1,503 +0,0 @@ -#!/bin/tcsh - -# (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository. All Rights Reserved. - -# This software is protected by copyright law and by international treaties. -# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository retain full ownership rights in their respective contributions in -# the software. This notice grants no license of any kind, including but not limited to patent -# license, nor is any license granted by implication, estoppel or otherwise. - -# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making -# contributions. - -# This software is provided "AS IS", without any express or implied warranties. The software is in the -# development stage. It is intended exclusively for experts who have experience with such software and -# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability -# and fitness for a particular purpose are hereby disclaimed and excluded. - -# Any dispute, controversy or claim arising under or in relation to providing this software shall be -# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in -# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and -# the United Nations Convention on Contracts on the International Sales of Goods. - -set srcFile = $1 -set file_final = $2 -set file = ${file_final}.new -set graphName = $3 - -set tmpBase = `basename $0` -set tmpFile = /tmp/${tmpBase}_$$ - -rm -f $file -touch $file - -set worstCaseCodec -set worstCaseEnc -set worstCaseDec -@ numEntries = 0; -@ offsetTicks = 0; - -echo "var $graphName = {" >> $file -echo ' wmops_worstcase_per_op: {' >> $file -echo ' description: "Worst Case WMOPS per OP",' >> $file -echo ' direction: -1,' >> $file -echo ' runs: [' >> $file - -# -# NB modes -# -if (0) then # don't use! -rm -f ${tmpFile} -cat ${srcFile} | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_NB_" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksNB = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "NB"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - -# -# NB modes, rateswitching -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_NB_RS" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksNB_RS = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "NB RS"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - -# -# AMR-WB IO modes -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_WB_" | grep "AMR" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksWBIO = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "AMR-WB IO"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - -# -# AMR-WB IO modes rateswitching -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_WB_RS" | grep "AMR" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksWBIO_RS = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "AMR-WB IO RS"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file -endif - -# -# WB modes -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_WB_" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksWB = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "WB"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - -# -# WB modes rateswitching -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_WB_RS" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksWB_RS = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "WB RS"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - -# -# SWB modes -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_SWB_" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksSWB = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "SWB"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - - -# -# SWB modes rateswitching -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_SWB_RS" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksSWB_RS = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "SWB RS"' >> $file - echo ' },' >> $file - -end - -# -# FB modes -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_FB_" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksFB = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -foreach line ( "`cat ${tmpFile}`" ) - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "FB"' >> $file - echo ' },' >> $file - -end - -set worstCaseCodec = ( $worstCaseCodec 0 ) -set worstCaseEnc = ( $worstCaseEnc 0 ) -set worstCaseDec = ( $worstCaseDec 0 ) -@ numEntries++ - -echo ' {' >> $file -echo ' operatingPoint: "",' >> $file -echo ' mode: ""' >> $file -echo ' },' >> $file - - -# -# FB modes rateswitching -# -rm -f ${tmpFile} -cat $srcFile | grep "[0-9]" | sed -e "s/\ /_/g" | sed -e "s/;/\ /g" | grep "_FB_RS" > ${tmpFile} -set nLines = `cat ${tmpFile} | wc -l` -@ ticksFB_RS = $offsetTicks + ( $nLines / 2 ) -@ offsetTicks += ($nLines + 1) - -@ i = 0 -foreach line ( "`cat ${tmpFile}`" ) - @ i++ - set separator = "," - if ( $i == $nLines ) then - set separator = "" - endif - - set tmp = `echo $line` - - set operatingPoint = $tmp[1] - set worstCaseCodec = ( $worstCaseCodec $tmp[4] ) - set worstCaseEnc = ( $worstCaseEnc $tmp[2] ) - set worstCaseDec = ( $worstCaseDec $tmp[3] ) - @ numEntries++ - - echo ' {' >> $file - echo ' operatingPoint: "'${operatingPoint}'",' >> $file - echo ' mode: "SWB RS"' >> $file - echo ' }'${separator} >> $file - -end - -echo ' ],' >> $file - -# -# ticks -# -echo ' ticks: [' >> $file -if (0) then -echo ' ['$ticksNB', "NB"],' >> $file -echo ' ['$ticksNB_RS', "NB RS"],' >> $file -echo ' ['$ticksWBIO', "AMR-WB IO"],' >> $file -endif -echo ' ['$ticksWB', "WB"],' >> $file -echo ' ['$ticksWB_RS', "WB RS"],' >> $file -echo ' ['$ticksSWB', "SWB"],' >> $file -echo ' ['$ticksSWB_RS', "SWB RS"],' >> $file -echo ' ['$ticksFB', "FB"],' >> $file -echo ' ['$ticksFB_RS', "FB RS"]' >> $file -echo ' ],' >> $file - - -# begin displays -echo ' displays: [' >> $file - -# Start: Worse case encoder -echo ' {' >> $file -echo ' lines: { show: false },' >> $file -echo ' points: { show: false },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: false,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#CF4B4B",' >> $file -echo ' id: "worstCaseEnc",' >> $file -echo ' label: "Encoder",' >> $file -echo ' data: [' >> $file - -@ i = 0 -while($i < $numEntries) - - set separator = "," - if ( $i == $numEntries - 1 ) then - set separator = "" - endif - - @ j = $i + 1 - - echo ' ['"${i}, $worstCaseEnc[$j]"']'${separator} >> $file - - @ i++ -end - -echo ' ]' >> $file -echo ' },' >> $file -# End: Worst case encoder - -# Start: Worse case decoder -echo ' {' >> $file -echo ' lines: { show: false },' >> $file -echo ' points: { show: false },' >> $file -echo ' borderWidth: 1.5,' >> $file -echo ' borderColor: "#BEBEBE",' >> $file -echo ' markingsLineWidth: .75,' >> $file -echo ' hoverable: true,' >> $file -echo ' clickable: false,' >> $file -echo ' shadowSize: 0,' >> $file -echo ' color: "#008040",' >> $file -echo ' id: "worstCaseDec",' >> $file -echo ' label: "Decoder",' >> $file -echo ' data: [' >> $file - -@ i = 0 -while($i < $numEntries) - - set separator = "," - if ( $i == $numEntries - 1 ) then - set separator = "" - endif - - @ j = $i + 1 - - echo ' ['"${i}, $worstCaseDec[$j]"']'${separator} >> $file - - @ i++ -end - -echo ' ]' >> $file -echo ' }' >> $file -# End: Worst case encoder - -echo ' ]' >> $file -# end displays - -echo ' }' >> $file -echo '};' >> $file - -mv -f $file $file_final -rm -f $tmpFile diff --git a/ci/complexity_measurements/getWmops.sh b/ci/complexity_measurements/getWmops.sh index 3e2bcefc24..3214a21c05 100755 --- a/ci/complexity_measurements/getWmops.sh +++ b/ci/complexity_measurements/getWmops.sh @@ -82,28 +82,17 @@ ret_val=$? ### WMOPS ${scriptDir}/parseNewsletterWmops.py ${wmopsFilenameFlc}_WMOPS.csv ${wmopsFilenameFlcLast}_WMOPS.csv ${commit_sha} ${shortDate} ${fullDate} >> ${destDir}/wmops/log_wmops_all.txt -# now update the webpage -tcsh ${scriptDir}/genWebpageData_WMOPS.csh ${destDir}/wmops/log_wmops_all.txt ${destDir}/wmops/graphs_wmops_flc.js Graphs_WMOPS - -# per mode graph -tcsh ${scriptDir}/genWebpageData_WmopPerOperatingpoint.csh ${wmopsFilenameFlc}_WMOPS.csv ${destDir}/wmops/graphs_wmops_flc_perOP.js Graphs_WMOPS_perOP - - # get memory info for webpage ### RAM ${scriptDir}/mergeNewsletterRam.py ${wmopsFilenameFlc}_HEAP.csv ${wmopsFilenameFlc}_STACK.csv > ${wmopsFilenameFlc}_RAM.csv ${scriptDir}/parseNewsletterRam.py ${wmopsFilenameFlc}_HEAP.csv ${wmopsFilenameFlc}_STACK.csv ${wmopsFilenameFlcLast}_RAM.csv ${commit_sha} ${shortDate} ${fullDate} >> ${destDir}/wmops/log_ram_all.txt -# generate java script from database -tcsh ${scriptDir}/genWebpageData_Ram.csh ${destDir}/wmops/log_ram_all.txt ${destDir}/wmops/graphs_ram_flc.js Graphs_RAM - ### ROM - ${scriptDir}/mergeNewsletterRom.py ${wmopsFilenameFlc}_PROM.csv ${wmopsFilenameFlc}_TROM.csv > ${wmopsFilenameFlc}_ROM.csv ${scriptDir}/parseNewsletterRom.py ${wmopsFilenameFlc}_PROM.csv ${wmopsFilenameFlc}_TROM.csv ${wmopsFilenameFlcLast}_ROM.csv ${commit_sha} ${shortDate} ${fullDate} >> ${destDir}/wmops/log_rom_all.txt -# generate java script from database -tcsh ${scriptDir}/genWebpageData_Rom.csh ${destDir}/wmops/log_rom_all.txt ${destDir}/wmops/graphs_rom_flc.js Graphs_ROM +# generate javascript code from log files +python3 ci/complexity_measurements/genWebpageData.py ${destDir}/wmops/log_wmops_all.txt ${wmopsFilenameFlc}_WMOPS.csv ${destDir}/wmops/log_ram_all.txt ${destDir}/wmops/log_rom_all.txt python3 ${scriptDir}/check_for_changes.py ${destDir}/wmops/log_wmops_all.txt ${destDir}/wmops/log_ram_all.txt ${destDir}/wmops/log_rom_all.txt if [ "$?" != "0" ]; then -- GitLab From da9f1dd5ce2505c5bde4d1d2549f31e330838d23 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 13:36:07 +0200 Subject: [PATCH 09/21] add reference lines in WMOPS graph no actual numbers, just placeholder for now --- ci/complexity_measurements/genWebpageData.py | 25 ++++++++++++++----- .../index_complexity.html | 3 +++ 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index 36faeab478..4513a75054 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -3,6 +3,13 @@ import argparse MAX_VALUES = 40 +REF_WMOPS_EVS = 88 +REF_WMOPS_3EVS = 3 * REF_WMOPS_EVS +REF_WMOPS_6EVS = 6 * REF_WMOPS_EVS +REF_WMOPS_10EVS = 10 * REF_WMOPS_EVS + +REF_COLORS = ["#000000", "#666666", "#AAAAAA"] + RUNS_KEYS_COMMON = ["fullDate", "shortDate", "revision", "logFile"] RUNS_KEYS_WMOPS = RUNS_KEYS_COMMON + [ "worstCaseEnc", @@ -51,7 +58,9 @@ RUNS_LINE_IDX = { DISPLAY_IDS = { "wmops": [ - "requirement", + "3xEVS", + "6xEVS", + "10xEVS", "worst case codec", "worst case enc/dec", "worst case enc", @@ -103,7 +112,9 @@ DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fill LINE_COLORS = { "wmops": [ - "#000000", + REF_COLORS[0], + REF_COLORS[1], + REF_COLORS[2], "#0080FF", "#FF8000", "#CF4B4B", @@ -114,7 +125,7 @@ LINE_COLORS = { "#00F040", ], "rom": [ - "#000000", + REF_COLORS[0], "#FF0000", "#FF8000", "#FFFF00", @@ -126,7 +137,7 @@ LINE_COLORS = { "#00FF00", ], "ram": [ - "#000000", + REF_COLORS[0], "#FF0000", "#FF8000", "#FFFF00", @@ -167,7 +178,9 @@ FILE_DATA = { "description": "Worst Case WMOPS", "filename": "graphs_wmops_flc.js", "references": { - "requirement": 0, + "3xEVS": REF_WMOPS_3EVS, + "6xEVS": REF_WMOPS_6EVS, + "10xEVS": REF_WMOPS_10EVS, }, }, "rom": { @@ -306,7 +319,7 @@ def create_display_strings(log_lines, references, split_char, which): if __name__ == "__main__": - parser = argparse.ArgumentParser() + parser = argparse.ArgumentParser(description="Generate Javascript code for the complexity webpage") parser.add_argument("wmops_log") parser.add_argument("wmops_per_op_log") parser.add_argument("rom_log") diff --git a/ci/complexity_measurements/index_complexity.html b/ci/complexity_measurements/index_complexity.html index 3b3964e9d8..a420c10606 100755 --- a/ci/complexity_measurements/index_complexity.html +++ b/ci/complexity_measurements/index_complexity.html @@ -123,6 +123,9 @@
  • Worst case encoder performance (rateswitching)
  • Worst case decoder performance
  • Worst case decoder performance (rateswitching)
  • +
  • 3xEVS Reference
  • +
  • 6xEVS Reference
  • +
  • 10xEVS Reference
  • -- GitLab From 30a63145e93bfe94fb65b51c563b77ab58f51c1c Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 14:23:36 +0200 Subject: [PATCH 10/21] some changes for the reference display --- ci/complexity_measurements/genWebpageData.py | 3 ++- ci/complexity_measurements/index_complexity.html | 13 +++++++++++-- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index 4513a75054..81a98b3bc7 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -99,8 +99,9 @@ DISPLAY_IDS = { "worstCaseDec", ], } +# the -1's are for reference lines DISPLAY_LINE_IDX = { - "wmops": [-1, 9, 3, 5, 7, 17, 11, 13, 15], + "wmops": [-1, -1, -1, 9, 3, 5, 7, 17, 11, 13, 15], "rom": [-1, 3, 5, 7, 9, 11, 13, 15, 17, 19], "ram": [-1, 3, 5, 7, 8, 10, 12, 13, 15, 17], "wmops_per_op": [1, 2], diff --git a/ci/complexity_measurements/index_complexity.html b/ci/complexity_measurements/index_complexity.html index a420c10606..40ea922b5f 100755 --- a/ci/complexity_measurements/index_complexity.html +++ b/ci/complexity_measurements/index_complexity.html @@ -297,13 +297,15 @@

    FAQ

    +
    Q:
    Which input files are used for audio-input? What error pattern is used?
    +
    A:
    The input files can be found here. The error pattern is here
    . +
    Q:
    The legend lists some References, but I can't see them in the plot?
    +
    A:
    The plot Axes are scaled to fit the measured numbers. The reference values might be too high to fit into the plot. Put differently: if you can't see the references, you are probably below them (all is well).
    .
    Q:
    What is the meaning of these funny symbols in the navigation box, in the left upper corner of this page?
    A:
    1) Traffic light , or : !!!CURRENTLY NOT WORKING CORRECTLY AS NO REQUIREMENTS DEFINED YET!!! The traffic light symbols show, whether the last datapoint matches the requirement (green) or not (red). A yellow traffic light means that the requirement is matched, but the score is very close (within a 3% margin) to the requirement.
    2) Arrow , , : The arrow indicates the trend of the last datapoint, compared to the last but one. An upwards arrow means that the score got higher (i.e. worse), downwards arrow arrow means that the score got lower (i.e. better), and a rightwards arrow means that the score was kept constant (within a 1% margin).
    -
    Q:
    Which input files are used for audio-input? What error pattern is used?
    -
    A:
    The input files can be found here. The error pattern is here.
    @@ -405,6 +407,13 @@ var max = 0; for ( var i = 0; i < displays.length; i++ ) { + // do not include the references to prevent upscaling too much when the actual + // interesting numbers are only low + var id = displays[i].id; + if ( id.includes("EVS") ) + { + continue; + } var data = displays[i].data; for ( var j = 0; j < data.length; j++ ) { -- GitLab From c24fdddf3a4d86039d19cb2ba921bd2ff53095ce Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 14:43:35 +0200 Subject: [PATCH 11/21] remove duplicate lines --- ci/complexity_measurements/genWebpageData.py | 10 +--------- ci/complexity_measurements/index_complexity.html | 4 ---- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index 81a98b3bc7..870ff3bb00 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -65,10 +65,6 @@ DISPLAY_IDS = { "worst case enc/dec", "worst case enc", "worst case dec", - "worst case codec rs", - "worst case enc/dec rs", - "worst case enc rs", - "worst case dec rs", ], "rom": [ "requirementRom", @@ -101,7 +97,7 @@ DISPLAY_IDS = { } # the -1's are for reference lines DISPLAY_LINE_IDX = { - "wmops": [-1, -1, -1, 9, 3, 5, 7, 17, 11, 13, 15], + "wmops": [-1, -1, -1, 9, 3, 5, 7], "rom": [-1, 3, 5, 7, 9, 11, 13, 15, 17, 19], "ram": [-1, 3, 5, 7, 8, 10, 12, 13, 15, 17], "wmops_per_op": [1, 2], @@ -120,10 +116,6 @@ LINE_COLORS = { "#FF8000", "#CF4B4B", "#008040", - "#40C4FF", - "#FFC480", - "#CF8080", - "#00F040", ], "rom": [ REF_COLORS[0], diff --git a/ci/complexity_measurements/index_complexity.html b/ci/complexity_measurements/index_complexity.html index 40ea922b5f..fc403f8e88 100755 --- a/ci/complexity_measurements/index_complexity.html +++ b/ci/complexity_measurements/index_complexity.html @@ -116,13 +116,9 @@
    • Worst case encoder + decoder performance: Encoder and decoder mode might be different.
    • -
    • Worst case encoder + decoder performance (rateswitching): Encoder and decoder mode might be different.
    • Worst case codec performance: Encoder and decoder modes are identical.
    • -
    • Worst case codec performance (rateswitching): Encoder and decoder modes are identical.
    • Worst case encoder performance
    • -
    • Worst case encoder performance (rateswitching)
    • Worst case decoder performance
    • -
    • Worst case decoder performance (rateswitching)
    • 3xEVS Reference
    • 6xEVS Reference
    • 10xEVS Reference
    • -- GitLab From ff8968d01a55d52430c5e4f60d579ce2d3a65e22 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Fri, 13 Sep 2024 15:00:25 +0200 Subject: [PATCH 12/21] add license text to new file --- ci/complexity_measurements/genWebpageData.py | 30 ++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index 870ff3bb00..f4260edbe8 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -1,3 +1,33 @@ +#!/usr/bin/env python3 +""" + (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, + Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., + Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, + Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other + contributors to this repository. All Rights Reserved. + + This software is protected by copyright law and by international treaties. + The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, + Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., + Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, + Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other + contributors to this repository retain full ownership rights in their respective contributions in + the software. This notice grants no license of any kind, including but not limited to patent + license, nor is any license granted by implication, estoppel or otherwise. + + Contributors are required to enter into the IVAS codec Public Collaboration agreement before making + contributions. + + This software is provided "AS IS", without any express or implied warranties. The software is in the + development stage. It is intended exclusively for experts who have experience with such software and + solely for the purpose of inspection. All implied warranties of non-infringement, merchantability + and fitness for a particular purpose are hereby disclaimed and excluded. + + Any dispute, controversy or claim arising under or in relation to providing this software shall be + submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in + accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and + the United Nations Convention on Contracts on the International Sales of Goods. +""" import argparse -- GitLab From 8dbe9e7b07f25e7fdf0fac3061e1067e28335339 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 20 Nov 2024 10:47:10 +0100 Subject: [PATCH 13/21] pass files in correct order --- ci/complexity_measurements/getWmops.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/complexity_measurements/getWmops.sh b/ci/complexity_measurements/getWmops.sh index 63932f326b..1853704863 100755 --- a/ci/complexity_measurements/getWmops.sh +++ b/ci/complexity_measurements/getWmops.sh @@ -102,7 +102,7 @@ ${scriptDir}/mergeNewsletterRom.py ${wmopsFilenameFlc}_PROM.csv ${wmopsFilenameF ${scriptDir}/parseNewsletterRom.py ${wmopsFilenameFlc}_PROM.csv ${wmopsFilenameFlc}_TROM.csv ${wmopsFilenameFlcLast}_ROM.csv ${commit_sha} ${shortDate} ${fullDate} >>${destDir}/wmops/log_rom_all.txt # generate javascript code from log files -python3 ci/complexity_measurements/genWebpageData.py ${destDir}/wmops/log_wmops_all.txt ${wmopsFilenameFlc}_WMOPS.csv ${destDir}/wmops/log_ram_all.txt ${destDir}/wmops/log_rom_all.txt +python3 ci/complexity_measurements/genWebpageData.py ${destDir}/wmops/log_wmops_all.txt ${wmopsFilenameFlc}_WMOPS.csv ${destDir}/wmops/log_rom_all.txt ${destDir}/wmops/log_ram_all.txt python3 ${scriptDir}/check_for_changes.py ${destDir}/wmops/log_wmops_all.txt ${destDir}/wmops/log_ram_all.txt ${destDir}/wmops/log_rom_all.txt if [ "$?" != "0" ]; then -- GitLab From c8c84111af37cc97d75b8004a6053e6a1f8a9b20 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 20 Nov 2024 11:04:53 +0100 Subject: [PATCH 14/21] format python files --- .../check_for_changes.py | 10 ++-- ci/complexity_measurements/genWebpageData.py | 59 ++++++++++--------- .../parseNewsletterRam.py | 54 ++++++++--------- .../parseNewsletterRom.py | 54 ++++++++--------- .../parseNewsletterWmops.py | 46 +++++++-------- 5 files changed, 114 insertions(+), 109 deletions(-) diff --git a/ci/complexity_measurements/check_for_changes.py b/ci/complexity_measurements/check_for_changes.py index 50deb76e08..2048feb044 100644 --- a/ci/complexity_measurements/check_for_changes.py +++ b/ci/complexity_measurements/check_for_changes.py @@ -5,15 +5,17 @@ import sys THRESH = 0.01 COLS = [ - [3, 5, 7, 9], # wmops_all - [3,5,7,8,10,12,13,15,17], # ram_all - [3,5,7,9,11,13,15,17,19], # rom_all + [3, 5, 7, 9], # wmops_all + [3, 5, 7, 8, 10, 12, 13, 15, 17], # ram_all + [3, 5, 7, 9, 11, 13, 15, 17, 19], # rom_all ] def main(args): linewise_logfiles = [args.wmops_logfile, args.ram_logfile, args.rom_logfile] - changes_found_linewise = any([check_linewise_logfile(f, c) for f, c in zip(linewise_logfiles, COLS)]) + changes_found_linewise = any( + [check_linewise_logfile(f, c) for f, c in zip(linewise_logfiles, COLS)] + ) if changes_found_linewise: print("Global max of WMOPS, RAM or ROM changed") diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index f4260edbe8..94dffe11f3 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -1,33 +1,34 @@ #!/usr/bin/env python3 """ - (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository. All Rights Reserved. - - This software is protected by copyright law and by international treaties. - The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository retain full ownership rights in their respective contributions in - the software. This notice grants no license of any kind, including but not limited to patent - license, nor is any license granted by implication, estoppel or otherwise. - - Contributors are required to enter into the IVAS codec Public Collaboration agreement before making - contributions. - - This software is provided "AS IS", without any express or implied warranties. The software is in the - development stage. It is intended exclusively for experts who have experience with such software and - solely for the purpose of inspection. All implied warranties of non-infringement, merchantability - and fitness for a particular purpose are hereby disclaimed and excluded. - - Any dispute, controversy or claim arising under or in relation to providing this software shall be - submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in - accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and - the United Nations Convention on Contracts on the International Sales of Goods. +(C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository. All Rights Reserved. + +This software is protected by copyright law and by international treaties. +The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository retain full ownership rights in their respective contributions in +the software. This notice grants no license of any kind, including but not limited to patent +license, nor is any license granted by implication, estoppel or otherwise. + +Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +contributions. + +This software is provided "AS IS", without any express or implied warranties. The software is in the +development stage. It is intended exclusively for experts who have experience with such software and +solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +and fitness for a particular purpose are hereby disclaimed and excluded. + +Any dispute, controversy or claim arising under or in relation to providing this software shall be +submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +the United Nations Convention on Contracts on the International Sales of Goods. """ + import argparse @@ -342,7 +343,9 @@ def create_display_strings(log_lines, references, split_char, which): if __name__ == "__main__": - parser = argparse.ArgumentParser(description="Generate Javascript code for the complexity webpage") + parser = argparse.ArgumentParser( + description="Generate Javascript code for the complexity webpage" + ) parser.add_argument("wmops_log") parser.add_argument("wmops_per_op_log") parser.add_argument("rom_log") diff --git a/ci/complexity_measurements/parseNewsletterRam.py b/ci/complexity_measurements/parseNewsletterRam.py index 55eecff573..8d32c74816 100755 --- a/ci/complexity_measurements/parseNewsletterRam.py +++ b/ci/complexity_measurements/parseNewsletterRam.py @@ -1,33 +1,33 @@ #!/usr/bin/env python3 # coding: utf-8 """ - (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository. All Rights Reserved. - - This software is protected by copyright law and by international treaties. - The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository retain full ownership rights in their respective contributions in - the software. This notice grants no license of any kind, including but not limited to patent - license, nor is any license granted by implication, estoppel or otherwise. - - Contributors are required to enter into the IVAS codec Public Collaboration agreement before making - contributions. - - This software is provided "AS IS", without any express or implied warranties. The software is in the - development stage. It is intended exclusively for experts who have experience with such software and - solely for the purpose of inspection. All implied warranties of non-infringement, merchantability - and fitness for a particular purpose are hereby disclaimed and excluded. - - Any dispute, controversy or claim arising under or in relation to providing this software shall be - submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in - accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and - the United Nations Convention on Contracts on the International Sales of Goods. +(C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository. All Rights Reserved. + +This software is protected by copyright law and by international treaties. +The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository retain full ownership rights in their respective contributions in +the software. This notice grants no license of any kind, including but not limited to patent +license, nor is any license granted by implication, estoppel or otherwise. + +Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +contributions. + +This software is provided "AS IS", without any express or implied warranties. The software is in the +development stage. It is intended exclusively for experts who have experience with such software and +solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +and fitness for a particular purpose are hereby disclaimed and excluded. + +Any dispute, controversy or claim arising under or in relation to providing this software shall be +submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +the United Nations Convention on Contracts on the International Sales of Goods. """ import csv diff --git a/ci/complexity_measurements/parseNewsletterRom.py b/ci/complexity_measurements/parseNewsletterRom.py index a4a3df4ecf..0f5c5f7658 100755 --- a/ci/complexity_measurements/parseNewsletterRom.py +++ b/ci/complexity_measurements/parseNewsletterRom.py @@ -2,33 +2,33 @@ # coding: utf-8 """ - (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository. All Rights Reserved. - - This software is protected by copyright law and by international treaties. - The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository retain full ownership rights in their respective contributions in - the software. This notice grants no license of any kind, including but not limited to patent - license, nor is any license granted by implication, estoppel or otherwise. - - Contributors are required to enter into the IVAS codec Public Collaboration agreement before making - contributions. - - This software is provided "AS IS", without any express or implied warranties. The software is in the - development stage. It is intended exclusively for experts who have experience with such software and - solely for the purpose of inspection. All implied warranties of non-infringement, merchantability - and fitness for a particular purpose are hereby disclaimed and excluded. - - Any dispute, controversy or claim arising under or in relation to providing this software shall be - submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in - accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and - the United Nations Convention on Contracts on the International Sales of Goods. +(C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository. All Rights Reserved. + +This software is protected by copyright law and by international treaties. +The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository retain full ownership rights in their respective contributions in +the software. This notice grants no license of any kind, including but not limited to patent +license, nor is any license granted by implication, estoppel or otherwise. + +Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +contributions. + +This software is provided "AS IS", without any express or implied warranties. The software is in the +development stage. It is intended exclusively for experts who have experience with such software and +solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +and fitness for a particular purpose are hereby disclaimed and excluded. + +Any dispute, controversy or claim arising under or in relation to providing this software shall be +submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +the United Nations Convention on Contracts on the International Sales of Goods. """ import csv diff --git a/ci/complexity_measurements/parseNewsletterWmops.py b/ci/complexity_measurements/parseNewsletterWmops.py index a00171ead7..5f2b261db5 100755 --- a/ci/complexity_measurements/parseNewsletterWmops.py +++ b/ci/complexity_measurements/parseNewsletterWmops.py @@ -1,33 +1,33 @@ #!/usr/bin/env python3 # coding: utf-8 """ - (C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository. All Rights Reserved. +(C) 2022-2024 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository. All Rights Reserved. - This software is protected by copyright law and by international treaties. - The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, - Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., - Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, - Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other - contributors to this repository retain full ownership rights in their respective contributions in - the software. This notice grants no license of any kind, including but not limited to patent - license, nor is any license granted by implication, estoppel or otherwise. +This software is protected by copyright law and by international treaties. +The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +contributors to this repository retain full ownership rights in their respective contributions in +the software. This notice grants no license of any kind, including but not limited to patent +license, nor is any license granted by implication, estoppel or otherwise. - Contributors are required to enter into the IVAS codec Public Collaboration agreement before making - contributions. +Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +contributions. - This software is provided "AS IS", without any express or implied warranties. The software is in the - development stage. It is intended exclusively for experts who have experience with such software and - solely for the purpose of inspection. All implied warranties of non-infringement, merchantability - and fitness for a particular purpose are hereby disclaimed and excluded. +This software is provided "AS IS", without any express or implied warranties. The software is in the +development stage. It is intended exclusively for experts who have experience with such software and +solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +and fitness for a particular purpose are hereby disclaimed and excluded. - Any dispute, controversy or claim arising under or in relation to providing this software shall be - submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in - accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and - the United Nations Convention on Contracts on the International Sales of Goods. +Any dispute, controversy or claim arising under or in relation to providing this software shall be +submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +the United Nations Convention on Contracts on the International Sales of Goods. """ import csv -- GitLab From f1ab670966a55b4ea47cd9f8e3df4a87336d5b89 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 20 Nov 2024 12:04:45 +0100 Subject: [PATCH 15/21] improve hover tooltips a bit --- .../index_complexity.html | 35 ++++++++++--------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/ci/complexity_measurements/index_complexity.html b/ci/complexity_measurements/index_complexity.html index fc403f8e88..daac766ca0 100755 --- a/ci/complexity_measurements/index_complexity.html +++ b/ci/complexity_measurements/index_complexity.html @@ -477,15 +477,19 @@ previousPoint = item.datapoint; $("#tooltip").remove(); - if(item.series.id != "requirement"){ - var x = item.datapoint[0]; - var y = item.datapoint[1]; - var text = 'Score: ' + y; + var x = item.datapoint[0]; + var y = item.datapoint[1]; - if (graph.direction == -1) - text += " WMOPS"; - text += "
      "; - + var text = "" + item.series.id + "
      " + text += 'Score: ' + y; + + if (graph.direction == -1) + text += " WMOPS"; + text += "
      "; + + // add more info only if not a reference line + if ( !item.series.id.includes("EVS") ) + { if (x > 0) { var thisValue = parseFloat(y); var prevValue = parseFloat(item.series.data[x - 1, x - 1][1]); @@ -536,13 +540,10 @@ text += "
      " - text += "Revision: " + graph.runs[x].revision + "
      "; - text += "Date: " + graph.runs[x].fullDate + "
      "; + text += "Revision: " + graph.runs[x].revision + "
      "; + text += "Date: " + graph.runs[x].fullDate + "
      "; text += "Fixpoint scal. fac. to reach 138 WMOPS: " + graph.runs[x].fixpointScalingFac + "

      "; - text += "Logfile
      "; - } else { - text = "Complexity requirement: 135 WMOPS"; } showToolTip(item.pageX, item.pageY, text); @@ -659,7 +660,7 @@ function WMOPS_perOP() { var text = ""; - text += "Mode: " + Graphs_WMOPS_perOP.wmops_worstcase_per_op.runs[x].operatingPoint + "

      "; + text += "Mode: " + Graphs_WMOPS_perOP.wmops_worstcase_per_op.runs[x].operatingPoint + "
      "; text += 'Score: ' + Math.round(y * 100) / 100; if (graph.direction == -1) @@ -760,7 +761,8 @@ function RAM() { var x = item.datapoint[0]; var y = item.datapoint[1]; - var text = 'Score: ' + y; + var text = "" + item.series.id + "
      " + text += 'Score: ' + y; if (graph.direction == -1) text += " bytes"; @@ -921,7 +923,8 @@ function ROM() { { var x = item.datapoint[0]; var y = item.datapoint[1]; - var text = 'Score: ' + y; + var text = "" + item.series.id + "
      " + text += 'Score: ' + y; if (graph.direction == -1) text += " bytes"; -- GitLab From ea733d20a2d23f244b3805d62a6c549e5b281f75 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Wed, 20 Nov 2024 14:45:01 +0100 Subject: [PATCH 16/21] add support for reference bars in the WMOPS worst case per op plot --- ci/complexity_measurements/genWebpageData.py | 165 +++++++++++++++---- 1 file changed, 129 insertions(+), 36 deletions(-) diff --git a/ci/complexity_measurements/genWebpageData.py b/ci/complexity_measurements/genWebpageData.py index 94dffe11f3..457ca5ba93 100644 --- a/ci/complexity_measurements/genWebpageData.py +++ b/ci/complexity_measurements/genWebpageData.py @@ -30,6 +30,7 @@ the United Nations Convention on Contracts on the International Sales of Goods. """ import argparse +from typing import Optional MAX_VALUES = 40 @@ -138,6 +139,9 @@ DISPLAY_LABELS = { } DISPLAY_ELEM_TEMPLATE = '{{ lines: {{ show: true }}, points: {{ show: true, fillColor: "#ffffff" }}, borderWidth: 1.5, borderColor: "#BEBEBE", markingsLineWidth: .75, hoverable: true, clickable: false, shadowSize: 0, color: "{color}", id: "{id}", data: [ {data} ] }}' +REF_COLOR_FOR_COMP_BARS = dict( + zip(DISPLAY_LABELS["wmops_per_op"], [REF_COLORS[0], REF_COLORS[2]]) +) LINE_COLORS = { "wmops": [ REF_COLORS[0], @@ -235,7 +239,9 @@ FILE_DATA = { } -def main(wmops_log, wmops_per_op_log, rom_log, ram_log): +def main( + wmops_log, wmops_per_op_log, rom_log, ram_log, wmops_per_op_log_for_comparison +): FILE_DATA["wmops"]["log_file"] = wmops_log FILE_DATA["wmops_per_op"]["log_file"] = wmops_per_op_log FILE_DATA["rom"]["log_file"] = rom_log @@ -249,35 +255,9 @@ def main(wmops_log, wmops_per_op_log, rom_log, ram_log): ticks = [] if x == "wmops_per_op": split_char = ";" - # some preprocessing is needed so that the later functions work as are - # 1. need to make sure that modes are ordered by bandwidth - # 2. need to add the bandwidth indicator as a column - wb_lines, swb_lines, fb_lines = [], [], [] - for line in log_lines: - if " WB " in line: - wb_lines.append(line + ";WB") - elif " SWB " in line: - swb_lines.append(line + ";SWB") - elif " FB " in line: - fb_lines.append(line + ";FB") - log_lines = wb_lines + swb_lines + fb_lines - - # generate tick positions and x axis labels from the number of lines - in_between_offset_size = 1 - wb_label_pos = len(wb_lines) / 2 - swb_label_pos = len(wb_lines) + in_between_offset_size + len(swb_lines) / 2 - fb_label_pos = ( - len(wb_lines) - + in_between_offset_size - + len(swb_lines) - + in_between_offset_size - + len(fb_lines) / 2 + log_lines, ticks = pre_proc_log_lines( + log_lines, wmops_per_op_log_for_comparison ) - ticks = [ - f"['{wb_label_pos}', 'WB']", - f"['{swb_label_pos}', 'SWB']", - f"['{fb_label_pos}', 'FB']", - ] else: log_lines = log_lines[-MAX_VALUES:] @@ -285,7 +265,14 @@ def main(wmops_log, wmops_per_op_log, rom_log, ram_log): runs = [ create_runs_string(line.strip().split(split_char), x) for line in log_lines ] - displays = create_display_strings(log_lines, data["references"], split_char, x) + displays = create_display_strings( + log_lines, + data["references"], + split_char, + x, + has_comparison=x == "wmops_per_op" + and wmops_per_op_log_for_comparison is not None, + ) runs = ",\n".join(runs) displays = ",\n".join(displays) @@ -303,6 +290,72 @@ def main(wmops_log, wmops_per_op_log, rom_log, ram_log): print(js_string, file=f) +def pre_proc_log_lines( + log_lines: list[str], wmops_per_op_log_for_comparison: Optional[str] +): + if wmops_per_op_log_for_comparison is not None: + with open(wmops_per_op_log_for_comparison) as f: + log_lines_comp = f.readlines() + + log_lines_combined = [] + MISSING_LINE = "{};0;0;0" + for line in log_lines: + line_split = line.split(";") + conf = line_split[0] + + # add - BASOP suffix to existing line + new_line_split = line_split + new_line_split[0] = conf + " - BASOP" + new_line_basop = ";".join(new_line_split) + log_lines_combined.append(new_line_basop) + + # search for same operating point in given comparison log + ref_conf = conf + " - FLT REF" + new_line_ref = MISSING_LINE.format(ref_conf) + for line_comp in log_lines_comp: + line_comp_split = line_comp.split(";") + conf_comp = line_comp_split[0] + if conf == conf_comp: + new_line_ref = ";".join([ref_conf] + line_comp_split[1:]) + break + log_lines_combined.append(new_line_ref) + + log_lines = log_lines_combined + + # some preprocessing is needed so that the later functions work as are + # 1. need to make sure that modes are ordered by bandwidth + # 2. need to add the bandwidth indicator as a column + wb_lines, swb_lines, fb_lines = [], [], [] + for line in log_lines: + if " WB " in line: + wb_lines.append(line + ";WB") + elif " SWB " in line: + swb_lines.append(line + ";SWB") + elif " FB " in line: + fb_lines.append(line + ";FB") + log_lines = wb_lines + swb_lines + fb_lines + + # generate tick positions and x axis labels from the number of lines + in_between_offset_size = 1 + wb_label_pos = len(wb_lines) / 2 + swb_label_pos = len(wb_lines) + in_between_offset_size + len(swb_lines) / 2 + fb_label_pos = ( + len(wb_lines) + + in_between_offset_size + + len(swb_lines) + + in_between_offset_size + + len(fb_lines) / 2 + ) + + ticks = [ + f"['{wb_label_pos}', 'WB']", + f"['{swb_label_pos}', 'SWB']", + f"['{fb_label_pos}', 'FB']", + ] + + return log_lines, ticks + + def create_runs_string(line: list[str], which: str) -> str: keys = RUNS_KEYS[which] @@ -312,7 +365,9 @@ def create_runs_string(line: list[str], which: str) -> str: return run -def create_display_strings(log_lines, references, split_char, which): +def create_display_strings( + log_lines, references, split_char, which, has_comparison=False +): display_ids = DISPLAY_IDS[which] display_line_idx = DISPLAY_LINE_IDX[which] line_colors = LINE_COLORS[which] @@ -329,13 +384,44 @@ def create_display_strings(log_lines, references, split_char, which): value = references[id] data.append(f"[{i}, {value}]") - display = DISPLAY_ELEM_TEMPLATE.format(color=color, id=id, data=", ".join(data)) + if which == "wmops_per_op" and has_comparison: + # de-interleave data + data_basop = data[::2] + data_flt_ref = data[1::2] + + display_basop = DISPLAY_ELEM_TEMPLATE.format( + color=color, id=id + " - BASOP", data=", ".join(data_basop) + ) + idx_data = display_basop.index("data:") + label_string = f"label: '{label} - BASOP', " + display_basop = ( + display_basop[:idx_data] + label_string + display_basop[idx_data:] + ) + + ref_color = REF_COLOR_FOR_COMP_BARS[label] + + display_flt_ref = DISPLAY_ELEM_TEMPLATE.format( + color=ref_color, id=id + " - FLT REF", data=", ".join(data_flt_ref) + ) + idx_data = display_flt_ref.index("data:") + label_string = f"label: '{label} - FLT REF', " + display_flt_ref = ( + display_flt_ref[:idx_data] + label_string + display_flt_ref[idx_data:] + ) + + display = display_basop + ", \n" + display_flt_ref + else: + display = DISPLAY_ELEM_TEMPLATE.format( + color=color, id=id, data=", ".join(data) + ) if which == "wmops_per_op": display = display.replace("show: true", "show: false") - idx_data = display.index("data:") - label_string = f"label: '{label}', " - display = display[:idx_data] + label_string + display[idx_data:] + + if not has_comparison: + idx_data = display.index("data:") + label_string = f"label: '{label}', " + display = display[:idx_data] + label_string + display[idx_data:] displays.append(display) @@ -350,7 +436,14 @@ if __name__ == "__main__": parser.add_argument("wmops_per_op_log") parser.add_argument("rom_log") parser.add_argument("ram_log") + parser.add_argument("--wmops_per_op_log_for_comparison", default=None) args = parser.parse_args() - main(args.wmops_log, args.wmops_per_op_log, args.rom_log, args.ram_log) + main( + args.wmops_log, + args.wmops_per_op_log, + args.rom_log, + args.ram_log, + args.wmops_per_op_log_for_comparison, + ) -- GitLab From 99a0997589a067f01748c81a6c52d727b300810f Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 21 Nov 2024 14:24:21 +0100 Subject: [PATCH 17/21] always overwrite existing reference outputs --- tests/codec_be_on_mr_nonselection/test_param_file.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/codec_be_on_mr_nonselection/test_param_file.py b/tests/codec_be_on_mr_nonselection/test_param_file.py index 13a49c3f32..f970fb55f9 100644 --- a/tests/codec_be_on_mr_nonselection/test_param_file.py +++ b/tests/codec_be_on_mr_nonselection/test_param_file.py @@ -552,7 +552,7 @@ def encode( ref_stats_file = None dut_stats_file = None - if update_ref in [1, 2] and not os.path.exists(ref_out_file): + if update_ref in [1, 2]: check_and_makedir(ref_out_dir) # call REF encoder @@ -714,7 +714,7 @@ def decode( dut_out_file = f"{dut_out_dir}/{output_file}" ref_out_file = f"{ref_out_dir}/{output_file}" - if update_ref == 1 or update_ref == 2 and not os.path.exists(ref_out_file): + if update_ref == 1 or update_ref == 2: check_and_makedir(ref_out_dir) add_option_list = dec_opts_list if tracefile_dec != "": -- GitLab From 9574dfdbf67854dcb8a1d3876594aa81884e04ef Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 21 Nov 2024 15:58:06 +0100 Subject: [PATCH 18/21] unify syntax in conditions --- tests/codec_be_on_mr_nonselection/test_param_file.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/codec_be_on_mr_nonselection/test_param_file.py b/tests/codec_be_on_mr_nonselection/test_param_file.py index f970fb55f9..8e51b7128c 100644 --- a/tests/codec_be_on_mr_nonselection/test_param_file.py +++ b/tests/codec_be_on_mr_nonselection/test_param_file.py @@ -714,7 +714,7 @@ def decode( dut_out_file = f"{dut_out_dir}/{output_file}" ref_out_file = f"{ref_out_dir}/{output_file}" - if update_ref == 1 or update_ref == 2: + if update_ref in [1, 2]: check_and_makedir(ref_out_dir) add_option_list = dec_opts_list if tracefile_dec != "": -- GitLab From 859ba8170cc17b9127221c3c2065f219e432e322 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 21 Nov 2024 16:04:59 +0100 Subject: [PATCH 19/21] Revert "unify syntax in conditions" This reverts commit 9574dfdbf67854dcb8a1d3876594aa81884e04ef. --- tests/codec_be_on_mr_nonselection/test_param_file.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/codec_be_on_mr_nonselection/test_param_file.py b/tests/codec_be_on_mr_nonselection/test_param_file.py index 8e51b7128c..f970fb55f9 100644 --- a/tests/codec_be_on_mr_nonselection/test_param_file.py +++ b/tests/codec_be_on_mr_nonselection/test_param_file.py @@ -714,7 +714,7 @@ def decode( dut_out_file = f"{dut_out_dir}/{output_file}" ref_out_file = f"{ref_out_dir}/{output_file}" - if update_ref in [1, 2]: + if update_ref == 1 or update_ref == 2: check_and_makedir(ref_out_dir) add_option_list = dec_opts_list if tracefile_dec != "": -- GitLab From 1ee9bab05e7d12c1110255fada253a4dd2c22684 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 21 Nov 2024 16:05:09 +0100 Subject: [PATCH 20/21] Revert "always overwrite existing reference outputs" This reverts commit 99a0997589a067f01748c81a6c52d727b300810f. --- tests/codec_be_on_mr_nonselection/test_param_file.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/codec_be_on_mr_nonselection/test_param_file.py b/tests/codec_be_on_mr_nonselection/test_param_file.py index f970fb55f9..13a49c3f32 100644 --- a/tests/codec_be_on_mr_nonselection/test_param_file.py +++ b/tests/codec_be_on_mr_nonselection/test_param_file.py @@ -552,7 +552,7 @@ def encode( ref_stats_file = None dut_stats_file = None - if update_ref in [1, 2]: + if update_ref in [1, 2] and not os.path.exists(ref_out_file): check_and_makedir(ref_out_dir) # call REF encoder @@ -714,7 +714,7 @@ def decode( dut_out_file = f"{dut_out_dir}/{output_file}" ref_out_file = f"{ref_out_dir}/{output_file}" - if update_ref == 1 or update_ref == 2: + if update_ref == 1 or update_ref == 2 and not os.path.exists(ref_out_file): check_and_makedir(ref_out_dir) add_option_list = dec_opts_list if tracefile_dec != "": -- GitLab From b581c0d93b5e24f1fb0e16e5040f2e7b24d68049 Mon Sep 17 00:00:00 2001 From: Jan Kiene Date: Thu, 21 Nov 2024 16:06:18 +0100 Subject: [PATCH 21/21] add correct fix that does not break update_ref = 2 --- tests/codec_be_on_mr_nonselection/test_param_file.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/codec_be_on_mr_nonselection/test_param_file.py b/tests/codec_be_on_mr_nonselection/test_param_file.py index 13a49c3f32..998e5e0a08 100644 --- a/tests/codec_be_on_mr_nonselection/test_param_file.py +++ b/tests/codec_be_on_mr_nonselection/test_param_file.py @@ -552,7 +552,7 @@ def encode( ref_stats_file = None dut_stats_file = None - if update_ref in [1, 2] and not os.path.exists(ref_out_file): + if update_ref == 1 or (update_ref == 2 and not os.path.exists(ref_out_file)): check_and_makedir(ref_out_dir) # call REF encoder @@ -714,7 +714,7 @@ def decode( dut_out_file = f"{dut_out_dir}/{output_file}" ref_out_file = f"{ref_out_dir}/{output_file}" - if update_ref == 1 or update_ref == 2 and not os.path.exists(ref_out_file): + if update_ref == 1 or (update_ref == 2 and not os.path.exists(ref_out_file)): check_and_makedir(ref_out_dir) add_option_list = dec_opts_list if tracefile_dec != "": -- GitLab