Skip to content

Commit 1607ed7

Browse files
Bastien ValletArno500
Bastien Vallet
authored andcommittedJan 8, 2025
[ruff] Enable extra plugins
1 parent 2c941d5 commit 1607ed7

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+242
-226
lines changed
 

‎csv/convert.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,8 @@ def create_csv_power(out_file: pathlib.Path, data):
5858
job_name = result.get("job_name", "")
5959
job_number = result.get("job_number", "")
6060
monitoring = result.get("monitoring", {})
61-
for category in monitoring.keys():
62-
for typ in monitoring[category].keys():
61+
for category in monitoring:
62+
for typ in monitoring[category]:
6363
measures = monitoring[category][typ]
6464
events = measures.get("events", [])
6565
unit = measures.get("unit")
@@ -108,7 +108,7 @@ def print_memrates(out, results):
108108
job_name = result.get("job_name", "")
109109
job_number = result.get("job_number", "")
110110
workers = result.get("workers")
111-
for key in result.keys():
111+
for key in result:
112112
if isinstance(result[key], dict) and "sum_speed" in result[key]:
113113
result_list.append(
114114
{

‎graph/chassis.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def get_marker(category: PowerCategories) -> str:
107107
"Time [seconds]",
108108
y_label,
109109
outdir,
110-
f"time_watt_{base_outfile}_by_{str(graph_type)}",
110+
f"time_watt_{base_outfile}_by_{graph_type!s}",
111111
)
112112

113113
if graph_type == PowerCategories.SERVERINCHASSIS:
@@ -126,7 +126,7 @@ def get_marker(category: PowerCategories) -> str:
126126
y_serie = np.array(sum_serie_to_plot[str(component)])[order]
127127
curve_label = str(component)
128128
if component in [PowerCategories.SERVER, PowerCategories.SERVERINCHASSIS]:
129-
curve_label = f"sum of {str(component)}"
129+
curve_label = f"sum of {component!s}"
130130
graph.get_ax().plot(x_serie, y_serie, "", label=curve_label, marker=get_marker(component))
131131

132132
for trace in args.traces:

0 commit comments

Comments
 (0)
Please sign in to comment.