fix pre commit

Signed-off-by: princepride <wangzhipeng628@gmail.com>
This commit is contained in:
princepride committed 2026-05-29 02:59:58 +00:00
1 parent 6a7e31b549
commit 0e45a22094
3 files changed
+11 -11

No files matched your search

+2 -2
View File
@@ -51,11 +51,11 @@ def _benchmark(fn, warmup: int = 20, iters: int = 200) -> float:
"""Return mean latency in milliseconds."""
for _ in range(warmup):
fn()
torch.cuda.synchronize()
torch.accelerator.synchronize()
t0 = time.perf_counter()
for _ in range(iters):
fn()
torch.cuda.synchronize()
torch.accelerator.synchronize()
return (time.perf_counter() - t0) / iters * 1000.0