benchmark_app: except ALLOW_AUTO_BATCHING (#17731)
* benchmark_app: except ALLOW_AUTO_BATCHING Running benchmark_app.py with -b 1 -d CPU fails with `Unsupported property ALLOW_AUTO_BATCHING by CPU plugin`. C++ benchmark_app sets ALLOW_AUTO_BATCHING in ov::Core::compile_model() call, which doesn't trigger the error. * Move `ALLOW_AUTO_BATCHING` to `device_config`
This commit is contained in:
parent
cd4b920bc9
commit
84f46bd048
@ -59,9 +59,6 @@ class Benchmark:
|
|||||||
def set_cache_dir(self, cache_dir: str):
|
def set_cache_dir(self, cache_dir: str):
|
||||||
self.core.set_property({'CACHE_DIR': cache_dir})
|
self.core.set_property({'CACHE_DIR': cache_dir})
|
||||||
|
|
||||||
def set_allow_auto_batching(self, flag: bool):
|
|
||||||
self.core.set_property({'ALLOW_AUTO_BATCHING': flag})
|
|
||||||
|
|
||||||
def read_model(self, path_to_model: str):
|
def read_model(self, path_to_model: str):
|
||||||
model_filename = os.path.abspath(path_to_model)
|
model_filename = os.path.abspath(path_to_model)
|
||||||
head, ext = os.path.splitext(model_filename)
|
head, ext = os.path.splitext(model_filename)
|
||||||
|
@ -324,7 +324,7 @@ def main():
|
|||||||
## If set batch size, disable the auto batching
|
## If set batch size, disable the auto batching
|
||||||
if args.batch_size:
|
if args.batch_size:
|
||||||
logger.warning("Batch size is set. Auto batching will be disabled")
|
logger.warning("Batch size is set. Auto batching will be disabled")
|
||||||
benchmark.set_allow_auto_batching(False)
|
device_config["ALLOW_AUTO_BATCHING"] = False
|
||||||
|
|
||||||
topology_name = ""
|
topology_name = ""
|
||||||
load_from_file_enabled = is_flag_set_in_command_line('load_from_file') or is_flag_set_in_command_line('lfile')
|
load_from_file_enabled = is_flag_set_in_command_line('load_from_file') or is_flag_set_in_command_line('lfile')
|
||||||
|
Loading…
Reference in New Issue
Block a user