Skip to content

Commit 5277791

Browse files
committed
Merge remote-tracking branch 'upstream/master' into CVS-163062_CVS-163051
Signed-off-by: Evgeniia Nugmanova <evgeniia.nugmanova@intel.com>
2 parents ab23914 + ff64a7d commit 5277791

File tree

87 files changed

+1232
-677
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

87 files changed

+1232
-677
lines changed

.github/actions/common/constants.py

+2
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ class EventType(Enum):
1919
'public_windows_vs2022_release',
2020
'public_windows_vs2022_debug',
2121
'public_manylinux2014_x86_64_release',
22+
'public_macos_x86_64_release',
2223
)
2324
ProductType = Enum('ProductType', {t.upper(): t for t in productTypes})
2425

@@ -44,4 +45,5 @@ class EventType(Enum):
4445
PlatformKey.UBUNTU22_X86_64: ProductType.PUBLIC_LINUX_UBUNTU_22_04_X86_64_RELEASE,
4546
PlatformKey.UBUNTU24_X86_64: ProductType.PUBLIC_LINUX_UBUNTU_24_04_X86_64_RELEASE,
4647
PlatformKey.WINDOWS_X86_64: ProductType.PUBLIC_WINDOWS_VS2022_RELEASE,
48+
PlatformKey.MACOS_12_6_X86_64: ProductType.PUBLIC_MACOS_X86_64_RELEASE,
4749
}

.github/workflows/build_doc.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
packages: graphviz texlive liblua5.2-0 libclang1-9 libclang-cpp9
3131
version: 3.0
3232

33-
- uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
33+
- uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
3434
id: cp310
3535
with:
3636
python-version: '3.10'

.github/workflows/coverage.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020

2121
steps:
2222
- name: Setup python
23-
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
23+
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
2424
with:
2525
python-version: '3.10.10'
2626
architecture: 'x64'

.github/workflows/job_gpu_tests.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
DEBIAN_FRONTEND: noninteractive # to prevent apt-get from waiting user input
7575
TZ: "Europe/London" # to prevent tzdata from waiting user input
7676
- name: Setup Python ${{ env.PYTHON_VERSION }}
77-
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
77+
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
7878
with:
7979
python-version: ${{ env.PYTHON_VERSION }}
8080

.github/workflows/mac.yml

+108-11
Original file line numberDiff line numberDiff line change
@@ -33,12 +33,16 @@ permissions: read-all
3333

3434
env:
3535
PYTHON_VERSION: '3.11'
36+
MANIFEST_FILE: manifest.yml
37+
PRODUCT_TYPE: public_macos_x86_64_release
3638

3739
jobs:
40+
3841
Smart_CI:
3942
runs-on: ubuntu-latest
4043
outputs:
4144
affected_components: "${{ steps.smart_ci.outputs.affected_components }}"
45+
changed_components: "${{ steps.smart_ci.outputs.changed_components }}"
4246
skip_workflow: "${{ steps.smart_ci.outputs.skip_workflow }}"
4347
steps:
4448
- name: checkout action
@@ -59,7 +63,7 @@ jobs:
5963
repo_token: ${{ secrets.GITHUB_TOKEN }}
6064
skip_when_only_listed_labels_set: 'docs'
6165
skip_when_only_listed_files_changed: '*.md,*.rst,*.png,*.jpg,*.svg'
62-
66+
6367
Build:
6468
needs: Smart_CI
6569
timeout-minutes: 150
@@ -78,6 +82,7 @@ jobs:
7882
INSTALL_DIR: ${{ github.workspace }}/openvino_install
7983
INSTALL_DIR_JS: ${{ github.workspace }}/openvino_install/js
8084
INSTALL_TEST_DIR: ${{ github.workspace }}/tests_install
85+
DEVELOPER_PACKAGE_DIR: ${{ github.workspace }}/developer_package_install
8186
INSTALL_WHEELS_DIR: ${{ github.workspace }}/install/wheels
8287
BUILD_DIR: ${{ github.workspace }}/build
8388
if: "!needs.smart_ci.outputs.skip_workflow"
@@ -171,17 +176,22 @@ jobs:
171176

172177
- name: Cmake install - OpenVINO
173178
run: |
174-
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -P ${{ env.BUILD_DIR }}/cmake_install.cmake
175-
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_TEST_DIR }} -DCOMPONENT=tests -P ${{ env.BUILD_DIR }}/cmake_install.cmake
179+
cmake --install . --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_DIR }}
180+
cmake --install . --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.INSTALL_TEST_DIR }} --component tests
181+
cmake --install . --config ${{ env.CMAKE_BUILD_TYPE }} --prefix ${{ env.DEVELOPER_PACKAGE_DIR }} --component developer_package
182+
working-directory: ${{ env.BUILD_DIR }}
176183

177-
- name: Pack Artifacts
178-
run: |
179-
pushd ${{ env.INSTALL_DIR }}
180-
tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/openvino_package.tar.gz
181-
popd
182-
pushd ${{ env.INSTALL_TEST_DIR }}
183-
tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/openvino_tests.tar.gz
184-
popd
184+
- name: Pack openvino_package
185+
run: tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/openvino_package.tar.gz
186+
working-directory: ${{ env.INSTALL_DIR }}
187+
188+
- name: Pack openvino_developer_package
189+
run: tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/openvino_developer_package.tar.gz
190+
working-directory: ${{ env.DEVELOPER_PACKAGE_DIR }}
191+
192+
- name: Pack openvino_tests
193+
run: tar -cvf - * | pigz > ${{ env.BUILD_DIR }}/openvino_tests.tar.gz
194+
working-directory: ${{ env.INSTALL_TEST_DIR }}
185195

186196
# Setup additional Python versions for wheels building
187197
- name: Setup Python 3.9
@@ -225,6 +235,18 @@ jobs:
225235
should-setup-pip-paths: 'false'
226236
self-hosted-runner: 'false'
227237

238+
- name: Generate product manifest and set CI_BUILD_NUMBER & CI_BUILD_DEV_TAG
239+
id: create_manifest
240+
uses: ./openvino/.github/actions/create_manifest
241+
with:
242+
repos: |
243+
${{ env.OPENVINO_REPO }}
244+
${{ env.OPENVINO_CONTRIB_REPO }}
245+
product_type: ${{ env.PRODUCT_TYPE }}
246+
target_arch: ${{ runner.arch }}
247+
build_type: 'release'
248+
save_to: ${{ github.workspace }}/${{ env.MANIFEST_FILE }}
249+
228250
- name: Cmake & Build - OpenVINO Contrib
229251
run: |
230252
cmake \
@@ -275,13 +297,30 @@ jobs:
275297
name: openvino_tests
276298
path: ${{ env.BUILD_DIR }}/openvino_tests.tar.gz
277299
if-no-files-found: 'error'
300+
301+
- name: Upload openvino developer package
302+
if: ${{ always() }}
303+
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
304+
with:
305+
name: openvino_developer_package
306+
path: ${{ env.BUILD_DIR }}/openvino_developer_package.tar.gz
307+
if-no-files-found: 'error'
308+
278309
- name: Upload openvino js package
279310
if: fromJSON(needs.smart_ci.outputs.affected_components).JS_API
280311
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
281312
with:
282313
name: openvino_js_package
283314
path: ${{ env.BUILD_DIR }}/openvino_js_package.tar.gz
284315
if-no-files-found: 'error'
316+
317+
- name: Upload product manifest
318+
if: ${{ always() }}
319+
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
320+
with:
321+
name: openvino_package_manifest
322+
path: ${{ github.workspace }}/${{ env.MANIFEST_FILE }}
323+
if-no-files-found: 'error'
285324

286325
Samples:
287326
needs: [ Build, Smart_CI ]
@@ -377,3 +416,61 @@ jobs:
377416
with:
378417
runner: 'macos-13'
379418
python-version: '3.11'
419+
420+
upload_artifacts:
421+
name: Upload OpenVINO artifacts
422+
timeout-minutes: 10
423+
needs: [Build, Smart_CI]
424+
defaults:
425+
run:
426+
shell: bash
427+
runs-on: aks-linux-2-cores-8gb
428+
container:
429+
image: 'openvinogithubactions.azurecr.io/library/python:3.12-slim'
430+
volumes:
431+
- /mount:/mount
432+
- ${{ github.workspace }}:${{ github.workspace }}
433+
env:
434+
OPENVINO_REPO: ${{ github.workspace }}/openvino
435+
OPENVINO_CONTRIB_REPO: ${{ github.workspace }}/openvino_contrib
436+
ARTIFACTS_DIR: ${{ github.workspace }}/artifacts
437+
WHEELS_DIR: ${{ github.workspace }}/wheels
438+
ARTIFACTS_SHARE: "/mount/build-artifacts"
439+
440+
steps:
441+
- name: Checkout OpenVINO actions
442+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
443+
timeout-minutes: 15
444+
with:
445+
sparse-checkout: |
446+
.github/actions/common
447+
.github/actions/store_artifacts
448+
path: ${{ env.OPENVINO_REPO }}
449+
450+
- name: Download OpenVINO artifacts
451+
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
452+
with:
453+
pattern: "{openvino_package,openvino_developer_package,openvino_js_package,openvino_package_manifest}"
454+
path: ${{ env.ARTIFACTS_DIR }}
455+
merge-multiple: true
456+
457+
- name: Download OpenVINO wheels
458+
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
459+
with:
460+
name: openvino_wheels
461+
path: ${{ env.WHEELS_DIR }}
462+
merge-multiple: true
463+
464+
- name: Store artifacts to a shared drive
465+
id: store_artifacts
466+
if: ${{ always() }}
467+
uses: ./openvino/.github/actions/store_artifacts
468+
with:
469+
artifacts: |
470+
${{ env.ARTIFACTS_DIR }}/${{ env.MANIFEST_FILE }}
471+
${{ env.ARTIFACTS_DIR }}/openvino_package.tar.gz
472+
${{ env.ARTIFACTS_DIR }}/openvino_developer_package.tar.gz
473+
${{ env.WHEELS_DIR }}
474+
${{ fromJSON(needs.smart_ci.outputs.affected_components).JS_API && format('{0}/openvino_js_package.tar.gz', env.ARTIFACTS_DIR) || '' }}
475+
storage_dir: ${{ env.PRODUCT_TYPE }}
476+
storage_root: ${{ env.ARTIFACTS_SHARE }}

.github/workflows/ovc.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ jobs:
2323
timeout-minutes: 15
2424

2525
- name: Setup Python
26-
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
26+
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
2727
with:
2828
python-version: '3.10'
2929

.github/workflows/py_checks.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
timeout-minutes: 15
3333

3434
- name: Setup Python
35-
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
35+
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
3636
with:
3737
python-version: '3.9'
3838

src/bindings/python/tests/test_runtime/test_async_infer_request.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ class ArrayLikeObject:
223223
def __init__(self, array) -> None:
224224
self.data = array
225225

226-
def __array__(self):
226+
def __array__(self, dtype=None, copy=None):
227227
return self.data
228228

229229
jobs = 8
@@ -364,7 +364,7 @@ class ArrayLikeObject:
364364
def __init__(self, array) -> None:
365365
self.data = array
366366

367-
def __array__(self):
367+
def __array__(self, dtype=None, copy=None):
368368
return np.array(self.data)
369369

370370
_, request, _, input_data = generate_abs_compiled_model_with_data(device, Type.f32, np.single)

src/bindings/python/tests/test_runtime/test_sync_infer_request.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,7 @@ class ArrayLikeObject:
563563
def __init__(self, array) -> None:
564564
self.data = array
565565

566-
def __array__(self):
566+
def __array__(self, dtype=None, copy=None):
567567
return np.array(self.data)
568568

569569
_, request, _, input_data = generate_abs_compiled_model_with_data(device, Type.f32, np.single)

src/bindings/python/tests/test_utils/test_data_dispatch.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ class FakeTensor():
195195
def __init__(self, array):
196196
self.array = array
197197

198-
def __array__(self):
198+
def __array__(self, dtype=None, copy=None):
199199
return self.array
200200

201201

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
// Copyright (C) 2018-2025 Intel Corporation
2+
// SPDX-License-Identifier: Apache-2.0
3+
//
4+
5+
#pragma once
6+
7+
#include "openvino/core/type/element_type.hpp"
8+
#include "openvino/pass/graph_rewrite.hpp"
9+
#include "transformations_visibility.hpp"
10+
11+
namespace ov {
12+
namespace pass {
13+
class TRANSFORMATIONS_API ConvertPagedAttnInputs;
14+
15+
/**
16+
* @ingroup ov_transformation_common_api
17+
* @brief Set precision and shape of KV cache in PagedAttn op based runtime options
18+
*/
19+
20+
class ConvertPagedAttnInputs : public ov::pass::MatcherPass {
21+
public:
22+
struct KVCacheConfig {
23+
ov::element::Type keyCachePrecision;
24+
ov::element::Type valueCachePrecision;
25+
ov::element::Type inferencePrecision;
26+
size_t keyCacheBlockSize = 32;
27+
size_t valueCacheBlockSize = 32;
28+
size_t keyCacheGroupSize = 0;
29+
size_t valueCacheGroupSize = 0;
30+
bool keyCacheQuantBychannel = false;
31+
bool valueCacheQuantBychannel = false;
32+
std::vector<size_t> keyCacheDimOrder = {0, 1, 2, 3};
33+
std::vector<size_t> valueCacheDimOrder = {0, 1, 2, 3};
34+
};
35+
36+
OPENVINO_MATCHER_PASS_RTTI("ConvertPagedAttnInputs");
37+
ConvertPagedAttnInputs(const KVCacheConfig& config);
38+
39+
void setKVCacheConfig(const KVCacheConfig& config);
40+
41+
const KVCacheConfig& getKVCacheConfig() const;
42+
43+
private:
44+
KVCacheConfig m_config;
45+
};
46+
47+
} // namespace pass
48+
} // namespace ov

0 commit comments

Comments
 (0)