benchmark_app: --latency_percentile: don't list all values (#13799)
Ticket 95243
This commit is contained in:
parent
a48d1558e3
commit
65f83b591e
@ -98,7 +98,7 @@ def parse_args():
|
||||
'Also, using nstreams>1 is inherently throughput-oriented option, while for the best-latency '
|
||||
'estimations the number of streams should be set to 1. '
|
||||
'See samples README for more details.')
|
||||
args.add_argument('--latency_percentile', type=int, required=False, default=50, choices=range(1,101),
|
||||
args.add_argument('--latency_percentile', type=int, required=False, default=50,
|
||||
help='Optional. Defines the percentile to be reported in latency metric. The valid range is [1, 100]. The default value is 50 (median).')
|
||||
args.add_argument('-nthreads', '--number_threads', type=int, required=False, default=None,
|
||||
help='Number of threads to use for inference on the CPU, GNA '
|
||||
@ -159,4 +159,8 @@ def parse_args():
|
||||
"Example: -imean data[255,255,255],info[255,255,255]\n")
|
||||
parsed_args = parser.parse_args()
|
||||
|
||||
if parsed_args.latency_percentile < 0 or parsed_args.latency_percentile > 100:
|
||||
parser.print_help()
|
||||
raise RuntimeError("The percentile value is incorrect. The applicable values range is [1, 100].")
|
||||
|
||||
return parsed_args
|
||||
|
Loading…
Reference in New Issue
Block a user