Commit Graph
725 Commits
Author SHA1 Message Date
Przemyslaw Wysocki dddc85f68f Add lower bound to sympy (#21127) 2023-11-20 10:17:47 +01:00
Przemyslaw WysockiandKarol Blaszczak 2c3535355d [PyOV] Add torchvision to OpenVINO preprocessing converter docs (#20770)
Co-authored-by: Karol Blaszczak <karol.blaszczak@intel.com>
2023-11-15 15:25:36 +01:00
Pawel Raasz c974c9a478 Remove limit for Loop inputs in bindings (#21055) 2023-11-14 11:18:40 +01:00
dependabot[bot] 03a1ba1f81 Bump pytest-html from 3.2.0 to 4.1.1 in /src/bindings/python (#20948)
Bumps [pytest-html](https://github.com/pytest-dev/pytest-html) from 3.2.0 to 4.1.1.
- [Release notes](https://github.com/pytest-dev/pytest-html/releases)
- [Changelog](https://github.com/pytest-dev/pytest-html/blob/master/docs/changelog.rst)
- [Commits](https://github.com/pytest-dev/pytest-html/compare/v3.2.0...4.1.1)

---
updated-dependencies:
- dependency-name: pytest-html
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-11-13 17:43:45 +04:00
Maciej Smyk 5a04359200 [DOCS] Updating links for master 2023-11-13 12:23:23 +01:00
Jan Iwaszkiewicz 6650b8750a [PyOV] Support Tensor creation from empty numpy arrays (#20964) 2023-11-13 11:25:58 +01:00
Jan Iwaszkiewicz 212a9bc852 [PyOV] Support Constant creation from empty numpy arrays (#20967)
* [PyOV] Support Constant creation from empty numpy arrays

* Return 0 when shape is 0

* Add missing file...
2023-11-13 10:11:12 +00:00
854158612f Scaled dot product attention (#20492)
* Added experimental ScaledDotProductAttention operation in opset12. Supported in PT FE for aten::scaled_dot_product_attention translation. Decomposed in the common optimizations as functional reference.

* Better ScaledDotProductAttention

- Moved decomposition to the decomposing transformation
- Implemented more ctors for the op
- Renamed is_causal to causal
- Shape/type inference native code instead of using decomposition
- Moved the op from opset12 to opset13
- Added Python wrapper for ScaledDotProductAttention

* Fix test that counts ops in the opsets

* Update src/core/src/op/scaled_dot_product_attention.cpp

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>

* Update src/core/src/op/scaled_dot_product_attention.cpp

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>

* Move ScaledDotProductAttentionDecomposition from fusions to decompositions.

* Remove not used legacy shape inference in ScaledDotProductAttention

* Better namespace usage

* Register all nodes in ScaledDotProductDecomposition for correct tracking of nodes and running next mather passes on all new nodes.

* Don't use register_new_node_

* ScaledDotProductAttention specification (with an extra scale argument)

* Code style fix

* Scale input implementation for ScaledDotProductAttention

* Handle attention_mask=0 case in the op spec

* Better description of scale input

* N->M in scale description

* Code style fix, remove debug print.

* Apply suggestions from code review

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>
Co-authored-by: Mateusz Mikolajczyk <mateusz.mikolajczyk@intel.com>

* Fix for case when is_causal is not passed

* Extended description of ScaledDotProduct op

* Better description in py op wrapper

* Basic shape propagation tests for ScaledDotProductAttention

* Added ScaledDotProductAttention to toc.

* Add op impl check

---------

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>
Co-authored-by: Mateusz Mikolajczyk <mateusz.mikolajczyk@intel.com>
2023-11-08 20:17:13 +01:00
LiuandMichal Lukaszewski 9e7243d67c fix typo (#20906)
Co-authored-by: Michal Lukaszewski <michal.lukaszewski@intel.com>
2023-11-08 13:10:11 +04:00
Ilya Lavrenov d6cc3d7058 Disable warnings about API 1.0 in GNA, Python API 1.0 (#20933) 2023-11-08 12:45:22 +04:00
a0849edca1 [CPU] migrate cpu plugin api 2.0 (#18124)
* [CPU] CPU plugin migrates to plugin API 2.0

* Fix legacy config/metric issue

* Fix some issue of ov_cpu_func_tests

1. set_tensors_impl segment fault
2. ov::loaded_from_cache unsupported issue

* Resolve some comments

1. ov::loaded_from_cache issue
2. throw_if_cancelled issue
3. import_model issue
4. set_tensor_impl issue
5. batched_inference issue

* Fix dynamic shape inference issue

* Fix build error

* keep original model info in infer_request

* Fix minor error

* cache internal tensors for input/output precision change

* Disable import model test cases with precision changes

* fix precision issue

* Fix issue for import model

* Fix InferRequestCancellationTests exception issue

* Skip InferRequestIOBBlobTest.*secondCallGetInputDoNotReAllocateData due to new plugin api have different behavior

* Fix graph name issue

* Fix ROI issues

* Fix Transpose shape issue

* Skip vie::Version test due to change to ov::Version

* Solve input port name changes issue

* Solve preprocess layout issue

* Fix minor issue

* tidy up code

* Fix conflict after rebase

* Fix Windows build warning

* Add aux tensors for precision change issue

* Fix import/export model issue

* WA single layer name changed by preprocess

* Revert "WA single layer name changed by preprocess"

This reverts commit bc8fcdd43c.

* Skip some legacy tests due to plugin api 2.0 is enabled

1. skip some python legacy tests for plugin api 2.0 some different behaviors
2. skip some smoke tests due to output port name was changed

* Fix 2 build warnings

* Skip some AUTO plugin tests

* Fix property issue caused by AUTO plugin

* Skip PSROIPooling issues

* Follow header files reference policy

* Split out transformation fixing for nop_elimination

* Fix AUTO plugin mismatch issue for get_tensor function

* Fix aux tensor shape issue

* Fix tensor shape issue

* WA python sync inference sample's segmentfault issue

* Fix reshape issue for dynamic inference

* Fixed incorrect tensor name in e2e test

Fixe issue: e2e ONNX_Customized_Cascade_Rcnn_api_2_True_batch_1_device_CPU_precision_FP325den8cnk

* Fix python segmentfault issue of plugin api 2.0

* Fix python segmentfault issue of plugin api 2.0

* Revert "Fix python segmentfault issue of plugin api 2.0"

This reverts commit 6f502e5d86.

* Fix onnx_duplicated_output_name due to empty tensor

Co-authored-by: Bell, Song <bell.song@intel.com>

* Remove redundant code

* Remove python segment fault WA

* Keep rt_info to fix test failure in case of legacy public api

* Fix output port names missing issue

* Adress some reviewers' comments

* Restore OnnxBackendNodeModelTest::test_maxpool_with_argmax_2d_precomputed_pads_cpu after fixing has been merged

* Resolve tensor sharing issue when there are same name output port name

In some case, model has 2 or more same name input/output ports, they aslo have the same
precision and partial_shape. Compiled_model will share the same ov::Descriptor::Tensor pointer
and ov::Tensor between multiple such ports.
Considered solving python segment fault issue to create seperated input/output ports, which also
need handle such tensor shared case, this patch will do it.

* Resolve tensor sharing issue when there are same name output port name

In some case, model has 2 or more same name input/output ports, they aslo have the same
precision and partial_shape. Compiled_model will share the same ov::Descriptor::Tensor pointer
and ov::Tensor between multiple such ports.
Considered solving python segment fault issue to create seperated input/output ports, which also
need handle such tensor shared case, this patch will do it.

* Better method to find shrared tensor desc

* rename with snake_case style

* Remove ngraph header files

* Keep external_ptr naming

* Add OPENVINO_SUPPRESS_DEPRECATED for some legacy code

* Use port's tensor_ptr to replace creating new tensor_ptr

* Resolve some reviewer comments

* Implement ov::IInferRequestInternalWrapper::GetPreProcess to recover python GetPrepProcess tests

* Remove unnecessary header files reference

* Assert the risk of precision change and reorder at the same time

* Modify legacy python test to fit plugin api 2.0 behavior

* Recover smoke_Transpose(2|4|5|6)D/TransposeLayerTest.CompareWithRefs due to fixing is merged

* Fix typo issue

* Address reviewer's comments

* Disable precision coversion

* Fix error when CpuBlockedMemoryDesc

* Remove precision mismatch WA

* WA precision issue for query_model

* Solve precision mismatch between compiled model and graph

* Fixe failure of query_model

* Rebase to new plugin api update

* Recover the test cases of precision mismatch

* Try to fix name changing for graph model

* Remove tets code

* Remove fp64

* Rebase to new plugin api update

* Update for some failure cases

* Fix bert_benchmark failure issue

* Avoid segment fault in arm acl

Legacy public api + cpu plugin api will add convert op by preprocess by default for unsupported precision,
but ACLConvertExecutor cannot support dimension > 6, so this test will be segment fault due to dimension > 6

smoke_TestNumpyBroadcastNgraphEvaluate/BroadcastLayerTest.CompareWithRefs/targetShape=(1.2.3.4.5.6.7.8.9.10)_axesMapping=()_mode=numpy_inShape=(1.2.1.4.1.6.1.8.1.10)_inNPrec=I8_trgDev=CPU
smoke_TestNumpyBroadcastNgraphEvaluate/BroadcastLayerTest.CompareWithRefs/targetShape=(1.2.3.4.5.6.7.8.9.10)_axesMapping=()_mode=numpy_inShape=(1.2.1.4.1.6.1.8.1.10)_inNPrec=U8_trgDev=CPU

* Remove precision change from preprocess to avoid ACL unsupport convert dim > 6

* ACLConvertExecutor cannot support dimension > 6, don't let preprocess to add Convert

* Revert "ACLConvertExecutor cannot support dimension > 6, don't let preprocess to add Convert"

This reverts commit fd7a8b35af.

* Revert "Remove precision change from preprocess to avoid ACL unsupport convert dim > 6"

This reverts commit 3c2d9a5f17.

* Debug

* Debug incorrect precision checking issue

* Debug Eltwise FP64 unsupported issue

* Add logs for precision

* debug log

* Update for new dependent PRs merged

* Fix failure caused by preprocess

Fix below failures due to cannot find ops by name
     smoke_LPT/ReduceMaxTransformation.CompareWithRefImpl/f32_[1,3,10,10]_CPU_f32__256*

* Fix build error

* Fix failure caused by missing code during rebase

* Add debug

* Fix precision unsupport issue

* U16/I16/U64 precision support

* Resolve the issue of f64 reorder

Fix below issue:
Cannot create reorder primitive: unsupported reorder case

* Fix convert multiple child edge issue

* Solve ROI tensor failure issues

* Temporarily disable num_nodes comparison

* Only change convert precision for fp64

* Put convert precision change before reorder to avoid confusion

* Add debug log for transformation

* Fix rebase confilict

* Fix clang issue

* Temporarily disable test_infer_mixed_values python test of bf16

* Solve issue of smoke_ConvertCPULayerTest_BOOL_Dynamic_inputPRC=BF16 choose FP32 primType rather than BP16 primType

* Fix issue of pytorch_tests/test_outer.py

There are 2 output ports, but with the same port name, they should share the same tensor.

* Fix arm cannot find Eltwise executor issue

smoke_SetBlobCPU/SetBlobTest.CompareWithRefs/Type=INPUT_Device=CPU_PrecisionInNet=FP16_PrecisionInNgraph=BOOL
will report below error:
	 [ GENERAL_ERROR ] Supported Eltwise executor is not found
It need change convert precision to avoid such problem.

* Fix memory overwritten issue

* Temporarily skip arm fp16 SetBlobTest

* Fix compile error after rebase

* Restore smoke_IsOp test due to fixing pr merged

* Fix float to bf16 issue in avx2 isa

* solve onnx test xfail issue

* Skip test cases that ARM Eltwise executor FP16 is not supported

smoke_SetBlobCPU/SetBlobTest.CompareWithRefs/Type=INPUT_Device=CPU_PrecisionInNet=FP16_PrecisionInNgraph=BOOL
smoke_SetBlobCPU/SetBlobTest.CompareWithRefs/Type=BOTH_Device=CPU_PrecisionInNet=FP16_PrecisionInNgraph=BOOL

      [ GENERAL_ERROR ] Supported Eltwise executor is not found

* [CPU] improve reorder to support any precision

* Implement ReorderExecutor

* Fix builld error

* Not cache executor due to its primitive has been cached

* Keep convert one time at most

At most insert one convert if needed, if still cannot do reorder it will throw exception rather than insert the second convert
For example, below reorder will not be supported:
   FP64<->I64/U64/U32
   U32<->I64/U64
   U32<->I16/U16
   FP64<->FP64
   BIN<->BIN

* Only do conversion if layout is same

* update for only convert case

* Update for reviewer comments

* update for failure cases

* Address reviewer comments

* Update rebase issue

* minor update

* Solve unsupported precision issue in tranfromation rather than init_edge

* Remove unnecessary convert in init_edge

* Minor changes

* Update Reorder::reorderData

* Solve issue if only coversion without reorder

* Address reviewer comments

* Address reviewer comments

* Keep exception for unsuported precision

* update

* Revert reorder executor implement

* Solve float->bool issue on transformation pipeline

* Solve I64 is not supported issues

* Solve reviewer's comments

* Fixed dynamic top_k node issue

* Skip nhwc and nChw16c test cases for ConvertLayer

* Update for reviewers' comments

* Fix some failures

* Update for several failure cases

* Update for apiConformanceTests failures

* Fix incorrect node name after import model

* update

* update comments

* Solve issue of smoke_MatMul_NoTranspose and smoke_MatMul_BothTranspose

* Fixed AlignMatMulInputRanks scalar issue

* Address reviewers' comments, remove redundant path in graph.cpp

* Remove test_div_uint8_cpu from xfail_issue_58676

* Solve invalid number of nodes for smoke_Snippets_BroadcastSelect

* ConstantResultSubgraphTest of u16/i16/u32/i64/u64

* restore smoke_SetBlobCPU BOOL tests for arm

* [CPU] Fix ARM precision issue

ARM64 ACL prefers fp16 than fp32, API 2.0 requires input/output precision not changes,
then fp32 input will trigger convert node is added to convert fp32 to fp16.

* Solve some ARM64 failures

* Fix arm64 InferRequestVariableStateTest tests out of memory issue

ARM64 will force fp16 precision, which cause states memory can be fp16, so memcpy to state_memory
cannot use float * element_size, else it will be out of memory bound.

* Skip 2 arm64 tests caused by forcing fp16 precision

* Revert "Fix arm64 InferRequestVariableStateTest tests out of memory issue"

This reverts commit 3e12bd48c2.

* Fix python test_get_profiling_info failure issue

---------

Co-authored-by: Bell, Song <bell.song@intel.com>
Co-authored-by: Chen Peter <peter.chen@intel.com>
2023-11-07 15:25:05 +01:00
Anastasia KuporosovaandRoman Kazantsev 4a0098b26a [PyOV] ngraph linter check update (#20870)
* [PyOV] ngraph linter check update

* Update src/bindings/python/requirements_test.txt

Co-authored-by: Roman Kazantsev <roman.kazantsev@intel.com>

---------

Co-authored-by: Roman Kazantsev <roman.kazantsev@intel.com>
2023-11-07 10:42:46 +00:00
Anastasiia Pnevskaia cc389c23ca Removed logic of building example_input by shape. (#20859) 2023-11-03 20:45:34 +04:00
Alina Kladieva 86c638a595 Temporarily restrict flake8_builtins version (#20864) 2023-11-03 16:59:47 +01:00
Surya Siddharth Pemmaraju bb0e4f8ecf Fixed issue with cat in fx backend (#20744)
* Added fix for cat in torchfx

* Added batch_norm_legit_no_training op

* Fixed coding style

* Fixed clang format

* Addressed PR comments
2023-11-01 08:36:19 +01:00
Przemyslaw Wysocki 31f6a95122 [PyOV] Set inference precision explicitly to fp32 for torchvision tests (#20713)
* Set fp32

* Fix flake

* use properties api
2023-10-30 20:06:55 +01:00
Anastasia Kuporosova 5b583276b2 [PyOV] Add get_byte_size to const node (#20759) 2023-10-30 19:46:07 +01:00
Ekaterina Aidova c21fd2ea61 [PT FE]: fix object has no attribute 'dtype' (#20755)
* [PT FE]: fix  object has no attribute 'dtype'

* add model in tests

* update test
2023-10-30 18:36:08 +00:00
Maxim Vafin 7b9db3d81b [PT FE] Add torch.int16 dtype support (#20735)
* Add torch.int16 dtype support

* Add test
2023-10-30 10:12:55 +01:00
Katarzyna Mitrus 14d51de93c [ONNX] Add support for standard ONNX GroupNormalization (#20694)
* Add support for ONNX GroupNormalization

* Enable onnx compliance tests

* Add f to the test values to avoid cast warning

* Use tolerance as fp instead of bits
2023-10-27 09:24:07 +04:00
Anastasia Kuporosova 3b9606f217 [PyOV] fix set_node_friendly_name (#20695) 2023-10-26 14:35:57 +02:00
Ilya Lavrenovanddependabot[bot] 0d458f086d Dependabot/pip/src/bindings/python/paddlepaddle 2.5.2 (#20708)
* Bump paddlepaddle from 2.5.1 to 2.5.2 in /src/bindings/python

Bumps [paddlepaddle](https://github.com/paddlepaddle/paddle) from 2.5.1 to 2.5.2.
- [Release notes](https://github.com/paddlepaddle/paddle/releases)
- [Changelog](https://github.com/PaddlePaddle/Paddle/blob/develop/RELEASE.md)
- [Commits](https://github.com/paddlepaddle/paddle/compare/v2.5.1...v2.5.2)

---
updated-dependencies:
- dependency-name: paddlepaddle
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

* Removed WA for Ubuntu 22.04 and PDPD

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-26 14:06:34 +04:00
Mikhail Ryzhov 49c5099f5e [GHA] Removed dependency on git repo in python tests (#20390)
* Removed repo deps in py tests

* fixed typo

* changed test cmd

* add test_utils to pythonpath

* set test_utils to LD_LIBRARY_PATH

* changed path

* changed path

* source python site-packages

* fixed LD_LIBRARY_PATH

* print pip dir

* changed python install path

* source all openvino dir

* isolate test_utils

* system deps

* reordered deps

* dep conflict

* tests reorder

* changed test_utils path

* cpack test dir

* rebase fix

* fixed env

* frontend tests fix

* removed already installed reqs

* debug

* debug 2

* added python action path

* test

* reset 3rdparties

* set pip install path globally

* reset 3rdparties

* removed parallel code

* moved doc snippets

* switched back 4-core runner

* removed global unused vars

* removed unused requirements.txt

* removed unused requirements

* test

* Revert "test"

This reverts commit bdf22d22fd6ec5d488930bc362bdb0741c5bea76.
2023-10-25 20:16:01 +00:00
Ilya Churaev 7ceff55b71 Add AlignedBuffer to OpenVINO developer API (#20532)
* Add AlignedBuffer to OpenVINO developer API

* Fixed build

* Fixed code style and remove opset deprecation

* Fixed Windows build

* Fixed GNA

* Fixed comment
2023-10-24 06:13:23 +00:00
Maxim Vafin 8d0381b0fe [PT FE] Implement custom op for types alignment (#20431)
* [PT FE] Implement custom op for types alignment

* Fix code style

* Fix inplace ops

* Fix layer tests

* Remove no longer needed change

* Fix ovc tests

* Fix fe tests
2023-10-23 22:54:08 +02:00
Andrey KashchikhinandIlya Lavrenov b67cff7cd5 [CI] [GHA] Introduce macOS ARM64 as a matrix parameter in the macOS pipeline (#20363)
* add m1 mac pipelines as a matrix parameter

* Update mac.yml

disable java_api because of macos arm64 - Java is not available on macOS arm64 runners

* Update mac.yml

added always condition for all tests

* Update mac.yml

* Update mac.yml

* Update mac.yml

* Update setup.py

temp commit

* Update tools/openvino_dev/setup.py

* use matrix for var

* add mxnet to extras only for x86_64

* skip failing tests

* use xfail for Python tests; add missing filter for transformations tests

* skip CPU func tests on x86_64 mac; skip some tests from CPU func tests on arm mac

* Update mac.yml

* skip tests on mac arm

* skip tests on darwin; apply review

* add more skips for python and c++ tests

* skip tf tests

* skip more tf tests; skip more Python UT stages

* rm alwayses, rm triggers, add nightly trigger

---------

Co-authored-by: Ilya Lavrenov <ilya.lavrenov@intel.com>
2023-10-23 15:06:22 +04:00
Lucas Alava PeñaandJan Iwaszkiewicz fc93262d7c fix typo in opset3 shuffle_channels docstring (#20158)
Co-authored-by: Jan Iwaszkiewicz <jan.iwaszkiewicz@intel.com>
2023-10-20 15:00:50 +04:00
Mateusz MikolajczykandMaxim Vafin 891f79ac84 [PT FE] Add aten::as_strided (#19482)
* Add aten::as_strided

* rm commented code

* Update src/frontends/pytorch/src/op/as_strided.cpp

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Update src/frontends/pytorch/src/op/as_strided.cpp

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Fix CI error

* Fix CI issues

* mark_node for remaining constants

* Add test reproducing issue

* Use strides from torchscript

* Add led model to test suite

* Add sugested changes

---------

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>
2023-10-20 14:24:10 +04:00
Mustafa CavusandMaxim Vafin 3d5fe8d446 Llm and sd additional ops (#20435)
* TorchFX: New ops added (baddbbmm, leaky_relu_)

* TorchFX: Initial scaled_dot_product_flash_attention

* Code Formatting: scaled_fot_product_attention translation

* TorchFX unit test enabled for SDPA

* Typo fix in comment line

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

---------

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>
2023-10-19 21:21:28 +04:00
Mustafa CavusandJan Iwaszkiewicz 5018be82c3 TorchFX: Constant value pass without copy (#20380)
* TorchFX: Constant value pass optimization

* Replace op.Constant with make_constant in fx_decoder

* Using shared memory for constant value passing

Co-authored-by: Jan Iwaszkiewicz <jan.iwaszkiewicz@intel.com>

---------

Co-authored-by: Jan Iwaszkiewicz <jan.iwaszkiewicz@intel.com>
2023-10-19 19:35:10 +04:00
Anastasiia PnevskaiaandAndrey Kashchikhin be177021b0 Switching telemetry to opt-out and disabling telemetry in CI jobs (#20391)
* Added disabling telemetry script to linux azure job, added debug checks to convert_model.

* Telemetry disabling.

* Disabling telemetry.

* Config corrections.

* Config corrections.

* Update .github/workflows/mac.yml

Co-authored-by: Andrey Kashchikhin <andrey.kashchikhin@intel.com>

* Debug output.

* Win config correction.

* Win config correction.

* Debug output.

* Debug output.

* Added turning off telemetry to onnx azure tests config.

* Corrected config.

* Removed debug output.

* Switch telemetry to opt-out.

* Removed not needed blank lines.

* Text correction.

* Debug output.

* Remove changes from CI configs, add CI var to dockers.

* Config correction.

* Debug output.

* Config corrected.

* Readme corrected.

* Config changed.

* Config changed.

* Debug output.

* Required version changed.

* Remove debug output.

---------

Co-authored-by: Andrey Kashchikhin <andrey.kashchikhin@intel.com>
2023-10-19 15:26:21 +04:00
46935e0a00 Partial GPTQ int4 models conversion support + Swap nibbles in u4/i4 element type (#20371)
* Reference implementation for u4 constant compression from pytorch model based on bitwise ops pattern

* Fixed order of 4-bit halfs in byte

* Switched PyTorch FE to dev mode: in case if model cannot be fully converted, give partially converted model with PTFrameworkNode's with a printed warning (normally would raise an exception in case).

* Moved u4 compression to utils_quantize. Implemented not-interleaved version of u4 compression

* Removed debug output

* Added aten::matmul to the list of exceptions in may_produce_alias as a workaround for gptq models

* Added patching for gptq models applied automatically in convert_model

* WA for an inssue with u4 with earlier convert to fp16

* U4 blocked repacking for gptq patched model layout

* Deleted obsolete u4 re-packing based on aten::cat. Fixed the resulting u4 constant shape. Removed debug output.

* Revert "Switched PyTorch FE to dev mode: in case if model cannot be fully converted, give partially converted model with PTFrameworkNode's with a printed warning (normally would raise an exception in case)."

This reverts commit 0ef1455e70.

* Update src/frontends/pytorch/src/op/cat.cpp

* Check mask and shift values in u4 pattern. deque -> OutputVector for u4_compression_stack

* Convert to a given floating type instead of half in gptq patching. Better structured code.

* Code style fix

* Removed deque include

* Code style fixes

* Trailing space removed

* Fixed patched_forward and ts_decoder after unvalidated commits.

* Swap nibbles in u4/i4

* Better exception handling around jit.trace and gptq.patch_model

* Update src/bindings/python/src/openvino/frontend/pytorch/gptq.py

Co-authored-by: Alexander Kozlov <alexander.kozlov@intel.com>

* Update src/bindings/python/src/openvino/frontend/pytorch/gptq.py

Co-authored-by: Alexander Kozlov <alexander.kozlov@intel.com>

* Code style

* Revers int4 byte order

* Fixed core tests

* Fixed unguarded dynamic_cast result

Co-authored-by: Evgenya Nugmanova <eva.my.link@gmail.com>

* Fixed transformation tests

* Update src/bindings/python/src/openvino/frontend/pytorch/gptq.py

Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>

* Prevent patching of non-gptq models

* Removed extra calling of quantized weights decompression patterns

* Better detection of supported AutoGPTQ models + more diagnostics

* Accurate diagnostics in case when aten::stack has multiple axes

---------

Co-authored-by: Alexander Kozlov <alexander.kozlov@intel.com>
Co-authored-by: Ilya Churaev <ilyachur@gmail.com>
Co-authored-by: Evgenya Nugmanova <eva.my.link@gmail.com>
Co-authored-by: Maxim Vafin <maxim.vafin@intel.com>
2023-10-18 21:06:17 +04:00
Ilya Lavrenov 00618a429b Relocatable OpenVINO Dev package improvements (#20461) 2023-10-16 12:54:30 +04:00
dependabot[bot] 6f6017724f Bump pytest-timeout from 2.1.0 to 2.2.0 in /src/bindings/python (#20310)
Bumps [pytest-timeout](https://github.com/pytest-dev/pytest-timeout) from 2.1.0 to 2.2.0.
- [Commits](https://github.com/pytest-dev/pytest-timeout/compare/2.1.0...2.2.0)

---
updated-dependencies:
- dependency-name: pytest-timeout
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-15 03:14:14 +04:00
Ilya Lavrenov 0b78a388be Removed custom python usage in Azure pipelines (#20433)
* Removed custom python usage

* Removed custom python usage
2023-10-14 01:18:27 +04:00
Katarzyna Mitrus 2478cf7df3 [Opset13][pyAPI] Python API Multinomial-13 (#20400)
* Init Multinomial op python API

* Add python tests for Multinomial op

* Update num_samples input description
2023-10-13 10:50:02 +00:00
Ilya Lavrenov 56d74a82cb Relocatable developer package (#20327)
* Merge Linux CC + static build + clang compiler

* Improvements

* Removed ie prefixes from cmake scripts

* Fixes for NPU

* Initial relocatable OpenVINO Developer package

* Improvements

* Try to fix

* improvements

* Export a lot of headers

* Removed NVIDIA pipeline; make it to be a job

* Fixes

* Fixes 2

* Try ilya-lavrenov repo

* Clean-up

* More imrpovements

* Even more improvements

* Override export, install

* Override export, install

* Disable pythonwheel generation for relocatable OV dev package

* Fixed issues with versions

* Fixed android build

* Fixed android build

* Fixed NPU build

* Update src/bindings/python/CMakeLists.txt
2023-10-12 22:59:04 +00:00
Ilya Lavrenov d41e7fcc30 Revert "[CI] [GHA] Skip test_div_uint8_cpu on macOS only; unskip test_onnx/test_backend.py in GHA workflows (#20367)" (#20402)
This reverts commit a3d6d0bca9.
2023-10-12 03:00:14 +04:00
Roman Kazantsev 0bb6450398 [TF FE] Support TF 2.14 and add OnesLike translator (#20385)
* [TF FE] Support TF 2.14 and add OnesLike translator

Signed-off-by: Kazantsev, Roman <roman.kazantsev@intel.com>

* Update tests constraints

* Update open_model_zoo

* Adopt TF Lite test to 2.14 TF

Signed-off-by: Kazantsev, Roman <roman.kazantsev@intel.com>

* Support TF Lite layer tests for diffrent TF versions

---------

Signed-off-by: Kazantsev, Roman <roman.kazantsev@intel.com>
2023-10-11 15:24:32 +04:00
Andrey KashchikhinandIlya Lavrenov a3d6d0bca9 [CI] [GHA] Skip test_div_uint8_cpu on macOS only; unskip test_onnx/test_backend.py in GHA workflows (#20367)
* only skip test if mac

* unskip

* unskip trigger

* skip for onnx fe as well

* do not skip

* return skips and unskip test_backend in Python API 1.0

* rm pr trigger

---------

Co-authored-by: Ilya Lavrenov <ilya.lavrenov@intel.com>
2023-10-11 14:05:12 +04:00
Jan IwaszkiewiczandMichal Lukaszewski 6a326455b9 [PyOV] Propagate errors on imports from runtime module (#20273)
Co-authored-by: Michal Lukaszewski <michal.lukaszewski@intel.com>
2023-10-11 11:53:34 +04:00
Ilya Lavrenov 0a0d0f0aa5 Revert "Switch telemetry to opt-out approach. (#20290)" (#20370)
This reverts commit b630bffa14.
2023-10-10 22:08:20 +04:00
Andrey Kashchikhin 0060b26b74 [CI] [GHA] [Azure] Unskip test_div_uint8_cpu, unskip src/frontends/onnx/tests/test_python/test_zoo_models.py in Win and Linux pipelines (#20366)
* only skip test if mac

* unskip

* skip for onnx fe as well

* remove skips

* rm unused imports

* revert import
2023-10-10 21:06:18 +04:00
Mateusz MikolajczykandKatarzyna Mitrus 670fff062e [Opset13][pyAPI] Python API BitwiseNot-13 (#20265)
* Add pyAPI BitwiseNot-13

* Update src/bindings/python/src/openvino/runtime/opset13/ops.py

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>

* Remove whitespace from ops.py

---------

Co-authored-by: Katarzyna Mitrus <katarzyna.mitrus@intel.com>
2023-10-10 14:27:45 +02:00
Andrey KashchikhinandIlya Lavrenov 1454e77bbf [CI] [GHA] Introduce GHA macOS Pipeline (#20212)
* start transferring

* start with samples

* start with initial two stages

* change name

* skip pytorch tests; rm unused comments

* rm setupvars sourcing; make test steps similar to those in linux pipeline

* add missing options and setupvars sourcing

* add skips for mac

* install wheels directly

* add deployment target

* add skips for pytorch layer tests; experiment with samples

* do not exclude files for archives; set rpath

* apply comments; rm unnecessary stages

* Update mac.yml

fixed MO Python API tests

* Update .github/workflows/mac.yml

* Update openvino.cmake

add LC_RPATH to libopenvino.dylib

* Update src/cmake/openvino.cmake

* Update CMakeLists.txt

reverted changes in samples build

* Update openvino.cmake

removed rpath changes

* add setupvars

* disable pr trigger

---------

Co-authored-by: Ilya Lavrenov <ilya.lavrenov@intel.com>
2023-10-10 14:43:09 +04:00
Anastasiia Pnevskaia b630bffa14 Switch telemetry to opt-out approach. (#20290)
* Switch telemetry to opt-out approach.

* Minor correction.

* Small correction.
2023-10-10 13:14:45 +04:00
Mateusz Tabaka 4a3ce48f7a CompressQuantizeWeights optimizations (#20025)
* Optimize CompressQuantizeWeights transformation

- remove CoordinateTransform usage from FakeQuantize reference implementation
- move ZeroPointOptimizer functionality inside CompressQuantizeWeights
- compute scale and zero point in the same loop

Ticket: CVS-119273

* review comments

* clang format

* fix comments
2023-10-10 13:10:05 +04:00
Mateusz Mikolajczyk ef0c10df6c [Opset13][pyAPI] Python API binary BitwiseAnd-13, BitwiseOr-13, BitwiseXor-13 (#20261)
* add xor

* Add and and or

* Add ch srequested in review
2023-10-10 09:04:06 +02:00
Maxim Vafin d07b2ccc5f [PT FE] Return dynamic shape when static shape exist in graph (#20289) 2023-10-10 07:59:46 +02:00
Ilya Lavrenov e30f75bb4d Rpath story (#20297) 2023-10-10 06:27:26 +02:00