diff --git a/3dmark/ul3dmark.py b/3dmark/ul3dmark.py index 1062322..21f8c85 100644 --- a/3dmark/ul3dmark.py +++ b/3dmark/ul3dmark.py @@ -128,8 +128,6 @@ try: logging.info("Benchmark took %.2f seconds", elapsed_test_time) logging.info("Score was %s", score) - - report = { "test": BENCHMARK_CONFIG[args.benchmark]["test_name"], "unit": "score", diff --git a/cinebench_2024/cinebench.py b/cinebench_2024/cinebench.py index 911eb17..951cf84 100644 --- a/cinebench_2024/cinebench.py +++ b/cinebench_2024/cinebench.py @@ -6,7 +6,7 @@ import subprocess import sys import time import psutil -from cinebench_utils import friendlyTestName, get_score +from cinebench_utils import friendly_test_name, get_score PARENT_DIR = str(Path(sys.path[0], "..")) sys.path.append(PARENT_DIR) @@ -90,7 +90,7 @@ try: logging.info("Benchmark took %.2f seconds", elapsed_test_time) report = { - "test": friendlyTestName(test_type), + "test": friendly_test_name(test_type), "score": score, "unit": "score", "start_time": seconds_to_milliseconds(start_time), diff --git a/cinebench_2024/cinebench_utils.py b/cinebench_2024/cinebench_utils.py index 40455f0..abfc857 100644 --- a/cinebench_2024/cinebench_utils.py +++ b/cinebench_2024/cinebench_utils.py @@ -13,11 +13,13 @@ def get_score(output: str) -> str | None: return None -def friendlyTestName(test: str) -> str: +def friendly_test_name(test: str) -> str: + """Return a friendlier string given a test argument""" if test == "g_CinebenchCpu1Test=true": return "Cinebench 2024 Single Core" if test == "g_CinebenchCpuXTest=true": return "Cinebench 2024 Multicore" - if test == "g_CinebenchGpuTest=true": + if test == "g_CinebenchGpuTest=true": return "Cinebench 2024 GPU" + return test \ No newline at end of file diff --git a/gravitymark/gravitymark.py b/gravitymark/gravitymark.py index 2b94e02..6eee1ec 100644 --- a/gravitymark/gravitymark.py +++ b/gravitymark/gravitymark.py @@ -4,7 +4,7 @@ import getpass import subprocess import sys from pathlib import Path -from gravitymark_utils import friendlyTestName, get_args, get_score, create_gravitymark_command +from gravitymark_utils import friendly_test_name, get_args, get_score, create_gravitymark_command PARENT_DIR = str(Path(sys.path[0], "..")) sys.path.append(PARENT_DIR) @@ -57,7 +57,7 @@ try: sys.exit(1) report = { - "test": friendlyTestName(args.api), + "test": friendly_test_name(args.api), "score": score, "unit": "score" } diff --git a/gravitymark/gravitymark_utils.py b/gravitymark/gravitymark_utils.py index aa663ea..3a0d0b8 100644 --- a/gravitymark/gravitymark_utils.py +++ b/gravitymark/gravitymark_utils.py @@ -23,7 +23,8 @@ CLI_OPTIONS = { "-status": "1" } -def friendlyTestName(api: str) -> str: +def friendly_test_name(api: str) -> str: + """return a friendlier string given the API harness argument""" if api == "vulkan": return "GravityMark Vulkan" if api == "opengl": @@ -32,6 +33,7 @@ def friendlyTestName(api: str) -> str: return "GravityMark DX12" if api == "direct3d11": return "GravityMark DX11" + return api def get_args() -> Namespace: """Get command line arguments for test script"""