Skip to content

Commit bd65447

Browse files
Assignment 7.11
1 parent 96f6a0b commit bd65447

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

session_61_assignment_7.11/test.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
required=True, help='The sentence to test the model')
1313
args.add_argument('--infer', type=bool, default=True,
1414
action=BooleanOptionalAction, help='Whether to inferences the model with your sentence or not')
15-
args.add_argument('--n-infer', type=int,
15+
args.add_argument('--num-infer', type=int,
1616
default=100, help='Number of inferences on your sentence')
1717

1818
opt = args.parse_args()
@@ -24,8 +24,8 @@
2424

2525
if opt.infer:
2626
start_time = time()
27-
for i in range(opt.n_infer):
27+
for i in range(opt.num_infer):
2828
classifier.predict(opt.sentence)
2929

3030
duration = time() - start_time
31-
print(f'\nAverage inference time: {duration / opt.n_infer}')
31+
print(f'\nAverage inference time: {duration / opt.num_infer}')

0 commit comments

Comments
 (0)