Commit Graph

82 Commits

Author SHA1 Message Date
Ilya Lavrenov
a34ef680f2 Made plugins.hpp generation to be CONFIG dependent (#17139) 2023-04-24 14:48:45 +04:00
Ilya Lavrenov
46f8ebfaec Revert "Fix C API unite test case error (#17012)" (#17128)
This reverts commit 63c0089128.
2023-04-22 01:44:34 +04:00
Ilya Lavrenov
fbc28297ec Enabled C-API tests on ARM platform (#17119)
* Enabled C-API tests on ARM platform

* Fixed ARM CPU plugin test on streams
2023-04-21 22:55:18 +04:00
Ilya Churaev
71880aadd3 Deprecate set batch method (#17057)
* Deprecate set batch method

* Fixed some errors

* Suppress warning in tests

* Fixed warning in GPU

* Deprecate python
2023-04-19 20:21:18 +00:00
Xuejun Zhai
63c0089128 Fix C API unite test case error (#17012)
* Fix C API unite test case error

Signed-off-by: Zhai, Xuejun <xuejun.zhai@intel.com>

* Fix test error with relative path

Signed-off-by: Zhai, Xuejun <xuejun.zhai@intel.com>

---------

Signed-off-by: Zhai, Xuejun <xuejun.zhai@intel.com>
Co-authored-by: River Li <river.li@intel.com>
2023-04-19 11:26:12 +04:00
Ilya Churaev
25826bfe7d Added deprecation of nv12 legacy API (#16982)
* Added deprecation of nv12 legacy API

* Added new files

* Change macros

* Suppress warnings for preprocessing

* Suppress warnings in tests

* Suppress warnings for Windows
2023-04-17 14:13:43 +00:00
Xuejun Zhai
e238bfc1d0 Fix C API test failed with debug version on Windows & MacOS (#16903)
Signed-off-by: Zhai, Xuejun <xuejun.zhai@intel.com>
2023-04-13 10:59:42 +04:00
Vitaliy Urusovskij
7442a17240 Add Core property to switch from mmap to read in IR Frontend (#16600)
* Add Core property to switch from `mmap` to `read`
in IR FrontEnd

* Add tests on `ov::enable_mmap` property

* Add `enable_mmap` in C & Py APIs

* ClangFormat
2023-04-05 18:22:11 +04:00
Shen, Wanglei
9f54504232 update cpu properties name to enable_hyper_threading and enable_hyper_threading (#16723) 2023-04-04 15:25:11 +04:00
River Li
dec425c408 [C API] remove UNDEFINED property value (#16709) 2023-04-03 16:54:03 +04:00
Shen, Wanglei
86da15e621 enable new property ov::hint::use_cpu_pinning (#16383)
* enable ov::hint::use_cpu_pinning

* update test case for comments

* update header file

* update header file

* Delete cpu_streams_calculation.hpp

* Revert "Delete cpu_streams_calculation.hpp"

This reverts commit a1074ca843.

* update config name

* fix code styple issue

* update for merge conflict
2023-04-03 18:14:33 +08:00
Wang Wangwang
99eda5b5e1 [PYTHON][CAPI][AUTO] Add ENABLE_STARTUP_FALLBACK and ENABLE_RUNTIME_FALLBACK proper… (#16436)
* [AUTO] Add ENABLE_STARTUP_FALLBACK and ENABLE_RUNTIME_FALLBACK properties to Python API

* Add DEVICE_BIND_BUFFER property

* Add AUTO properties to C API

* Update test case && Update AUTO properties in PYTHON API

* Create dedicated files for auto plugin

* Update header files

* Update test case

* Modify code style

* Update variable name

* Add test case for invalid input value
2023-04-03 11:56:48 +08:00
guozhong wang
341217de99 Unify code path for MULTI and AUTO CTPUT hint (#16349)
[MULTI] pass through to AUTO with CTPUT hint
After this change
-- MULTI doesn't support setting infer request via CPU(4),GPU(8).
-- MULTI doesn't support CompiledModel::set_property() and ExecutableNetwork::GetConfig().
2023-03-31 18:40:41 +02:00
Sun Xiaoxia
988a8dd6a9 Xiaoxia/Optimize the streams calculation process (#15777)
* add _big_core_logic_streams

* modify core binding with cpu mapping table

* get _cpu_ids with querying cpu_mapping_table

* fix mac build issue

* fix cpu func test issue

* fix clang-format issue

* remove getCoreOffset and getThreadStep

* motify return false from cpuMapAvailable on windows

* remove core binding in latency mode

* add bind core on windows

* add model prefer threads

* modify streams calculating schedule in ApplyPerformanceHints

* modify MakeDefaultMultiThreaded and Stream

* add unified cpu binding with cpu_mapping on linux and windows. add GPU core binding interface. modify streams calculation scheduling

* fix code style issue

* modify default streams to 1 to fix ci test issue

* add SetStreamtoConfig, modify getNumOfAvailableCPUCores to fix continuous call loadnetwork issue

* modify code according to comments

* fix build issue on macos

* fix macos error

* fix cputest issue

* fix build issue on macos

* move features about CPU to lin_system_config.cpp

* fix code style

* fix bebian_arm build failed issue

* fix macos build issue

* fix code style

* fix test issue on windows

* fix code style

* add latency in hybrid_aware condition

* add the condition used all cores in latency mode

* fix code style

* fix code style

* add init_cpu

* fix code style

* fix streams=2 issue

* fix multi gpu core bind issue

* modify interface

* fix debian arm build issue

* add bind core in different socket

* fix code style

* fix build issue on windows

* fix GPU set_executor_config sync issue

* fix latency issue

* fix bind_cores issue

* modify model prefer on tigerlake machine

* modify according to comments

* fix code style

* modify GPU reserve CPU interface, remove bind core on windows feater

* fix code style

* add 3rd type core in cpu_mapping_table

* fix build issue

* update test case

* modify core bind behavior in latency mode

* remove 3rd core type function

* update format

* add lock in get_task_flag

* not bind core in latency mode

* change model_prefer to 0 with latency mode on core machine. bind core with latency mode on core machine

* remove a void thread

* modify condition of create task_area

* modify comments

* fix according to comments

* fix spelling mistake

* fix according to comments

* fix code style

---------

Co-authored-by: Shen, Wanglei <wanglei.shen@intel.com>
2023-03-29 18:26:27 +08:00
Vitaliy Urusovskij
40cc006bae Enable MapAllocator in IR Frontend (#12673)
* Enable MapAllocator in IR Frontend

* Fix `ov_infer_request_ppp` test

With `mmap()`ing of IR, .bin can't be deleted until unmapping.
And it shows that there was a leak in test

* Add comment to Win `CreateFile()` regarding
FILE_SHARE_DELETE

* Unmap .bin file before IR files deletion

Wait ov::Model deletion to trigger .bin file unmapping
before IR files deletion

* ClangFormat

* Add `use_map_allocator` switch in FE

In case of direct use of FE (e.g. via MO), `mmap()` is OFF.
But in case of use FE via Core, `mmap()` is ON.
2023-03-28 23:24:13 +04:00
Shen, Wanglei
a726f0ae38 Enable new property ov::hint::scheduling_core_type (#16106)
* enable apply_processor_type()

* declare PROCESSOR_TYPE

* enable readProperties

* test case for get_property()

* enable set_property() and test cases

* reduce changes

* fix code style issue

* fix python test case issue

* remove python interface

* move processor type definition out of dev_api

* refine coding

* add dependency

* update header file

* update description

* merge intel_cpu header file

* add inline in-code documentation

* change 'UNDEFINED' to 'DEFAULT'

* remove ProcTypeConfig

* refine change

* refine change

* refine process_type to scheduling_core_type

* refine description

* fix code style issue

* change to ov::hint::scheduling_core_type

* fix code style issue

* fix code style issue

* fix python issue

* fix python issue

* fix python issue

* fix python issue

* change core_type_cfg to ov::hint::SchedulingCoreType

* update test case for comments

* update test case for comments

* add default for comments

* update code style

* update for comments

* update for comments

* fix typo

* move cpu_map_scheduling into threading folder

* update for merge conflict

* update for code style
2023-03-28 10:04:30 +04:00
Shen, Wanglei
815d4abc03 enable new property ov::hint::use_hyper_threading (#16176)
* enable apply_processor_type()

* declare PROCESSOR_TYPE

* enable readProperties

* test case for get_property()

* enable set_property() and test cases

* reduce changes

* fix code style issue

* fix python test case issue

* remove python interface

* move processor type definition out of dev_api

* refine coding

* add dependency

* update header file

* update description

* merge intel_cpu header file

* add inline in-code documentation

* change 'UNDEFINED' to 'DEFAULT'

* remove ProcTypeConfig

* refine change

* refine change

* enable new property use hyper threading

* update description

* resume legacy code

* change to ov::hint namespace

* update including header file

* update C API and Python API

* update description for comments

* update test case for comments

* update function location for comments

* fix typo

* fix typo

* fix code style issue and update test case

* move cpu_map_scheduling into threading folder
2023-03-28 00:39:26 +04:00
River Li
232c802e07 [CAPI] Add ov::hint::execution_mode property (#16466) 2023-03-22 12:18:40 +04:00
River Li
0ca3ccb7fb [CAPI][TEST] remove testdata repository dependency (#16259)
* [CAPI][TEST] remove testdata repository dependency

Change-Id: I93798d47bcf4abf69562f76aab1469498b4e9ee1

* SCI issue

Change-Id: Ifb422fafdefe26be85a0ae8efdc1530f7f032079

* Apply TEST SUIT for C API tests

Change-Id: Ic716cdb357060e1cbf989871ae39d006f2878632

* Fix issue for static build

Change-Id: I5d33f23b48dcda4baf260553aa8d34e62c13c128
2023-03-14 12:34:33 +00:00
Ilya Lavrenov
7be7f25566 Added TF / TF Lite in API reference docs (#16023) 2023-03-02 16:45:18 +04:00
Ilya Lavrenov
0d798b7431 Building GPU plugin for Linux ARM64 (#16008)
* Building GPU plugin for ARM64

* changed order of headers

* Fixed clang-format
2023-03-02 12:43:33 +04:00
Ilya Lavrenov
ba19d945ac Fixed clang-format for C API (#16024) 2023-03-01 16:36:20 +04:00
Haiqi Pan
3f06d871bf Remove catch(...) code style (#14433)
* remove ... in /src/bindings/c and resolve format

* remove ... in auto and resolve format

* remove ... in auto batch and resolve format

* remove ... in hetero and resolve format

* IE exception

* IE exception

* const

* const

* resolve format and ov::Exception

* ov::Exception

* reset IE::Exception

* remove ov::Exception

* InferenceEngine->IE in auto_schedule.cpp

* fix coredump while runing test case smoke_AutoMultiMock_NumStreamsAndDefaultPerfHintToHWTest

* fix coredump issue of running LoadNetworkWithSecondaryConfigsMockTest

* fix commpile fail in CI

* resolve core dump of running exec_network_get_metrics.cpp and disable some test cases for KEEMBAY and MYRIAD in exec_network_get_metrics.cpp

* remove test cases of MYRIAD and resolve core dump of running KEEMBAYin exec_network_get_metrics.cpp

* resolve conflic of common.h

* resolve conflic of common.h

* resolve common.h complie fail

---------

Co-authored-by: guozhong <guozhong.wang@intel.com>
Co-authored-by: Ilya Churaev <ilya.churaev@intel.com>
2023-02-16 11:44:24 +08:00
Ilya Lavrenov
1f3e469c5e Added -Wall for Clang and GCC (#15513)
* Added -Wall for Clang and GCC

* Fixes

* Don't use /J

* Fixed warnings

* Fixed warnings

* More fixes

* Fixed for MSVC

* Fixed more warnings on Windows

* Suppressed some warnings in template plugin

* Update src/tests/functional/plugin/shared/include/behavior/plugin/caching_tests.hpp

* Added suppression for PT FE

* Suppressed warnings in TF FE

* Suppressed warnings on Core unit tests

* Suppress warnings in python

* Suppressed Windows warning for 3rd party modules

* Suppresed one more warning
2023-02-08 15:01:00 +04:00
Ilya Lavrenov
6865f8f147 Fixed C API tests build (#15530) 2023-02-06 19:08:33 +04:00
River Li
b04513c92e [C API] remote tensor support (#13719)
* [C API] remote tensor support

Provide C interface for remote context and remote tensor:
   1. OCL and VA context and buffer support
   2. unite test for remote context and remote tensor

Change-Id: I2c449aef21cbe928ca470b4e3bcf1e03a1d1ca43

* Fix clang issue

Change-Id: I83c9592d21ff9cb8aeb85148277d96db74b455c7

* [CAPI] Add ocl nv12 input inference test case

1. Add fully nv12(2 ocl remote tensor) as input plus preprocess do csc+resize, then do inference
2. Add get_device_name for remote tensor
3. Add test case for preprocess to set mem type

Change-Id: Ieaab50c8de20e5c7258697030672e0b010627a81

* Update documentation

Change-Id: Ia7dbaea48d38f5534aba60fbb25cd0a1f2f9eab0

* Remove debug code

Change-Id: Ic5c5a24d3c40bb258b7007dcea44594af2d92344

* Fix issues brought by rebase

Change-Id: I2520c5ccf3620349e202ea40c08bb1c437d5af88

* Resolve document issue

Change-Id: Ia14500f8623147f481dda286a0afaa8ecfffa7c9

* Resolve some comments
1. Add specific header file for gpu plugin
2. clang-format issue
3. interface compatible issue

Change-Id: Icc4723af071af30f0422ac9a107e57ddeec94aac

* fix clang issue

Change-Id: I46e1fed3dd9a4e51260b695dc3fb194b9571ed58

* Add gpu header file directory

Change-Id: I8c15d9da58a46c070dcc68530cb2beea8cd4bba9

* Remove HAVE_OCL_SUPPORT macro

Change-Id: I10093a99c1858649f1c5502248729704fcec34ef

* Address some comments

Change-Id: I72830288d063623641e8946c8470631e81fdeb34

* Printov:AnyMmap with the help of ov::Any

Change-Id: I8abd3a8d94ba8116974c59a489cda2af15f225d7
2023-02-06 16:27:53 +08:00
Ilya Churaev
1bb8223ecd Template ov plugin (#15220)
* Initial migration of TemplatePlugin to ov::IPlugin interface

* Fixed segfault

* Fixed static build and some template tests

* Fixed code style

* Fixed some template tests

* Fixed scale tests

* Disabled transformations in the template plugin

* Fixed ONNX tests

* Fixed compilation

* Fixed core tests

* Fixed some crashes

* Small fixes

* Migrate to ICompiledModel

* Fixed some behaviour tests (add legacy names and supported_properties)

* Fixed output precisions

* Fixed some tests

* Changed parameter->result test

* Fixed some preprocessing tests

* Added mean image preprocessing

* Disabled some tests

* Fixed some template tests

* Try to fix not implemented false

* Try to fix template tests

* Fixed doc

* Catch ov::NotImplemented exception

* Small changes

* Fixed build

* Try to fix build

* Fixed some comments

* Use new properties

* Fixed documentation

* Fixed properties
2023-02-03 13:37:40 +04:00
Xuejun Zhai
5030660b9f Xuejun/fix cvs 98110 (#14534)
* [CAPI][UNITE TEST] 1) create plugin test xml file in runtime; 2) fix arm plugin test error;

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [CAPI] fix format issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [CAPI] change the time of Copyright

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

---------

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2023-02-02 11:01:37 +04:00
Vitaliy Urusovskij
ea48786bc6 Fix "(un)register_plugin(s)" C and Py tests (#15291)
* Fix "(un)register_plugin(s)" tests

* Remove test skips on Debian after tests are fixed
2023-01-27 09:54:43 +04:00
Vitaliy Urusovskij
54ea2612ae [Core] Safe loading of default plugins (#15073)
* Safe loading of default plugins

1. In case of default plugins.xml all plugins is registered by
absolute paths
2. In case of user API user is able to specify abs or rel path
or plugin name to be found in ENV
3. Update `ov::util::get_absolute_file_path()` in order to prevent
checking file exists or can be accessed
4. Add tests + delete duplicated tests

* Add `OV_CORE_CALL_STATEMENT` to `Core()` ctor
to convert InferenceEngine::Exception to
ov::Exception

* Add `ie_plugins.hpp` dependency to `ov_infer_unit_tests`

* Update C and Py docstrings

* Comment fix

* Update LD_LIB_PATH in openvino-onnx/Dockerfile

* Skip `test_register_plugin*` for Debian job
2023-01-24 14:53:00 +04:00
Vitaliy Urusovskij
d5f3bfa43e RGB->Gray C and Py API2.0 (#15050)
* Add RGB to GRAY to C API 2.0

* Add RGB to GRAY to Py API 2.0

* ClangFormat + PyFlake8
2023-01-19 10:51:32 +04:00
Ilya Lavrenov
c4eeecfec5 Remove myriad plugin (#15131)
* Removed Intel MYRIAD plugin

* Removed Intel MYIAD from CI files

* Removed Intel MYRIAD from cmake folder

* Removed MYRIAD, HDDL from samples

* Removed MYRIAD, HDDL from scripts folder

* Removed MYRIAD from bindings folder (C and Python API)

* Removed MYRIAD tests

* Removed MYRIAD from tests folder

* Removed MYRIAD from tools folder

* Removed HDDL (VAD), MYRIAD (NSC2) from documentation

* Fixed build for AUTO unit tests

* Fixed clang code style

* Fixed comments and issues

* removed MYRIAD from AUTO tests

* Disabled MULTI tests in CI

* Update docs/OV_Runtime_UG/auto_device_selection.md

Co-authored-by: Yuan Xu <yuan1.xu@intel.com>

* Update docs/get_started/get_started_demos.md

Co-authored-by: Yuan Xu <yuan1.xu@intel.com>

* Update docs/OV_Runtime_UG/deployment/local-distribution.md

Co-authored-by: Yuan Xu <yuan1.xu@intel.com>

Co-authored-by: Yuan Xu <yuan1.xu@intel.com>
2023-01-18 15:19:44 +04:00
Ilya Churaev
0c9abf43a9 Updated copyright headers (#15124)
* Updated copyright headers

* Revert "Fixed linker warnings in docs snippets on Windows (#15119)"

This reverts commit 372699ec49.
2023-01-16 11:02:17 +04:00
Xuejun Zhai
1910f42179 [C API DOC][DG] C API developer documentation (#13499)
* [C API DOC] add c api docs

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* Update OpenVINO_Runtime_C_API_User_Guide.md

Add mapping relationship about C++ API 2.0 and C API

* [C API][DG] Add some roles for developping C API

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API DOC][DG] Implement the developer guide

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API DOC][DG] Fix comments

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API DOC][DG] Fix format issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DG] Fix review issues including add reference link, clear description

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] Fix review comments

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] remove the mapping relationship of interface & object

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] Fix review comments

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] add descriptions for unit test

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-11-22 10:38:17 +04:00
Xuejun Zhai
0bc67ce1a7 [C API][DOC][PPP] Extend user documentation for new preproprocess api (#14008)
* [C API][DOC] correct the doxy group for ppp

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] improve the C API doc with new PPP interface

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-11-17 19:23:08 +03:00
Xuejun Zhai
2faddf61bf [C API][Preprocess] add more preprocess api (#13770)
* [C API][Preprocess API] Add api reverse_channels(), convert_layout(), crop(), scale(), mean()

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Preprocess API] Add unite test case for api reverse_channels(), convert_layout(), crop(), scale(), mean()

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Preprocess API] code format api reverse_channels(), convert_layout(), crop(), scale(), mean()

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Preprocess API] code format api reverse_channels(), convert_layout(), crop(), scale(), mean()

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Preprocess API] code format

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] clarify code with TEST_F

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] clarify code

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] remove space

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] fix code format issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] fix code format issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][PPP Test Case] fix code format issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-11-14 08:07:56 +04:00
Xuejun Zhai
5f1ce082ea [C API][Unite Test] Add more tests to achieve code coverage target (#13885)
* [C API][Unite Test] Add more unite test case for C API (functional level)

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Unite Test] remove unused function

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][Unite Test] fix function code coverage issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][TEST CASE] fix error

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-11-11 09:20:05 +04:00
Xuejun Zhai
23882408c4 [C API][DOC]add doc capi reference (#13886)
* [Test] Build doc for C API reperence

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [Test] Build doc for C API reperence add C path

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [Test] Build doc for C API reperence add C path

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC][DOXYGEN] refact the components of C API

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [DOC][API reference] remove useless code

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API][DOC] Modify format to generate api reference

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [DOC][API reference] fix doc build error

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-11-09 11:20:32 +04:00
Xuejun Zhai
af5e06bb8b [C API] fix warning as error issue (#13671)
Signed-off-by: Zhai <xuejun.zhai@intel.com>

Signed-off-by: Zhai <xuejun.zhai@intel.com>
2022-10-31 04:57:58 +03:00
Ilya Churaev
2a344b66cb Update to the latest cmake for Windows (#13604)
* Update to the latest cmake for Windows

* Skip new warnings

* Added compiler flags for old cmake

* Disabled some warnings

* Suppress new warnings

* Fixed some errors

* Disable some warning for lpt

* Fix some warnings

* Disable new warnings

* Fix some warnings

* Disabled Was error for arm

* Fixed some errors

* Fixed some new warnings

* Fixed auto plugin

* Fixed Windows warning

* Fixed Windows

* Disable some warnings

* Some changes

* Small test fixes

* Fixed python build

* Added skip warnings for legacy python API
2022-10-25 18:11:46 +04:00
Ilya Churaev
8a9c19e3eb Warning as error for Windows (#13291)
* parent 6e7016ccda
author Ilya Churaev <ilya.churaev@intel.com> 1664281499 +0400
committer Ilya Churaev <ilya.churaev@intel.com> 1664510018 +0400

Fixed warnings on local machine

* Added CMAKE_COMPILE_WARNING_AS_ERROR usage

* Fixed style

* Fixed merge conflicts

* Fixed typo

* Fixed myriad build for macOS

* Fixed warning

* Fixed tests

* Disabled incorrect test

* Try to fix linux tests

* Revert "Try to fix linux tests"

This reverts commit 29224c93ff.

* Fixed tests

* Revert logic with incorrect cast

* Fixed log softmax

* Disable warning as error for cuda

* Try to fix inference_engine_s

* Fixed cmake

* Revert "Fixed cmake"

This reverts commit 87e9e4e674.

* Revert "Try to fix inference_engine_s"

This reverts commit a1adca8b05.

* WA for static symbols in inference_engine_s test library

* Fixed code style

* Fixed static definition for master

* Revert "Fixed static definition for master"

This reverts commit 20d00d215a.

* Revert "Fixed code style"

This reverts commit 0eb2362543.

* Revert "WA for static symbols in inference_engine_s test library"

This reverts commit 75ef86a79d.

* Fixed linker issue for Windows

* Disable WaE by default

* Disable warning as error in the developer package

* Try to fix dev package

* Try to fix Windows Jenkins

* Revert old behavior for tread_warn_as_err variable
2022-10-06 13:44:21 +04:00
River Li
7d7fb11c5f [CAPI] add more test cases for element type (#13265)
* Avoid duplicated code

Change-Id: I86fe59bab13010aedc62a2c92102b00e060ceeec

* Add more test cased for element type

Change-Id: I1f02254cee715d53ede0422c14a4732267d3db27

* Apply INSTANTIATE_TEST_SUITE_P for tensor element type test

Change-Id: I8bbeeb00ae872b7b286b5a776a5c2681e6b5ee94
2022-10-03 08:09:37 +04:00
River Li
371186ee05 Remove unreasonable assert in test cases (#13279)
Change-Id: I5844d674733cb70d31687d4f8e1f353c840daca4
2022-09-29 17:00:47 +03:00
River Li
159a54f07e [CAPI]Fix some potential segment fault in test cases (#13127)
* Fix some potential segmentfault in test cases

Change-Id: Ie12956e32805d950fa1eb82a1e49d532b26bc390

* Use OV_ASSERT_OK to replace OV_EXPECT_OK

Change-Id: I6780072cca4b4a6485105db4832ef3085c990df0

* Fix compile error

Change-Id: Ib4594093ddc60e504e45c6581410fa22d09bd9a6

* Update usage of ASSERT and EXCEPT

Change-Id: I7cb5d0bda4a60a2de899132c47fbf745bc760305

* Use EXPECT by default

Use EXPECT by default, unless you require something to hold for the remainder of the tests.

Change-Id: I2d2d8d8d9632e9e8742c4d923353d319e597a46a

* Avoid the issue of ov::hint::PerformanceMode::UNDEFINED

If convert ov::hint::PerformanceMode::UNDEFINED to string format, the string value is 0 (string_value=0, not "UNDEFINED")
We should avoid to copy this empty string.

Change-Id: I9d4a080b697a863762342f6f890d8ac7434e1864
2022-09-28 23:01:22 +04:00
River Li
9e88e0283d [CAPI]Unicode support (#12985)
* Unicode support

Change-Id: I6da095b0f0b86eb0fa9c44ddb41fa40f82fbded2

* Unicode support load compile model from file and add test cases

Change-Id: Ic66c2b9d5bc7da44db85772fc55abb9a699f4b7d

* Fix build error in Windows

Change-Id: I98c686f5bef17bef63ec6937035fac011224a790

* Fix compile error caused by rebase

Change-Id: I1457ba6bfd6743855bf55d77a2103a558548a8a0

* Fix refefinition issue in Windows

In windows it reports below error:
  include\10.0.18362.0\um\winnt.h(1131): error C2365: 'BOOLEAN': redefinition; previous definition was 'enumerator'
  openvino\src\bindings\c\include\openvino/c/ov_common.h(105): note: see declaration of 'BOOLEAN'

Change-Id: Ic84b7f0d6e3de5ba6c37af39533a3ca2f2d17ad8

* Link ov::util to call unicode code function

Change-Id: Ib324173524b8fe9b7f523fe6b838e155ffbe0842

* rename BL0 to be BOOLEAN

* Boolean should be 8bits data
2022-09-28 05:37:53 +04:00
River Li
ed31a46b7b [CAPI] improve property implement to achieve better compatibility (#12887)
* Solve some code style issues

Change-Id: I06c31ad9513463c758db96dbe33031983a8fd7a5

* Refine ov_dimension with C style structure

Use C style definition to replace opaque C++ handle:
 1). Improve partial shape
 2). Improve dimension/rank
 3). Improve shape

Change-Id: I680fd3e76c63d0c06d9d8b07c67af0440fb15bb7

* Some minor update

Change-Id: I237490a765e6ecd6f3896b1bd75d5f962304f43b

* add partial_shape_is_dynamic and update doc

Change-Id: Ief358f27de8386e35485d08847c8243d1490157f

* Rename property and add basic test cases

Change-Id: Ifbed0bbf7a5e836d2cab186763d7e5f8f2cb7d44

* address reviewer's comments

Change-Id: I9a5d1ede6d086906f3777c3d29237986a505db52

* Fix compile error

Change-Id: I72267a8dda32dd8f43c1ea1522d07b392052358f

* Use ov_any_t to replace ov_property_value_t

Change-Id: Ia4062d0da0941c901990bf5f16497ae3c8f2eb0f

* update doc for ov_model

Change-Id: I80183394f16dd1e07ff998993e26f8b903f2402e

* Property key apply string variables replace enum variable

Change-Id: I0e1699862de3913ccdc06ded5b8f8ac5a2bf8773

* Fix compiling error in windows

Change-Id: I4f9c7c746e218db94491c5f4bc5aeda1b3fde62b

* Change init/deinit method to create/free, remove unnecessary methods

Change-Id: Ibc5de039da94e92db494583ab1ff1a63e0586c73

* Pass by value for single C structure data

Change-Id: I289eb56e2ba1ab90942c8c801c585ab0f792952f

* fix dllexport issue in windows

Change-Id: I1632375e5e651fdfa076cdab2d8d1c3e83986549

* Fix static build error

Change-Id: I6633fe4887edad0b3a8b7e10730fb9d36a6ac0cd

* Use pass by value for all transparent structure

Change-Id: I652f6e70b420ef7c5af5cff3f5d482911cf0d75a

* Unify parameter order in  C APIs, input first and then output parameters

Change-Id: Ib89c77d81c314e3a81bfcec9917630abbc896f5e

* Rename preprocess api to be more readable

Change-Id: I0a8ecd005e73e4ba8e90a8f25bedf0739fe31836

* Simplfy property implement for set and get property

Change-Id: Icad41606368cef9520b1623f6207784c295f1b9f

* check string type property issue

Change-Id: Ie8ee6995dda401f1db0cc098e061ffcfd24de92a

* Fix memory leak

Change-Id: Ife8980736be320314eca6fb3f3605e019663e1da

* Check string property data

Change-Id: I542a136ff874cb345c67f7d3c1dbc74981a909df

* Fix issues caused by rebase

Change-Id: I3d675a16cf76980a6414e369a83464a46dec1e49

* Remove some redundant code

Change-Id: Iab6bf7f355ec7a7424d884e620319ed9db80ecf5

* Remove property type from interface

ov_core_set_property will have 2 cases:

1) enum type:  <const char* property_key, ov_property_xxx_e property_value>
2) other: <const char* property_key, const char* property_value>

Change-Id: Id7dec1ac40948d45c4f8baee687652aee92ea75d

* Remove redundant code

Change-Id: I66865d3313e305b0109cb63bd049772a01c0688f

* Remove exception log and update propery size argument

Change-Id: Ia1a60c07c9adf08d175d94a7d5e4298adb27bf80

* Apply string for enum property

Change-Id: I591b1db453a52b5ea9000e0cc3e11edf0ef5f790

* Add test case for MULTI_DEVICE_PRIORITIES

Change-Id: I59e4307564a2560724b4dacdb83c3ed45ea1ce8d

* Fix test issues and add more negative test case

Change-Id: Ib849fb8c098e487a537c1b1ab881f5e905871f73
2022-09-20 15:59:27 +03:00
Xuejun Zhai
c8e62fddb2 [C API] add more descriptions about ov_model & ov_compiled_model (#13061)
Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
2022-09-16 15:23:30 +03:00
RICKIE777
77906042f3 [CAPI]Extend Model API (#12617)
* Add ov_model_output_by tensor name and index function

* Fix the clang format issue

* clang format

* Add ov_output_node_t in input and shape function

* Add ov_oputput_node_t in model_output function

* Fix clang-format

* change ov_output_node_list_t to ov_output_const_node_list_t

* Add ov_output_node_list_t new struct

* Rename oputput_node to be port

* Rename output_node to be port in CAPI test and samples

* Add ov_model_output/outputs/input/inputs function and testcases

* Rename output_ports to ports

* Chage ov_node_list_get_element_type_by_index to ov_node_list_get_element_type

* Change ov_output_node to ov_output_port

* Delete node list and modify the function that used the node list structure before

* Fix clang-format in ov_infer_request_test.cpp

* change node to port in funcation name

* Rebase new master

* Add new API in compile model and model,such as get input/output size

* Add err info in hello_classification_c

* Fix clang-format in hello_classification_c

* Merge the new infer_request

* Initialize ov_output_const_port

* Change the location of initialization

Co-authored-by: River Li <river.li@intel.com>
2022-09-15 07:37:23 +04:00
Xuejun Zhai
349f3e02e0 [C API] Add more C API for infer request (#12636)
* [C API] Add more C API for infer request

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [Code Style] Fix code style issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* Fix review comments

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API] add more details desc for infer request interfaces

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API] Modify the structure of tensor list

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API] Fix code style issue

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* [C API] remove define about tensor list

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>

* Update documents for infer request

Change-Id: I1acbae95425cfe4aad85da48d290bafe5bb7d319

* Update documents for ov_infer_request

Change-Id: Ib68530c49cf439c7b570ee63bd3ee8ea85018d51

Signed-off-by: xuejun <Xuejun.Zhai@intel.com>
Co-authored-by: River,Li <river.li@intel.com>
2022-09-09 10:47:46 +03:00
RICKIE777
f780303e5a Fix the memory issue in ov_core_read_model_from_memory (#12817) 2022-09-07 10:06:31 +04:00