Skip to content

Commit 3419a92

Browse files
committed
change seed for repeated benchmarking
1 parent eb4902f commit 3419a92

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

examples/eval.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -207,6 +207,10 @@ def _run_single_benchmark(test: TestCase, recheck: bool, max_repeats: int, max_t
207207

208208
for i in range(max_repeats):
209209
if recheck:
210+
# ensure we use a different seed for every benchmark
211+
if "seed" in test.args:
212+
test.args["seed"] += 13
213+
210214
data = generate_input(**test.args)
211215
check_copy = _clone_data(data)
212216
torch.cuda.synchronize()

0 commit comments

Comments
 (0)