Skip to content

Commit 51a52c2

Browse files
committed
format
1 parent 6923eec commit 51a52c2

File tree

1 file changed

+4
-10
lines changed

1 file changed

+4
-10
lines changed

python/triton/runtime/autotuner.py

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -225,12 +225,9 @@ def check_disk_cache(self, tuning_key, configs, bench_fn, state: AutotunerThread
225225
json.dumps({
226226
"key":
227227
tuning_key,
228-
"configs_timings":
229-
[
230-
(config.__dict__, timings)
231-
for config, timings in (state.configs_timings or {}).items()
232-
if not config.pre_hook
233-
],
228+
"configs_timings": [(config.__dict__, timings)
229+
for config, timings in (state.configs_timings or {}).items()
230+
if not config.pre_hook],
234231
}), file_name, binary=False)
235232
return False
236233

@@ -254,10 +251,7 @@ def run(self, *args, **kwargs):
254251

255252
def benchmark():
256253
bench_start = time.time()
257-
timings = {
258-
config: self._bench(nargs, *args, config=config, **kwargs)
259-
for config in pruned_configs
260-
}
254+
timings = {config: self._bench(nargs, *args, config=config, **kwargs) for config in pruned_configs}
261255
bench_end = time.time()
262256
state.bench_time = bench_end - bench_start
263257
best_config = builtins.min(timings, key=timings.get)

0 commit comments

Comments
 (0)