Skip to content

Commit 48aaeb5

Browse files
Kaiming Chengkaiming-cheng
authored andcommitted
fix ruff issue
1 parent 9e27818 commit 48aaeb5

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

kernel_perf_agent/kernel_opt/diagnose_prompt/judger_prompts.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@
3737
from .metric_schema import GPU_MEMORY_FIELDS, GPU_SPEC_FIELDS, NCU_METRIC_SECTIONS
3838

3939

40-
4140
# =============================================================================
4241
# Section Renderers
4342
# =============================================================================
@@ -312,12 +311,20 @@ def validate_judge_response(analysis: Dict[str, Any]) -> bool:
312311
) and _validate_bottleneck_entry(analysis["bottleneck_2"])
313312

314313

315-
VALID_CATEGORIES = frozenset(["memory-bound", "compute-bound", "occupancy-limited", "latency-bound"])
314+
VALID_CATEGORIES = frozenset(
315+
["memory-bound", "compute-bound", "occupancy-limited", "latency-bound"]
316+
)
316317

317318

318319
def _validate_bottleneck_entry(bottleneck: Dict[str, Any]) -> bool:
319320
"""Validate a single bottleneck entry."""
320-
required = ["category", "root_cause", "suggestion", "priority_metrics", "expected_improvement"]
321+
required = [
322+
"category",
323+
"root_cause",
324+
"suggestion",
325+
"priority_metrics",
326+
"expected_improvement",
327+
]
321328
if not all(f in bottleneck for f in required):
322329
return False
323330
if bottleneck["category"] not in VALID_CATEGORIES:

0 commit comments

Comments
 (0)