Skip to content

Commit 351ffc8

Browse files
committed
only source files
1 parent 46398c4 commit 351ffc8

Some content is hidden

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

71 files changed

+796
-770
lines changed

.github/workflows/mac.yml

+168-168
Original file line numberDiff line numberDiff line change
@@ -1,168 +1,168 @@
1-
name: macOS (Python 3.11)
2-
on:
3-
workflow_dispatch:
4-
pull_request:
5-
push:
6-
branches:
7-
- master
8-
- 'releases/**'
9-
10-
concurrency:
11-
# github.ref is not unique in post-commit
12-
group: ${{ github.event_name == 'push' && github.run_id || github.ref }}-mac-main
13-
cancel-in-progress: true
14-
15-
env:
16-
PYTHON_VERSION: '3.11'
17-
OV_BRANCH: ${{ github.base_ref || github.event.merge_group.base_ref || github.ref }}
18-
19-
permissions: read-all
20-
21-
jobs:
22-
Build_and_test:
23-
name: Build and Test
24-
timeout-minutes: 150
25-
defaults:
26-
run:
27-
shell: bash
28-
runs-on: 'macos-13-large'
29-
env:
30-
CMAKE_BUILD_TYPE: 'Release'
31-
MACOSX_DEPLOYMENT_TARGET: '11.0'
32-
OSX_ARCHITECTURES: 'x86_64'
33-
CMAKE_CXX_COMPILER_LAUNCHER: ccache
34-
CMAKE_C_COMPILER_LAUNCHER: ccache
35-
OPENVINO_REPO: ${{ github.workspace }}/openvino
36-
OPENVINO_CONTRIB_REPO: ${{ github.workspace }}/openvino_contrib
37-
TEST_DATA: ${{ github.workspace }}/testdata
38-
INSTALL_DIR: ${{ github.workspace }}/openvino_install
39-
INSTALL_DIR_JS: ${{ github.workspace }}/openvino_install/js
40-
INSTALL_TEST_DIR: ${{ github.workspace }}/tests_install
41-
BUILD_DIR: ${{ github.workspace }}/build
42-
CCACHE_DIR: ${{ github.workspace }}/ccache
43-
CCACHE_MAXSIZE: '2G'
44-
GRADLE_VER: '7.1.1'
45-
steps:
46-
- name: Clone OpenVINO
47-
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
48-
with:
49-
repository: 'openvinotoolkit/openvino'
50-
path: 'openvino'
51-
submodules: 'true'
52-
ref: ${{ env.OV_BRANCH}}
53-
54-
- name: Clone OpenVINO Contrib
55-
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
56-
with:
57-
path: 'openvino_contrib'
58-
59-
- name: Clone Testdata
60-
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
61-
with:
62-
repository: 'openvinotoolkit/testdata'
63-
path: 'testdata'
64-
lfs: 'true'
65-
submodules: 'true'
66-
67-
#
68-
# Dependencies
69-
#
70-
71-
- name: Install build dependencies
72-
run: brew install coreutils ninja scons automake gradle ccache
73-
74-
- name: Setup Python ${{ env.PYTHON_VERSION }}
75-
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
76-
with:
77-
python-version: ${{ env.PYTHON_VERSION }}
78-
79-
- name: Install python dependencies
80-
run: python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/wheel/requirements-dev.txt
81-
82-
#
83-
# Build
84-
#
85-
86-
- name: Setup ccache
87-
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
88-
with:
89-
# Should save cache only if run in the master branch of the base repo
90-
# github.ref_name is 'ref/PR_#' in case of the PR, and 'branch_name' when executed on push
91-
save-always: ${{ github.ref_name == 'master' && 'true' || 'false' }}
92-
path: ${{ env.CCACHE_DIR }}
93-
key: ${{ runner.os }}-${{ runner.arch }}-ccache-${{ github.sha }}
94-
restore-keys: |
95-
${{ runner.os }}-${{ runner.arch }}-ccache
96-
97-
- name: CMake configure
98-
run: |
99-
cmake \
100-
-GNinja \
101-
-DCMAKE_VERBOSE_MAKEFILE=ON \
102-
-DCMAKE_BUILD_TYPE=${{ env.CMAKE_BUILD_TYPE }} \
103-
-DBUILD_nvidia_plugin=OFF \
104-
-DOPENVINO_EXTRA_MODULES=${{ env.OPENVINO_CONTRIB_REPO }}/modules \
105-
-DCMAKE_OSX_DEPLOYMENT_TARGET=${{ env.MACOSX_DEPLOYMENT_TARGET }} \
106-
-DCMAKE_OSX_ARCHITECTURES=${{ env.OSX_ARCHITECTURES }} \
107-
-DCMAKE_CXX_COMPILER_LAUNCHER=${{ env.CMAKE_CXX_COMPILER_LAUNCHER }} \
108-
-DCMAKE_C_COMPILER_LAUNCHER=${{ env.CMAKE_C_COMPILER_LAUNCHER }} \
109-
-DENABLE_OV_PADDLE_FRONTEND=OFF \
110-
-DENABLE_OV_TF_FRONTEND=OFF \
111-
-DENABLE_OV_TF_LITE_FRONTEND=OFF \
112-
-DENABLE_OV_PYTORCH_FRONTEND=OFF \
113-
-DENABLE_CPPLINT=OFF \
114-
-DENABLE_INTEL_NPU=OFF \
115-
-S ${{ env.OPENVINO_REPO }} \
116-
-B ${{ env.BUILD_DIR }}
117-
118-
- name: Cmake build
119-
run: cmake --build ${{ env.BUILD_DIR }} --parallel
120-
121-
- name: Show ccache stats
122-
run: ccache --show-stats
123-
124-
- name: Cmake install
125-
run: |
126-
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -P ${{ env.BUILD_DIR }}/cmake_install.cmake
127-
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCOMPONENT=python_wheels -P ${{ env.BUILD_DIR }}/cmake_install.cmake
128-
129-
- name: Java tests
130-
working-directory: ${{ env.OPENVINO_CONTRIB_REPO }}/modules/java_api
131-
run: |
132-
. ${{ env.INSTALL_DIR }}/setupvars.sh gradle clean build --info
133-
134-
for d in CPU HETERO:CPU; do
135-
gradle test -Prun_tests -DMODELS_PATH=${{ env.TEST_DATA }} -Ddevice=$d --info;
136-
done
137-
138-
- name: Check wheel installation
139-
run: |
140-
source ${{ env.INSTALL_DIR }}/setupvars.sh
141-
python3 -m pip install -r ${{ env.OPENVINO_CONTRIB_REPO }}/modules/custom_operations/tests/requirements.txt
142-
143-
pushd ${{ env.INSTALL_DIR }}/wheels
144-
wheel_name=$(find . -name 'openvino-*.whl')
145-
python3 -m pip install $wheel_name
146-
popd
147-
148-
- name: Upload Test Results
149-
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
150-
if: ${{ !cancelled() }}
151-
with:
152-
name: test-results-java
153-
path: ${{ env.OPENVINO_CONTRIB_REPO }}/modules/java_api/build/test-results
154-
if-no-files-found: 'warn'
155-
156-
Overall_Status:
157-
name: ci/gha_overall_status_mac
158-
needs: [ Build_and_test ]
159-
if: ${{ always() }}
160-
runs-on: ubuntu-latest
161-
steps:
162-
- name: Check status of all jobs
163-
if: >-
164-
${{
165-
contains(needs.*.result, 'failure') ||
166-
contains(needs.*.result, 'cancelled')
167-
}}
168-
run: exit 1
1+
name: macOS (Python 3.11)
2+
on:
3+
workflow_dispatch:
4+
pull_request:
5+
push:
6+
branches:
7+
- master
8+
- 'releases/**'
9+
10+
concurrency:
11+
# github.ref is not unique in post-commit
12+
group: ${{ github.event_name == 'push' && github.run_id || github.ref }}-mac-main
13+
cancel-in-progress: true
14+
15+
env:
16+
PYTHON_VERSION: '3.11'
17+
OV_BRANCH: ${{ github.base_ref || github.event.merge_group.base_ref || github.ref }}
18+
19+
permissions: read-all
20+
21+
jobs:
22+
Build_and_test:
23+
name: Build and Test
24+
timeout-minutes: 150
25+
defaults:
26+
run:
27+
shell: bash
28+
runs-on: 'macos-13-large'
29+
env:
30+
CMAKE_BUILD_TYPE: 'Release'
31+
MACOSX_DEPLOYMENT_TARGET: '11.0'
32+
OSX_ARCHITECTURES: 'x86_64'
33+
CMAKE_CXX_COMPILER_LAUNCHER: ccache
34+
CMAKE_C_COMPILER_LAUNCHER: ccache
35+
OPENVINO_REPO: ${{ github.workspace }}/openvino
36+
OPENVINO_CONTRIB_REPO: ${{ github.workspace }}/openvino_contrib
37+
TEST_DATA: ${{ github.workspace }}/testdata
38+
INSTALL_DIR: ${{ github.workspace }}/openvino_install
39+
INSTALL_DIR_JS: ${{ github.workspace }}/openvino_install/js
40+
INSTALL_TEST_DIR: ${{ github.workspace }}/tests_install
41+
BUILD_DIR: ${{ github.workspace }}/build
42+
CCACHE_DIR: ${{ github.workspace }}/ccache
43+
CCACHE_MAXSIZE: '2G'
44+
GRADLE_VER: '7.1.1'
45+
steps:
46+
- name: Clone OpenVINO
47+
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
48+
with:
49+
repository: 'openvinotoolkit/openvino'
50+
path: 'openvino'
51+
submodules: 'true'
52+
ref: ${{ env.OV_BRANCH}}
53+
54+
- name: Clone OpenVINO Contrib
55+
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
56+
with:
57+
path: 'openvino_contrib'
58+
59+
- name: Clone Testdata
60+
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6
61+
with:
62+
repository: 'openvinotoolkit/testdata'
63+
path: 'testdata'
64+
lfs: 'true'
65+
submodules: 'true'
66+
67+
#
68+
# Dependencies
69+
#
70+
71+
- name: Install build dependencies
72+
run: brew install coreutils ninja scons automake gradle ccache
73+
74+
- name: Setup Python ${{ env.PYTHON_VERSION }}
75+
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
76+
with:
77+
python-version: ${{ env.PYTHON_VERSION }}
78+
79+
- name: Install python dependencies
80+
run: python3 -m pip install -r ${{ env.OPENVINO_REPO }}/src/bindings/python/wheel/requirements-dev.txt
81+
82+
#
83+
# Build
84+
#
85+
86+
- name: Setup ccache
87+
uses: actions/cache@0c45773b623bea8c8e75f6c82b208c3cf94ea4f9 # v4.0.2
88+
with:
89+
# Should save cache only if run in the master branch of the base repo
90+
# github.ref_name is 'ref/PR_#' in case of the PR, and 'branch_name' when executed on push
91+
save-always: ${{ github.ref_name == 'master' && 'true' || 'false' }}
92+
path: ${{ env.CCACHE_DIR }}
93+
key: ${{ runner.os }}-${{ runner.arch }}-ccache-${{ github.sha }}
94+
restore-keys: |
95+
${{ runner.os }}-${{ runner.arch }}-ccache
96+
97+
- name: CMake configure
98+
run: |
99+
cmake \
100+
-GNinja \
101+
-DCMAKE_VERBOSE_MAKEFILE=ON \
102+
-DCMAKE_BUILD_TYPE=${{ env.CMAKE_BUILD_TYPE }} \
103+
-DBUILD_nvidia_plugin=OFF \
104+
-DOPENVINO_EXTRA_MODULES=${{ env.OPENVINO_CONTRIB_REPO }}/modules \
105+
-DCMAKE_OSX_DEPLOYMENT_TARGET=${{ env.MACOSX_DEPLOYMENT_TARGET }} \
106+
-DCMAKE_OSX_ARCHITECTURES=${{ env.OSX_ARCHITECTURES }} \
107+
-DCMAKE_CXX_COMPILER_LAUNCHER=${{ env.CMAKE_CXX_COMPILER_LAUNCHER }} \
108+
-DCMAKE_C_COMPILER_LAUNCHER=${{ env.CMAKE_C_COMPILER_LAUNCHER }} \
109+
-DENABLE_OV_PADDLE_FRONTEND=OFF \
110+
-DENABLE_OV_TF_FRONTEND=OFF \
111+
-DENABLE_OV_TF_LITE_FRONTEND=OFF \
112+
-DENABLE_OV_PYTORCH_FRONTEND=OFF \
113+
-DENABLE_CPPLINT=OFF \
114+
-DENABLE_INTEL_NPU=OFF \
115+
-S ${{ env.OPENVINO_REPO }} \
116+
-B ${{ env.BUILD_DIR }}
117+
118+
- name: Cmake build
119+
run: cmake --build ${{ env.BUILD_DIR }} --parallel
120+
121+
- name: Show ccache stats
122+
run: ccache --show-stats
123+
124+
- name: Cmake install
125+
run: |
126+
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -P ${{ env.BUILD_DIR }}/cmake_install.cmake
127+
cmake -DCMAKE_INSTALL_PREFIX=${{ env.INSTALL_DIR }} -DCOMPONENT=python_wheels -P ${{ env.BUILD_DIR }}/cmake_install.cmake
128+
129+
- name: Java tests
130+
working-directory: ${{ env.OPENVINO_CONTRIB_REPO }}/modules/java_api
131+
run: |
132+
. ${{ env.INSTALL_DIR }}/setupvars.sh gradle clean build --info
133+
134+
for d in CPU HETERO:CPU; do
135+
gradle test -Prun_tests -DMODELS_PATH=${{ env.TEST_DATA }} -Ddevice=$d --info;
136+
done
137+
138+
- name: Check wheel installation
139+
run: |
140+
source ${{ env.INSTALL_DIR }}/setupvars.sh
141+
python3 -m pip install -r ${{ env.OPENVINO_CONTRIB_REPO }}/modules/custom_operations/tests/requirements.txt
142+
143+
pushd ${{ env.INSTALL_DIR }}/wheels
144+
wheel_name=$(find . -name 'openvino-*.whl')
145+
python3 -m pip install $wheel_name
146+
popd
147+
148+
- name: Upload Test Results
149+
uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
150+
if: ${{ !cancelled() }}
151+
with:
152+
name: test-results-java
153+
path: ${{ env.OPENVINO_CONTRIB_REPO }}/modules/java_api/build/test-results
154+
if-no-files-found: 'warn'
155+
156+
Overall_Status:
157+
name: ci/gha_overall_status_mac
158+
needs: [ Build_and_test ]
159+
if: ${{ always() }}
160+
runs-on: ubuntu-latest
161+
steps:
162+
- name: Check status of all jobs
163+
if: >-
164+
${{
165+
contains(needs.*.result, 'failure') ||
166+
contains(needs.*.result, 'cancelled')
167+
}}
168+
run: exit 1

0 commit comments

Comments
 (0)