Commit Graph

701 Commits

Author SHA1 Message Date
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 Kashchikhin 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ña 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 Mikolajczyk 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 Cavus 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 Cavus 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 Pnevskaia 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
Sergey Lyalin 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 Kashchikhin 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 Iwaszkiewicz 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 Mikolajczyk 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 Kashchikhin 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
Ilya Lavrenov ead4b8a0ec
Moved cmake functions, variables to API 2.0 naming style (#20281)
* Merge Linux CC + static build + clang compiler

* Improvements

* Removed ie prefixes from cmake scripts

* Fixes for NPU
2023-10-09 22:30:32 +04:00
Ilya Lavrenov 5764b5c108
Use RPATH instead of RUNPATH for wheel package (#20239) 2023-10-06 13:50:44 +04:00
Ilya Churaev 7c847cecba
Remove ngraph namespace from operations without evaluate (#20252)
* Remove ngraph namespace from operations without namespace

* Try to fix build

* Additional fixes

* More fixes

* More fixs

* Fix reverse op

* Fixed tests

* Throw an exception if somebody tries to reallocate tensor

* Revert "Throw an exception if somebody tries to reallocate tensor"

This reverts commit 8e06d6d576.

* Remove python test

* Revert "Remove python test"

This reverts commit 37b12148d3.

* Changed evaluate model behavior
2023-10-06 12:54:11 +04:00
Przemyslaw Wysocki 9fe6be21ea
[PyOV] Drop Python 3.7 in OpenVINO Runtime (#19534)
* Drop 37

* Fix linter

* Minor change

* Minor changes

* update add_lib_path

* Minor changes

* Update pypi pages

* Update pypi pages

* Fix linter

* Minor changes

---------

Co-authored-by: Anastasia Kuporosova <anastasia.kuporosova@intel.com>
Co-authored-by: Jan Iwaszkiewicz <jan.iwaszkiewicz@intel.com>
Co-authored-by: Ilya Lavrenov <ilya.lavrenov@intel.com>
2023-10-06 08:28:27 +00:00
Mikhail Ryzhov a79c07b3a0
[GA] Enable win workflow (#19646)
* Enable win workflow and cpu parallel tests

* removed test code

* update cache naming

* extended logs collections

* Revert "extended logs collections"

This reverts commit 0dd6620832.

* revert lost code during the merge

* missed dependencies

* enabled push trigger

* changed the cache key name

* skipped failed test

* fixed github action condition and added comments

* Update src/core/tests/check.cpp

* cache generation fix

* Apply suggestions from code review

* fixed python test configuration

* Revert "cache generation fix"

This reverts commit 0feab650fe.

* debug parallel tests

* Revert "Revert "cache generation fix""

This reverts commit e385b04410.

* Revert "debug parallel tests"

This reverts commit e4459472a7.

* fixed steps conditions

* concurrency updated

* fixed test skip condition on win

* review changes

* collect debug logs

* overwrite test list

* debug commit

* Revert "debug commit"

This reverts commit 8720b87c8f.
2023-10-05 16:49:39 +04:00
Katarzyna Mitrus bdb13aa28d
[Opset13][pyAPI] Python API opset13 init and NMSRotated-13 (#20204)
* Opset13 init

* Update py API to use Opset13

* Add nms_rotated op to py API

* Add tests

* Add trailng comma

* Adjust blank spaces

* Add nms_rotated to init file

* Update tests

* Update style

* Adjust Optional keyword

* Update op docs with shapes

* Add Tensor rypes hints

* Update tests to import opset13
2023-10-04 17:05:29 +02:00
Ilya Lavrenov 749ed9dec7
Added python search path for Conda (#19929) 2023-10-03 22:47:52 +04:00
Ilya Lavrenov 95e3096684
Added build on RedHat system to build & test RPM packages (#20134)
* Added GHA workflow for RPM packages

* Avoid rebuild for RPM / Debian packages

* Removed conditional include headers

* try only post-build

* Beautification

* Fixed testdata generation for mulit-config generators
2023-10-01 23:23:06 +04:00
andreyanufr b73b2502b1
Introduce NF4 data type (#19900)
* NF4 reference initial commit

* Compilable version.

* Executable NF4.

* Fixed nf4 unpacking.

* 1) Fixed warnings with nf4.
2) Removed unused functions.

* Added one test for nf4.

* Fixed code-style errors.

* Fixed code-style errors.

* Fixed NamingConventionCheck errors.

* Fixed test with nf4.

* Fixed windows compilation.

* Fixed casting warning.

* Fixed incorrect changes.

* Changed order of elements in nf4 pack/unpack.

* 1) Made Convert only on direction nf4->other type.
2) Applied reviewers suggestions.

* Fixed code style.

* Fised code style.

* 1) Added array header.
2) Added Bitsandbytes to third-party-programs.txt.

* 1) Removed unused code.
2) Fixed style typos.
3) Revert submodule version.

* Added test for nf4 compression.

* NF4 test refactoring.

* Added cpp tests for NF4.

* Removed model compilation from NF4 tests.

* Reverted submodule version.
2023-09-28 20:56:57 +04:00
Anastasia Kuporosova 744f5d4130
[PyOV] Fix docs and add test for Model._get_raw_address (#20109) 2023-09-28 12:06:20 +00:00
Anastasia Kuporosova c90bcbf5eb
[PyOV] fix if_op return types (#20014)
* [PyOV] fix if_op return types

* fix if

* other types

* test for if

* add tests, try fix loop, ti

* fix ci
2023-09-28 09:35:54 +02:00
Ilya Lavrenov 132bada331
Enable PDPD tests build (#20078)
* Fixed comments for linux-riscv64 GHA workflow

* Try to enable PDPD tests back
2023-09-27 18:03:02 +04:00
Sonder 5079c50bb8
Update the regular syntax in cmakelist (#20066) 2023-09-27 12:26:17 +04:00
Anastasia Kuporosova 9dfed28aed
[PyOV] Make openvino properties behave as python property object (#20007)
* properties as property

* working prototype

* another attempt

* fix for test

* cosmetic changes

* generate properties

* test upste

* add comments

* update submodules

* apply comments
2023-09-26 21:38:53 +02:00
Ilya Lavrenov 8349849e1c
Use FindPython3.cmake (#19847)
* Use FindPython3.cmake

* Fixed compilation on macOS 14 with new core development tools

* Try to use Python3_SOABI instead of PYTHON_MODULE_EXTENSION

* Use Development.Module

* Keep specifying only Python3_EXECUTABLE

* Print PYTHON_MODULE_EXTENSION

* Added check for minimal cmake version for python API

* Returned Python3_INCLUDE_DIR for cross-compilation case

* Try to allow cmake older than 3.18

* Use build python interpreter to check cython dependency

* revert changes in .ci/openvino-onnx/Dockerfile

* removed unused code

* Fixed issue with variables scope

* Experiment: remove include dirs

* Corrected docs

* Use pybind11 function to set extension

* Revert "Experiment: remove include dirs"

This reverts commit 6f7f90211c.

* Refactor ConvolutionBackpropDataLayerTest, ConvolutionLayerTest, DeformableConvolutionLayerTest (#19810)

* Refactor ConvolutionBackpropDataLayerTest

* Refactor ConvolutionLayerTest

* Refactor DeformableConvolutionLayerTest

* Apply comments

* Apply comments

* Fix

* Updated minimum cmake version for Windows

* Simplified check

* Removed useless message status

* Use puiblic option

---------

Co-authored-by: Oleg Pipikin <oleg.pipikin@intel.com>
2023-09-26 20:57:29 +02:00
Mahimai Raja J 39f6cbf259
Refactored with single dispatch generic function implementation (#19958)
* Refactored with single dispatch generic function implementation

* Resolved mypy linting warnings

* Update src/bindings/python/src/openvino/preprocess/torchvision/torchvision_preprocessing.py

* Update src/bindings/python/src/openvino/preprocess/torchvision/torchvision_preprocessing.py

---------

Co-authored-by: Przemyslaw Wysocki <przemyslaw.wysocki@intel.com>
2023-09-25 16:32:22 +04:00
Katarzyna Mitrus 37271c1e7c
[Opset13][CPP] Initialization of Opset13 (#20005)
* Opset13 init

* Update test pattern ops

* Update remaining files
2023-09-25 10:20:37 +02:00
Pavel Esir 9271b79540
[OVC] do not parse inputs for py_api (#19742)
* [OVC] do not parse inputs

* fix unit-tests

* remove redundant lines, add test case

* add one more unit-test

* skip None values

* replace str with List in test_mo_import_from_memory

* corrected type hints, added a safety assert
2023-09-22 15:05:21 +04:00
Siddhant Chauhan d6d4e3deeb
Align openvino.compile_model and openvino.Core.compile_model functions (#19778)
Co-Authored-By: Anastasia Kuporosova <anastasia.kuporosova@intel.com>
2023-09-21 11:15:30 +00:00
Ilya Lavrenov c67c0663fc
Use target python packages (#19928) 2023-09-20 11:16:15 +04:00
Anastasia Kuporosova b3ee79520f
[PyOV][Docs] Add docs for if-op (#19899)
* [PyOV][Docs] Add docs for if-op

* code style

* add rtypes

* add dots
2023-09-19 21:35:38 +00:00
Anastasiia Pnevskaia 215a2f435b
tf.Graph decoder accuracy fixes (#19903)
* Fixed outputs passing from decoder.

* Fixed get_variable method.

* Code style.

* Removed xfails from precommit models.

* Minor fix.

* Comment fixed.

* Added test.
2023-09-19 19:04:24 +02:00
dependabot[bot] 475ad32cc4
Update numpy requirement in /src/bindings/python (#19897)
Updates the requirements on [numpy](https://github.com/numpy/numpy) to permit the latest version.
- [Release notes](https://github.com/numpy/numpy/releases)
- [Changelog](https://github.com/numpy/numpy/blob/main/doc/RELEASE_WALKTHROUGH.rst)
- [Commits](https://github.com/numpy/numpy/compare/v1.16.6...v1.26.0)

---
updated-dependencies:
- dependency-name: numpy
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-09-19 11:19:35 +04:00
Przemyslaw Wysocki e34c5a09c6
[PyOV] Add an `__init__.py` alignment check in CMake (#19882)
* Add init check

* Apply CR
2023-09-19 00:36:13 +04:00