208 Commits
Author SHA1 Message Date
guozhong wang d3b7a1b86c fix cumulative donot handle nireq (#11775) 2022-06-06 10:10:05 +08:00
guozhong wang f5e2a463b5 remove CPU from default candidate list while GPUs more than 2 (#11753) 2022-05-30 10:04:13 +08:00
yanlan songandHu, Yuan2 0c7840ef28 multi code refine (#11663)
* draft

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* refactor for multi

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* refactor auto draft

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* try to fix executable get config test failed issue

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* set ExecNetwork only one time

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* format code and using alias

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* clear head file

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* change name from Context to ScheduleContext

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* polishing

Signed-off-by: fishbell <bell.song@intel.com>

* polish & new implementation

Signed-off-by: fishbell <bell.song@intel.com>

* enable/test a new schedule

Signed-off-by: fishbell <bell.song@intel.com>

* port fps logs over

Signed-off-by: fishbell <bell.song@intel.com>

* restructure

Signed-off-by: fishbell <bell.song@intel.com>

* fix windows build failure

Signed-off-by: fishbell <bell.song@intel.com>

* clean up code

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-05-25 22:53:47 +08:00
yanlan songandChen Peter 35ba009cd6 Bell/cache refine (#11414)
* cache compliance

Signed-off-by: fishbell <bell.song@intel.com>

* clang format

Signed-off-by: fishbell <bell.song@intel.com>

* fix crash

Signed-off-by: fishbell <bell.song@intel.com>

* enable test cases

Signed-off-by: fishbell <bell.song@intel.com>

* enable more tests

Signed-off-by: fishbell <bell.song@intel.com>

* refine cases

Signed-off-by: fishbell <bell.song@intel.com>

* do not use try catch

Signed-off-by: fishbell <bell.song@intel.com>

* case refine

Signed-off-by: fishbell <bell.song@intel.com>

* fix unicode failure

Signed-off-by: fishbell <bell.song@intel.com>

* use model_path.empty instead of try catch

Signed-off-by: fishbell <bell.song@intel.com>

* add mock test

Signed-off-by: fishbell <bell.song@intel.com>

* add more mock test

Signed-off-by: fishbell <bell.song@intel.com>

* disable unicode test on windows

Signed-off-by: fishbell <bell.song@intel.com>

* add hetero caching/stateful mode support

Signed-off-by: fishbell <bell.song@intel.com>

* remove the disable label for CPU

Signed-off-by: fishbell <bell.song@intel.com>

* resolve the CI failure

Signed-off-by: fishbell <bell.song@intel.com>

remove redundant lines

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: Chen Peter <peter.chen@intel.com>
2022-05-20 10:17:40 +08:00
yanlan songandTaylor Yeonbok Lee 35ad252003 Bell/rule out device (#11516)
* Fix batchability check of MAX_BATCH_SIZE

* Applied review comment

* new implementation

Signed-off-by: fishbell <bell.song@intel.com>

* enable device removing

Signed-off-by: fishbell <bell.song@intel.com>

* enable tests

Signed-off-by: fishbell <bell.song@intel.com>

* Update plugin.hpp

cpplint error

Co-authored-by: Taylor Yeonbok Lee <taylor.lee@intel.com>
2022-05-07 17:41:59 +08:00
yanlan song 912f40e74d stateful inferface impl for AUTO/HETERO (#11590)
* CPU for stateful model

Signed-off-by: fishbell <bell.song@intel.com>

* log

Signed-off-by: fishbell <bell.song@intel.com>

* hetero impl

Signed-off-by: fishbell <bell.song@intel.com>

* enable tests

Signed-off-by: fishbell <bell.song@intel.com>
2022-05-06 12:43:56 +08:00
guozhong wang 0a65f5f607 selectdevice returns MULTI:device in cumulative_throughput (#11367)
* selectdevice returns MULTI:device in cumulative_throughput

* load multi with throughput and disable cpu helper in cumulative

* disable cpu helper in cumulative_throughput

* add cumulative to bechmark_app help message

* modify benchmark_app.hpp clang-format
2022-05-06 12:42:59 +08:00
yanlan songandTaylor Yeonbok Lee 4057e408d8 Bell/shape auto (#11284)
* Fix batchability check of MAX_BATCH_SIZE

* Applied review comment

* clonenetwork in auto

Signed-off-by: fishbell <bell.song@intel.com>

* clone in correct way

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: Taylor Yeonbok Lee <taylor.lee@intel.com>
2022-04-01 11:09:22 +08:00
Anton Pankratov 78285f9db4 Added ov::NotImplemented Exception (#11124)
* Added ov::NotImplemented Exception

* add ie namespace

* Try fix
2022-03-31 07:36:13 +03:00
yanlan song f6e5ec9684 return device infer request in passthrough mode (#11253)
Signed-off-by: fishbell <bell.song@intel.com>
2022-03-30 09:21:13 +08:00
Yuan Hu 50adb2240c [AUTOPLUGIN] don't check dynamic shape when there is only one device (#10868)
* don't check dynamic shape when there is only one device

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* remove redundant if

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-03-16 09:56:23 +08:00
Yuan Hu 4f6dcc1d32 [AUTOPLUGIN] add fps log (#10662)
* add fps log

add format '%lf' for log
add INFO_RUN and DEBUG_RUN, code only run when greater than special log level
add fps log for device
print device config info with DEBUG_RUN
add mock test for DEBUG_RUN and INFO_RUN

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* use n / end -start instead of (n-1) / ((nst start) -(1st start))

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-03-16 09:55:41 +08:00
yanlan song a6583965a5 try avoid timeout in batch plugin during transition in auto plugin (#10753)
* initial debug

Signed-off-by: fishbell <bell.song@intel.com>

* refine

Signed-off-by: fishbell <bell.song@intel.com>

* remove debug msg

Signed-off-by: fishbell <bell.song@intel.com>
2022-03-14 11:05:26 +03:00
yanlan song 8a2252b774 fix multi infer result corrupt issue (#10704)
* do not share blob

Signed-off-by: fishbell <bell.song@intel.com>

* build error

Signed-off-by: fishbell <bell.song@intel.com>

* remove comment codes

Signed-off-by: fishbell <bell.song@intel.com>
2022-03-04 08:13:12 +03:00
Yuan Hu 09379dca86 [AUTOPLUGIN] add device priority if set ov::device::priorities (#10296)
* support config key device priority

for example:
if AUTO:CPU,GPU
the priority of CPU will be higher than GPU

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add test and fix compile and test error

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add an info for device priority and add lost [AUTOPLUGIN] on log

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* parseMetaDevice return all DEVICE of GPU, when use AUTO:GPU

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix compile issue

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* modify test and add test case, fix code issue

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix a bug and mutli with HETERO test failed

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix mock test faild issue

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix misprint

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* Disable AUTO:MYRIAD case

MYRIAD/CoreThreadingTests.smoke_QueryNetwork/targetDevice=MULTI_config=MULTI_DEVICE_PRIORITIES:MYRIAD_
faild on windows
the error is
myriadFuncTests-0 INFO: [E:] [BSL] found 0 ioexpander device

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* use ov::device::priorities key in this PR

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix a logic bug in key_network_priority after enable device priority

add test case cover it

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-02-21 23:06:51 +08:00
guozhong wang 2d88e67616 Guozhong/remove format time (#9923)
* remove formatTimeMilli from time_utils.cpp

* add traceCallStacks test case

* add traceCallStacks test case in format_test.cpp

* add param:"test" to function TraceCallStacks()

* rollback file in master branch

* add traceCallStacks test case in format_test.cpp

* remove formatTimeMilli from time_utils.cpp and add traceCallStacks test case in format_test.cpp
2022-02-18 09:36:01 +08:00
bell f75e50cc88 limit gpu compiling threads (#10349)
* limit gpu compiling threads

Signed-off-by: fishbell <bell.song@intel.com>

* switch to 2.0

Signed-off-by: fishbell <bell.song@intel.com>

* clang format

Signed-off-by: fishbell <bell.song@intel.com>
2022-02-15 08:52:49 +03:00
guozhong wang 14c1e98e8c Guozhong/check format (#10184)
* remove formatTimeMilli from time_utils.cpp

* add traceCallStacks test case

* add traceCallStacks test case in format_test.cpp

* add param:"test" to function TraceCallStacks()

* catch the exception of checkFormat

* add space for try catch

* rollback time_utils.cpp time_utils.hpp and log_utils_format_test.cpp

* modify testcase for log.hpp

* modify testcase from format_s to format_s_d_ld_u_lu2
2022-02-11 19:10:13 +03:00
Yuan Huandfishbell 7abd61f867 [AUTOPLUGIN] OV config 2.0 support (#10191)
* add support for LOG_LEVEL and supported_properties

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix compile error

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add test case for log_level and full_name

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* update to ov 2.0

Signed-off-by: fishbell <bell.song@intel.com>

* fix benchmark_app faild for AUTO:GPU, GPU

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add case

Signed-off-by: fishbell <bell.song@intel.com>

* refine logic

Signed-off-by: fishbell <bell.song@intel.com>

* add test cases

Signed-off-by: fishbell <bell.song@intel.com>

* add more cases

Signed-off-by: fishbell <bell.song@intel.com>

* fix redifinition

Signed-off-by: fishbell <bell.song@intel.com>

* cpu plugin only in cpu tests

Signed-off-by: fishbell <bell.song@intel.com>

* typo in parameter

Signed-off-by: fishbell <bell.song@intel.com>

* use _core directly

Signed-off-by: fishbell <bell.song@intel.com>

* fix multi case failure

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: fishbell <bell.song@intel.com>
2022-02-11 23:39:09 +08:00
Sergey Shlyapnikov 8f0e974ee6 [GPU] Add new properties and fix bechmark_app (#10149) 2022-02-09 09:18:54 +03:00
Vladislav Volkov a365ee768b Fix for leaked ExecutorManager (#10070)
* Fix for leaked ExecutorManager

* Code style fix

* Fixed plugin pointer access from ExecutableNetwork
2022-02-05 14:03:50 +03:00
Anton PankratovandIlya Lavrenov ced90de0a5 PERF_COUNT replaced with ov::enable_profiling (#10118)
* String conversions in any

* Fixed chaching tests

* Fixed tests

* fixed build

* PERF_COUNT replaced with ov::enable_profiling

* fixed format

* fixed format

* fixed optimal config

* merge fix

* fix build

* format fix

Co-authored-by: Ilya Lavrenov <ilya.lavrenov@intel.com>
2022-02-05 13:27:46 +03:00
Ilya Lavrenov f2f281e60b Renamed ov_runtime => openvino, ov_ => openvino_ prefix (#10069)
* Renamed ov_runtime => openvino, ov_ => openvino_ prefix

* Coverage fix

* More fixes

* Fixed MO tests with custom FE
2022-02-03 20:03:41 +03:00
Anton Pankratov 8993c4c18a Deprecated ov::Any implicit cast to any types (#9409)
* Depricated Any implicit cast

* Fixed test

* fixed gna build

* Fixed warnings in benchmark_app

* Fixed test build

* ncc exception for PrintTo

* Error mesage in test

* Error mesage in test

* fixed build
2022-02-03 19:10:52 +03:00
Anton Pankratov 5c9b6915dc Added undefined perfomnance hint value (#10082)
* Added undefined perfomnance hint value

* Added tests

* Fixed tests

* fixed dormat
2022-02-03 18:03:45 +03:00
Sergey Shlyapnikov ccf4f4e420 [GPU] Update config api 2.0 (#9649) 2022-02-03 13:04:36 +03:00
Ilya Churaev 03c38ca3fd Changed code which check newAPI flag from Core (#10080)
* Changed code which check newAPI flag from Core

* Fixed typo
2022-02-03 10:36:23 +03:00
Yuan Huandfishbell 8892b7b327 add Debug statistic log for devices infer nums (#9825)
* add statics log

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* change LOG_DEBUG to LOG_INFO

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix type

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: fishbell <bell.song@intel.com>
2022-02-01 14:18:29 +03:00
Wang, Yang 80d70dd438 Ywang2/update auto configuration api (#9977)
* Update AUTO OV 2.0 c++ configuration API.

Signed-off-by: ywang2 <yang4.wang@intel.com>

* Support the OV 2.0 key to set model priority and add the test case to verify the prioirty map logic within AUTO plugin.

Signed-off-by: ywang2 <yang4.wang@intel.com>

* Replace the old model priority key and add the corresponding test case.

Signed-off-by: ywang2 <yang4.wang@intel.com>
2022-01-31 16:24:46 +08:00
bell aaf02ab4c7 modify optimal request num(add a multiplexer) (#10004)
* muliply the request# by 2

Signed-off-by: fishbell <bell.song@intel.com>

* modify case

Signed-off-by: fishbell <bell.song@intel.com>
2022-01-30 16:43:41 +03:00
Yuan Huandfishbell 8883732ca8 [AutoPlugin] get optimal infer request number (#9529)
* dynamic optimal infer request

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* modify test case to match logic

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* for CPU_HELP,CPU case, use default value

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* update logic for GPU VPUX MYRIAD

throughput
GPU num = GPU_THROUGHPUT_STREAMS * 2
VPUX = 8
MYRIAD = 4

other mode
GPU NUM = 1
VPUX = 1
MYRIAD = 1

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* print GPU_THROUGHTPUT_STRREAM FOR TEST

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* get streams num from rangestreams for GPU

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* Revert "print GPU_THROUGHTPUT_STRREAM FOR TEST"

This reverts commit 06e348d21dfaed626bebcc32837737da9b036e44.

* use default variable instead of 4u and 1u

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* simple if else logic

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* check allow batching key

Signed-off-by: fishbell <bell.song@intel.com>

* add comment, optimize logic

Signed-off-by: fishbell <bell.song@intel.com>

Co-authored-by: fishbell <bell.song@intel.com>
2022-01-28 10:13:02 +08:00
song, bell 49c2086d23 allocate host blob from hw context (#9854)
* allocate host blob from hw context

Signed-off-by: fishbell <bell.song@intel.com>

* accomodate to new namespace

Signed-off-by: fishbell <bell.song@intel.com>

* fix build

Signed-off-by: fishbell <bell.song@intel.com>

* refine logic

Signed-off-by: fishbell <bell.song@intel.com>

* dynamic shape need to share blob with cpu infer request

Signed-off-by: fishbell <bell.song@intel.com>

* reuse icore from core

Signed-off-by: fishbell <bell.song@intel.com>

* cpu,gpu case fallback to original code, CI failure

Signed-off-by: fishbell <bell.song@intel.com>
2022-01-27 13:52:25 +08:00
song, bell f2e5788035 use priority queue for timeout issue (#9765)
* use priority queue for timeout issue

Signed-off-by: fishbell <bell.song@intel.com>

wrap tbb pq

Signed-off-by: fishbell <bell.song@intel.com>

clang format

Signed-off-by: fishbell <bell.song@intel.com>

fix potential dead-lock

Signed-off-by: fishbell <bell.song@intel.com>

fix arm build

Signed-off-by: fishbell <bell.song@intel.com>

try fix build on arm

Signed-off-by: fishbell <bell.song@intel.com>

merge master

Signed-off-by: fishbell <bell.song@intel.com>

* remove debug info

Signed-off-by: fishbell <bell.song@intel.com>

* use atomic to replace the lock

Signed-off-by: fishbell <bell.song@intel.com>

* clang format

Signed-off-by: fishbell <bell.song@intel.com>
2022-01-25 18:44:46 +03:00
Anton Pankratov f45991bd64 OV 2.0 c++ configuration API (#9870)
* New configuration API

* Review fix

* review coments

* fixed device name map

* fixed header

* code stile

* fixed optimization capabilities

* flatten properties

* dox fix

* doc

* merge conflicts

* fixed merge conflicts

* Fixed subobject linkage warning

* foramt fix

* Fixed unity test build

* Merge conflict fixes

* Fixed variadic
2022-01-25 12:43:56 +03:00
song, bell 2b9e726040 enable batching plugin through auto (#9520)
* initial commit

Signed-off-by: fishbell <bell.song@intel.com>

* remove debug code

Signed-off-by: fishbell <bell.song@intel.com>

* fix bug  with CPU,GPU

Signed-off-by: fishbell <bell.song@intel.com>

* refine code and test case for auto batching

Signed-off-by: fishbell <bell.song@intel.com>

* optimize the batching query

Signed-off-by: fishbell <bell.song@intel.com>

* refine test case

Signed-off-by: fishbell <bell.song@intel.com>

* optimize if/else

Signed-off-by: fishbell <bell.song@intel.com>

* fix sporadic crash

Signed-off-by: fishbell <bell.song@intel.com>

* refine logic

Signed-off-by: fishbell <bell.song@intel.com>

* refine case

Signed-off-by: fishbell <bell.song@intel.com>

* temp solution to disable batching in auto

Signed-off-by: fishbell <bell.song@intel.com>

* add debug logs

Signed-off-by: fishbell <bell.song@intel.com>

* merge with #9724

Signed-off-by: fishbell <bell.song@intel.com>

* refine the logic

Signed-off-by: fishbell <bell.song@intel.com>

* accurate debug message

Signed-off-by: fishbell <bell.song@intel.com>
2022-01-25 16:28:49 +08:00
Alexander Zhogov 6c2d1e923c Revert "OV2.0 c++ configuration API (#9829)" (#9860)
This reverts commit 50da8c4aed.
2022-01-24 11:29:09 +03:00
Anton Pankratov 50da8c4aed OV2.0 c++ configuration API (#9829)
* New configuration API

* Review fix

* review coments

* fixed device name map

* fixed header

* code stile

* fixed optimization capabilities

* flatten properties

* dox fix

* doc

* merge conflicts

* fixed merge conflicts

* Fixed subobject linkage warning

* foramt fix
2022-01-21 18:44:41 +03:00
Alexander Zhogov 79ff926b6d Revert "OpenVINO runtime Configuration API (#7750)" (#9828)
This reverts commit 400e9ad916.
2022-01-21 13:30:39 +03:00
Anton Pankratov 400e9ad916 OpenVINO runtime Configuration API (#7750)
* New configuration API

* Review fix

* review coments

* fixed device name map

* fixed header

* code stile

* fixed optimization capabilities

* flatten properties

* dox fix

* doc

* merge conflicts

* fixed merge conflicts
2022-01-21 10:32:57 +03:00
Yuan Hu 403339f8f4 [AUTOPLUGIN] not select if only one device (#9730)
* if only one Device, not select

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* modify test case to match logic

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-01-19 17:13:29 +03:00
Alexey Suhov a79830cb55 Update year to 2022 in copyright notice (#9755) 2022-01-19 01:07:49 +03:00
Yuan Hu 580a0f30eb [AUTOPLUGIN] Add format string checker for log information (#9592)
* add limit format on snprintf

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add limit on format

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add test case

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* fix a bug for LOG_TRACE

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* remove debug info
2022-01-17 14:50:01 +03:00
Wang, Yang c7d216db13 passing by reference to fix performance inefficiencies. (#9590)
* passing by reference to fix performance inefficiencies.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* Passing by const reference.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>
2022-01-14 15:33:58 +03:00
song, bell 282f37cdae fix sporadic crash (#9616)
Signed-off-by: fishbell <bell.song@intel.com>
2022-01-13 10:25:53 +03:00
song, bell 3e9ae4bea7 Bell/release resource (#9222)
* recycle helper resources when hw is ready

Signed-off-by: fishbell <bell.song@intel.com>

* use cv to avoid additional while loop

Signed-off-by: fishbell <bell.song@intel.com>

* refine the logic

Signed-off-by: fishbell <bell.song@intel.com>

* fix potential threading issue

Signed-off-by: fishbell <bell.song@intel.com>

* refine logic

Signed-off-by: fishbell <bell.song@intel.com>

* avoid using global var

Signed-off-by: fishbell <bell.song@intel.com>

* clean up code

Signed-off-by: fishbell <bell.song@intel.com>

* refine

Signed-off-by: fishbell <bell.song@intel.com>

* release helper network/plugin also

Signed-off-by: fishbell <bell.song@intel.com>

* lock when release, avoid double release in destructor

Signed-off-by: fishbell <bell.song@intel.com>

* formatting

Signed-off-by: fishbell <bell.song@intel.com>

* add test case

Signed-off-by: fishbell <bell.song@intel.com>

* add case coverage

Signed-off-by: fishbell <bell.song@intel.com>

* move the task

Signed-off-by: fishbell <bell.song@intel.com>

* remove uncessary lock

Signed-off-by: fishbell <bell.song@intel.com>
2022-01-11 19:41:17 +03:00
Yuan Hu 00361b7617 try to fix klocwork issue (#9207)
Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-01-10 14:57:37 +03:00
Yuan Hu b6951bfb2c change INT8 to VPUX as first priority (#9261)
Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>
2022-01-10 14:54:21 +03:00
49b5e5728b Auto Batching impl (#7883)
* auto-batching POC squashed (all commits from auto-batch-2021.3 branch)

(cherry picked from commit d7742f2c747bc514a126cc9a4d5b99f0ff5cbbc7)

* applying/accomodating the API changes after rebase to the master

* replaying modified version of actual batch selection

* eearly experiments with model mem footprint

* changes from rebasing to the latest master

* experimenting with DG1 on the batch size selection, also collecting the mem footprint

* WIP:moving the auto-batching to the icore to let the MULT/AUTO support that, ALLOW_AUTO_BATCHING as a conventional config key. still fials hot device swap

* quick-n-dirty batch footpint vs device total mem

* code style

* testing which models perform badly due to kernels and NOT (batched) footprint

* stub  pipeline task to comunicate the readiness rather than promise/future

* quick-n-dirty timeout impl

* explicit _completionTasks,reverting BA to use the timeout

* inputs outputs copies, works with AUTO and demo now

* accomodate the config per device-id, after rebase to the latest master

* allowing the auto-batching only with tput hint to let more conventional tests pass

* fix the pre-mature timeout restaring via waiting for batch1 requests completion

* moved the bacthed request statring ( along with input copies) to the dedicated thread

* [IE CLDNN] Disable bs_fs_yx_bsv16_fsv16 format for int8 convolution

* code style

* increasing the timeout to test the ssd_* models perf (timeout?) issues

* reducing number of output stuff in BA to avoid bloating the logs in experiments

* more aggressive batching for experiments, not limited to 32 and also 4 as a min

* more accurate timeout debugging info

* getting the reqs limitation from the plugin SetConfig as well

* refactor the reshape logic a bit to accomodate CPU for bathcing, also added remeote context

* let the benchamrk_app to consume specific batch values for the auto-batching such as BATCH:GPU(4)

* auto-batching functional test (with results check vs ref) and GPU instance for that

* fixed arithemtic on blobs ptrs

* clang

* handling possible batched network failure

* BATCH as the constants device name in test

* ENABLE_BATCH

* func tests for CPU, also DetectionOutput hetero tests (CPU and GPU)

* DetectionOutput hetero test for the CPU

* reenabling the Auto-Batching in the AUTO

* auto-batching device enabled in the test

* fixed the DO test

* improve the loading loop logic

* brushed the config keys

* allow hetero code-path for explicit device name like BATCH:GPU(4), used in the hetero code-path tests

* fix the test after refactoring

* clang

* moving ThreadSafeQueue to the ie_parallel, as it is re-used in the AUTO/MULTI and BATCH now

* auto-batching hetero test (subgraph with DetectionOutput)

* fixed minor changes that were result of experiments with impl

* code-style

* brushing, disabling CPU's HETERO tests until planned activity for 22.2

* removing home-baked MAX_BATCH_SZIE and swicthing to the official impl by GPU team

* remote blobs tests for the auto-batching (old API)

* brushed names a bit

* CreateContext and LoadNEtwork with context for the Auto-Batching plus remote-blobs tests

* fixed the ieUnitTests with adding CreateContext stub to the MockICore

* clang

* improved remote-blobs tests

* revert the back BA from exeprimenents with AB + device_use_mem

* conformance tests for BATCH, alos batch size 1 is default for BATCH:DEVICE

* remote blobs 2.0 tests, issue with context having the orig device name

* debugging DG1 perf drop (presumably due to non-fitting the device-mem)

* disbaling WA with batch/=2 for excesive mem footptint, leaving only streams 2

* remote blobs 2.0 tests for different tensor sharing types

* converting assert to throw to accomodate legacy API where the lock() was possible to be called

* revert the timeout back to avoid mixing the studies, fixed the footprint calc

* reverting to estimating the max batch by extrapolating from bacth1 size

* more conservative footptint etimation (with bacth1), graceful bacth 1 handling without duplication

* even graceful batch 1 handling without duplication

* WA for MAX_BATCH_SIZE failure, removing batch4 as a min for the auto-batching

* AutoBatchPlugin -> ov_auto_batch_plugin

* WA for gcc 4.8

* clang

* fix misprint

* fixed errors resulted from recent OV's Variant to Any transition

* skip auto-batching for already-batched networks

* AUTO_BATCH_TIMEOUT and tests

* GPU-specific L3

* switched to pure config, also improved ALLOW_AUTO_BATCHING config key handling logic

* debugging device info

* enabling the config tests for the GPU and fixing the Auto-batching tests to pass

* making the default (when not recognized the driver) cache size more aggressive, to accomodate recent HW with old drivers

* skip auto-batching for RNNs and alikes (e.g. single CHW input)

* fixed fallback to the bacth1 and moved HETERO path under condition to avoid bloating

* brushing

* Auto plugin GetMetric support gpu auto-batch

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add test case

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* add comments on test

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* brushing the vars names, alos adding the excpetion handling

* disabling the auto-batching for the networks with non-batched outputs and faster-rcnn and alikes (CVS-74085) to minimize the of #failures

* add try catch

Signed-off-by: Hu, Yuan2 <yuan2.hu@intel.com>

* brushing the code changed in the GPU plugin

* Auto-Batch requests tests

* brushed varibles a bit (ref)

* cleaned debug output from the ie_core

* cleaned cmake for the Auto-Batch

* removed batchN estimation from batch1

* cleaned from debug printf

* comments, cleanup

* WA the mock test errors introduced with merging the https://github.com/myshevts/openvino/pull/13

* Adding back  removed batchN estimation from batch1 to debug degradations on DG1 (resulted from too optimistic MAX_BATCH_SIZE?). This partially reverts commit e8f1738ac1.

* brushing ie_core.cpp

* fix 32bit compilation

* Code review: ENABLE_AUTO_BATCH

* consolidate the auot-batching logic in ie_core.cpp into single ApplyAutoBAtching

* renamed brushed the OPTIMAL_BATCH (now with_SIZE) and mimicks the MAX_BATCH_SZIE  wrt MODEL_PTR

* default value for the OPTIMAL_BATCH_SIZE

* clang

* accomodate new func tests location

* fix shuffle of headers after clang + copyrights

* fixed misprint made during code refactoring

* moving the common therad-safe containers (like ThreadSafeQueue) to the dedicated dev_api header

* switch from the device name to the OPTIMAL_BATCH_SIZE metric presence as a conditin to consider Auto-Batching

* switching from the unsafe size() and minimizing time under lock

* code style

* brushed the ApplyAutoBatching

* brushed the netric/config names and descriptions

* completed the core intergration tests for the auto-batching

* ExecGraphInfo and check for incorrect cfg

* removed explicit dependencies from cmake file of the plugin

* disabling Auto-Batching thru the tput hint (to preserve current product default), only excplicit like BATCH:GPU used in the tests

Co-authored-by: Roman Lyamin <roman.lyamin@intel.com>
Co-authored-by: Hu, Yuan2 <yuan2.hu@intel.com>
2021-12-24 12:55:22 +03:00
Ilya Churaev 42350a705e Remove legacy targets (#9333)
* Remove some legacy targets

* Replace some targets

* Removed inference_engine_plugin_api dependency

* Minor comment for developer config

* Fixed include paths

* Small fixes for static build

* Try to fix build pyopenvino

* Fixed comments

* Try to fix build

* Include OpenVINODeveloperPackage inside InferenceEngineDeveloperPackageConfig

* Try to fix GAPI tests
2021-12-23 08:16:23 +03:00
Wang, Yang 8c746fd52c Align AUTO/MULTI/HETERO wording (#8884)
* Align AUTO's behavior to parent Epic.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* update wording.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* Update.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* Update wprding in hetero plugin.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* Update.

Signed-off-by: Wang, Yang <yang4.wang@intel.com>

* Change "metric" to  "metric key".

Signed-off-by: Wang, Yang <yang4.wang@intel.com>
2021-12-22 12:21:08 +03:00