Skip to content

Commit 1a3b997

Browse files
committed
formatting
Signed-off-by: Jiamin Ni <jiamin.ni@ibm.com>
1 parent 84aa9ac commit 1a3b997

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

scripts/inference.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -803,12 +803,16 @@ def infer(use_cache, do_sample, warmup):
803803
args.compile_dynamic_sendnn,
804804
**extra_generation_kwargs,
805805
)
806-
if args.device_type == "aiu": # run device initialization warmup for AIU, skip for senulator
806+
if (
807+
args.device_type == "aiu"
808+
): # run device initialization warmup for AIU, skip for senulator
807809
aiu_warmup_time = time.time()
808810
for sample, cache in itertools.product(do_sample, use_cache):
809811
infer(cache, sample, True)
810812
aiu_warmup_time = time.time() - aiu_warmup_time
811-
dprint(f"AIU device initialization warmup complete, took {aiu_warmup_time:.3f}s")
813+
dprint(
814+
f"AIU device initialization warmup complete, took {aiu_warmup_time:.3f}s"
815+
)
812816
else:
813817
for sample, cache in itertools.product(do_sample, use_cache):
814818
infer(cache, sample, True)

0 commit comments

Comments
 (0)