Skip to content

Commit cec8f05

Browse files
committed
formatting
1 parent 75dd229 commit cec8f05

File tree

11 files changed

+96
-96
lines changed

11 files changed

+96
-96
lines changed

devops/scripts/benchmarks/benches/base.py

Lines changed: 20 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -12,27 +12,28 @@
1212
from utils.utils import download, run
1313

1414
benchmark_tags = [
15-
BenchmarkTag('SYCL', 'Benchmark uses SYCL runtime'),
16-
BenchmarkTag('UR', 'Benchmark uses Unified Runtime API'),
17-
BenchmarkTag('L0', 'Benchmark uses Level Zero API directly'),
18-
BenchmarkTag('UMF', 'Benchmark uses Unified Memory Framework directly'),
19-
BenchmarkTag('micro', 'Microbenchmark focusing on a specific functionality'),
20-
BenchmarkTag('application', 'Real application-based performance test'),
21-
BenchmarkTag('proxy', 'Benchmark that simulates real application use-cases'),
22-
BenchmarkTag('submit', 'Tests kernel submission performance'),
23-
BenchmarkTag('math', 'Tests math computation performance'),
24-
BenchmarkTag('memory', 'Tests memory transfer or bandwidth performance'),
25-
BenchmarkTag('allocation', 'Tests memory allocation performance'),
26-
BenchmarkTag('graph', 'Tests graph-based execution performance'),
27-
BenchmarkTag('latency', 'Measures operation latency'),
28-
BenchmarkTag('throughput', 'Measures operation throughput'),
29-
BenchmarkTag('inference', 'Tests ML/AI inference performance'),
30-
BenchmarkTag('image', 'Image processing benchmark'),
31-
BenchmarkTag('simulation', 'Physics or scientific simulation benchmark'),
15+
BenchmarkTag("SYCL", "Benchmark uses SYCL runtime"),
16+
BenchmarkTag("UR", "Benchmark uses Unified Runtime API"),
17+
BenchmarkTag("L0", "Benchmark uses Level Zero API directly"),
18+
BenchmarkTag("UMF", "Benchmark uses Unified Memory Framework directly"),
19+
BenchmarkTag("micro", "Microbenchmark focusing on a specific functionality"),
20+
BenchmarkTag("application", "Real application-based performance test"),
21+
BenchmarkTag("proxy", "Benchmark that simulates real application use-cases"),
22+
BenchmarkTag("submit", "Tests kernel submission performance"),
23+
BenchmarkTag("math", "Tests math computation performance"),
24+
BenchmarkTag("memory", "Tests memory transfer or bandwidth performance"),
25+
BenchmarkTag("allocation", "Tests memory allocation performance"),
26+
BenchmarkTag("graph", "Tests graph-based execution performance"),
27+
BenchmarkTag("latency", "Measures operation latency"),
28+
BenchmarkTag("throughput", "Measures operation throughput"),
29+
BenchmarkTag("inference", "Tests ML/AI inference performance"),
30+
BenchmarkTag("image", "Image processing benchmark"),
31+
BenchmarkTag("simulation", "Physics or scientific simulation benchmark"),
3232
]
3333

3434
benchmark_tags_dict = {tag.name: tag for tag in benchmark_tags}
3535

36+
3637
class Benchmark:
3738
def __init__(self, directory, suite):
3839
self.directory = directory
@@ -134,9 +135,10 @@ def get_metadata(self) -> BenchmarkMetadata:
134135
description=self.description(),
135136
notes=self.notes(),
136137
unstable=self.unstable(),
137-
tags=self.get_tags()
138+
tags=self.get_tags(),
138139
)
139140

141+
140142
class Suite:
141143
def benchmarks(self) -> list[Benchmark]:
142144
raise NotImplementedError()

devops/scripts/benchmarks/benches/compute.py

Lines changed: 28 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ def runtime_to_name(runtime: RUNTIMES) -> str:
2626
RUNTIMES.UR: "Unified Runtime",
2727
}[runtime]
2828

29+
2930
def runtime_to_tag_name(runtime: RUNTIMES) -> str:
3031
return {
3132
RUNTIMES.SYCL: "SYCL",
@@ -84,16 +85,15 @@ def additionalMetadata(self) -> dict[str, BenchmarkMetadata]:
8485
"The first layer is the Level Zero API, the second is the Unified Runtime API, and the third is the SYCL API.\n"
8586
"The UR v2 adapter noticeably reduces UR layer overhead, also improving SYCL performance.\n"
8687
"Work is ongoing to reduce the overhead of the SYCL API\n",
87-
tags=['submit', 'micro', 'SYCL', 'UR', 'L0']
88+
tags=["submit", "micro", "SYCL", "UR", "L0"],
8889
),
8990
"SinKernelGraph": BenchmarkMetadata(
9091
type="group",
9192
unstable="This benchmark combines both eager and graph execution, and may not be representative of real use cases.",
92-
tags=['submit', 'memory', 'proxy', 'SYCL', 'UR', 'L0', 'graph']
93+
tags=["submit", "memory", "proxy", "SYCL", "UR", "L0", "graph"],
9394
),
9495
"SubmitGraph": BenchmarkMetadata(
95-
type="group",
96-
tags=['submit', 'micro', 'SYCL', 'UR', 'L0', 'graph']
96+
type="group", tags=["submit", "micro", "SYCL", "UR", "L0", "graph"]
9797
),
9898
}
9999

@@ -279,7 +279,7 @@ def __init__(self, bench, runtime: RUNTIMES, ioq, measure_completion=0):
279279
)
280280

281281
def get_tags(self):
282-
return ['submit', 'latency', runtime_to_tag_name(self.runtime), 'micro']
282+
return ["submit", "latency", runtime_to_tag_name(self.runtime), "micro"]
283283

284284
def name(self):
285285
order = "in order" if self.ioq else "out of order"
@@ -344,7 +344,7 @@ def description(self) -> str:
344344
)
345345

346346
def get_tags(self):
347-
return ['memory', 'submit', 'latency', 'SYCL', 'micro']
347+
return ["memory", "submit", "latency", "SYCL", "micro"]
348348

349349
def bin_args(self) -> list[str]:
350350
return [
@@ -377,7 +377,7 @@ def description(self) -> str:
377377
)
378378

379379
def get_tags(self):
380-
return ['memory', 'latency', 'SYCL', 'micro']
380+
return ["memory", "latency", "SYCL", "micro"]
381381

382382
def bin_args(self) -> list[str]:
383383
return [
@@ -407,7 +407,7 @@ def description(self) -> str:
407407
)
408408

409409
def get_tags(self):
410-
return ['memory', 'latency', 'SYCL', 'micro']
410+
return ["memory", "latency", "SYCL", "micro"]
411411

412412
def bin_args(self) -> list[str]:
413413
return [
@@ -439,7 +439,7 @@ def lower_is_better(self):
439439
return False
440440

441441
def get_tags(self):
442-
return ['memory', 'throughput', 'SYCL', 'micro']
442+
return ["memory", "throughput", "SYCL", "micro"]
443443

444444
def bin_args(self) -> list[str]:
445445
return [
@@ -468,7 +468,7 @@ def description(self) -> str:
468468
)
469469

470470
def get_tags(self):
471-
return ['math', 'throughput', 'SYCL', 'micro']
471+
return ["math", "throughput", "SYCL", "micro"]
472472

473473
def bin_args(self) -> list[str]:
474474
return [
@@ -517,7 +517,7 @@ def description(self) -> str:
517517
)
518518

519519
def get_tags(self):
520-
return ['memory', 'latency', 'UR', 'micro']
520+
return ["memory", "latency", "UR", "micro"]
521521

522522
def bin_args(self) -> list[str]:
523523
return [
@@ -560,7 +560,14 @@ def unstable(self) -> str:
560560
return "This benchmark combines both eager and graph execution, and may not be representative of real use cases."
561561

562562
def get_tags(self):
563-
return ['graph', runtime_to_tag_name(self.runtime), 'proxy', 'submit', 'memory', 'latency']
563+
return [
564+
"graph",
565+
runtime_to_tag_name(self.runtime),
566+
"proxy",
567+
"submit",
568+
"memory",
569+
"latency",
570+
]
564571

565572
def bin_args(self) -> list[str]:
566573
return [
@@ -595,7 +602,13 @@ def name(self):
595602
return f"graph_api_benchmark_{self.runtime.value} SubmitGraph numKernels:{self.numKernels} ioq {self.inOrderQueue} measureCompletion {self.measureCompletionTime}"
596603

597604
def get_tags(self):
598-
return ['graph', runtime_to_tag_name(self.runtime), 'micro', 'submit', 'latency']
605+
return [
606+
"graph",
607+
runtime_to_tag_name(self.runtime),
608+
"micro",
609+
"submit",
610+
"latency",
611+
]
599612

600613
def bin_args(self) -> list[str]:
601614
return [
@@ -625,7 +638,7 @@ def name(self):
625638
return f"ulls_benchmark_{self.runtime.value} EmptyKernel wgc:{self.wgc}, wgs:{self.wgs}"
626639

627640
def get_tags(self):
628-
return [runtime_to_tag_name(self.runtime), 'micro', 'latency', 'submit']
641+
return [runtime_to_tag_name(self.runtime), "micro", "latency", "submit"]
629642

630643
def bin_args(self) -> list[str]:
631644
return [
@@ -666,7 +679,7 @@ def name(self):
666679
return f"ulls_benchmark_{self.runtime.value} KernelSwitch count {self.count} kernelTime {self.kernelTime}"
667680

668681
def get_tags(self):
669-
return [runtime_to_tag_name(self.runtime), 'micro', 'latency', 'submit']
682+
return [runtime_to_tag_name(self.runtime), "micro", "latency", "submit"]
670683

671684
def bin_args(self) -> list[str]:
672685
return [

devops/scripts/benchmarks/benches/llamacpp.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ def description(self) -> str:
102102
)
103103

104104
def get_tags(self):
105-
return ['SYCL', 'application', 'inference', 'throughput']
105+
return ["SYCL", "application", "inference", "throughput"]
106106

107107
def lower_is_better(self):
108108
return False

devops/scripts/benchmarks/benches/syclbench.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -113,15 +113,15 @@ def extra_env_vars(self) -> dict:
113113
return {}
114114

115115
def get_tags(self):
116-
base_tags = ['SYCL', 'micro']
116+
base_tags = ["SYCL", "micro"]
117117
if "Memory" in self.bench_name or "mem" in self.bench_name.lower():
118-
base_tags.append('memory')
118+
base_tags.append("memory")
119119
if "Reduction" in self.bench_name:
120-
base_tags.append('math')
120+
base_tags.append("math")
121121
if "Bandwidth" in self.bench_name:
122-
base_tags.append('throughput')
122+
base_tags.append("throughput")
123123
if "Latency" in self.bench_name:
124-
base_tags.append('latency')
124+
base_tags.append("latency")
125125
return base_tags
126126

127127
def setup(self):

devops/scripts/benchmarks/benches/umf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def setup(self):
7575
self.benchmark_bin = os.path.join(options.umf, "benchmark", self.bench_name)
7676

7777
def get_tags(self):
78-
return ['UMF', 'allocation', 'latency', 'micro']
78+
return ["UMF", "allocation", "latency", "micro"]
7979

8080
def run(self, env_vars) -> list[Result]:
8181
command = [

devops/scripts/benchmarks/benches/velocity.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ def description(self) -> str:
119119
return ""
120120

121121
def get_tags(self):
122-
return ['SYCL', 'application']
122+
return ["SYCL", "application"]
123123

124124
def run(self, env_vars) -> list[Result]:
125125
env_vars.update(self.extra_env_vars())
@@ -176,7 +176,7 @@ def parse_output(self, stdout: str) -> float:
176176
)
177177

178178
def get_tags(self):
179-
return ['SYCL', 'application', 'throughput']
179+
return ["SYCL", "application", "throughput"]
180180

181181

182182
class Bitcracker(VelocityBase):
@@ -217,7 +217,7 @@ def parse_output(self, stdout: str) -> float:
217217
)
218218

219219
def get_tags(self):
220-
return ['SYCL', 'application', 'throughput']
220+
return ["SYCL", "application", "throughput"]
221221

222222

223223
class SobelFilter(VelocityBase):
@@ -266,7 +266,7 @@ def parse_output(self, stdout: str) -> float:
266266
)
267267

268268
def get_tags(self):
269-
return ['SYCL', 'application', 'image', 'throughput']
269+
return ["SYCL", "application", "image", "throughput"]
270270

271271

272272
class QuickSilver(VelocityBase):
@@ -316,7 +316,7 @@ def parse_output(self, stdout: str) -> float:
316316
)
317317

318318
def get_tags(self):
319-
return ['SYCL', 'application', 'simulation', 'throughput']
319+
return ["SYCL", "application", "simulation", "throughput"]
320320

321321

322322
class Easywave(VelocityBase):
@@ -383,7 +383,7 @@ def parse_output(self, stdout: str) -> float:
383383
)
384384

385385
def get_tags(self):
386-
return ['SYCL', 'application', 'simulation']
386+
return ["SYCL", "application", "simulation"]
387387

388388

389389
class CudaSift(VelocityBase):
@@ -414,7 +414,7 @@ def parse_output(self, stdout: str) -> float:
414414
raise ValueError("Failed to parse benchmark output.")
415415

416416
def get_tags(self):
417-
return ['SYCL', 'application', 'image']
417+
return ["SYCL", "application", "image"]
418418

419419

420420
class DLCifar(VelocityBase):
@@ -468,7 +468,7 @@ def parse_output(self, stdout: str) -> float:
468468
raise ValueError("Failed to parse benchmark output.")
469469

470470
def get_tags(self):
471-
return ['SYCL', 'application', 'inference', 'image']
471+
return ["SYCL", "application", "inference", "image"]
472472

473473

474474
class DLMnist(VelocityBase):
@@ -556,7 +556,7 @@ def parse_output(self, stdout: str) -> float:
556556
raise ValueError("Failed to parse benchmark output.")
557557

558558
def get_tags(self):
559-
return ['SYCL', 'application', 'inference', 'image']
559+
return ["SYCL", "application", "inference", "image"]
560560

561561

562562
class SVM(VelocityBase):
@@ -602,4 +602,4 @@ def parse_output(self, stdout: str) -> float:
602602
raise ValueError("Failed to parse benchmark output.")
603603

604604
def get_tags(self):
605-
return ['SYCL', 'application', 'inference']
605+
return ["SYCL", "application", "inference"]

devops/scripts/benchmarks/html/index.html

Lines changed: 8 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,6 @@ <h1>Benchmark Results</h1>
3636
<details class="options-container">
3737
<summary>Options</summary>
3838
<div class="options-content">
39-
<div class="filter-section">
40-
<h3>Suites</h3>
41-
<div id="suite-filters">
42-
<!-- Suite checkboxes will be generated by JavaScript -->
43-
</div>
44-
</div>
45-
4639
<div class="filter-section">
4740
<h3>Display Options</h3>
4841
<div class="display-options">
@@ -56,12 +49,16 @@ <h3>Display Options</h3>
5649
</label>
5750
</div>
5851
</div>
59-
52+
6053
<div class="filter-section">
61-
<h3>Tags</h3>
62-
<div class="tag-filter-actions">
63-
<button onclick="toggleAllTags(false)">Clear All</button>
54+
<h3>Suites</h3>
55+
<div id="suite-filters">
56+
<!-- Suite checkboxes will be generated by JavaScript -->
6457
</div>
58+
</div>
59+
60+
<div class="filter-section">
61+
<h3>Tags <button class="tag-action-button" onclick="toggleAllTags(false)">Clear All</button></h3>
6562
<div id="tag-filters">
6663
<!-- Tag checkboxes will be generated by JavaScript -->
6764
</div>

0 commit comments

Comments
 (0)