Skip to content

Commit fc22294

Browse files
committed
format
1 parent 60bbd86 commit fc22294

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lightllm/utils/bench_utils.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ def do_bench(
3434
return_mode: Literal["min", "max", "mean", "median"] = "mean",
3535
) -> Union[float, List[float]]:
3636
"""Benchmarks the runtime of a PyTorch function.
37-
37+
3838
This function handles:
3939
- L2 cache flushing between runs for consistent timing
4040
- Automatic warmup and repeat count calculation
4141
- Optional gradient clearing for backward passes
4242
- Multiple measurement modes (mean, median, min, max)
43-
43+
4444
Args:
4545
fn: Function to benchmark
4646
warmup: Target warmup time in milliseconds
@@ -51,7 +51,7 @@ def do_bench(
5151
quantiles: Optional performance percentiles to compute
5252
fast_flush: Whether to use faster L2 cache flushing
5353
return_mode: How to aggregate timing results ("mean", "median", "min", "max")
54-
54+
5555
Returns:
5656
float: Aggregated runtime in milliseconds
5757
"""

0 commit comments

Comments
 (0)