-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into copy_unroll_sdpa_to_npuw_llm_comp_model
- Loading branch information
Showing
16 changed files
with
210 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,133 @@ | ||
name: JAX Layer Tests | ||
|
||
on: | ||
workflow_call: | ||
inputs: | ||
runner: | ||
description: 'Machine on which the tests would run' | ||
type: string | ||
required: true | ||
container: | ||
description: 'JSON to be converted to the value of the "container" configuration for the job' | ||
type: string | ||
required: false | ||
default: '{"image": null}' | ||
affected-components: | ||
description: 'Components that are affected by changes in the commit defined by the Smart CI Action' | ||
type: string | ||
required: true | ||
python-version: | ||
description: 'Python version to setup. E.g., "3.11"' | ||
type: string | ||
required: true | ||
|
||
permissions: read-all | ||
|
||
env: | ||
PIP_CACHE_PATH_LINUX: /mount/caches/pip/linux | ||
PIP_CACHE_PATH_WIN: "C:\\mount\\caches\\pip\\win" | ||
|
||
jobs: | ||
JAX_Layer_Tests: | ||
name: JAX Layer Tests | ||
timeout-minutes: 40 | ||
runs-on: ${{ inputs.runner }} | ||
container: ${{ fromJSON(inputs.container) }} | ||
defaults: | ||
run: | ||
shell: ${{ contains(inputs.runner, 'win') && 'pwsh' || 'bash' }} | ||
env: | ||
DEBIAN_FRONTEND: noninteractive # to prevent apt-get from waiting user input | ||
OPENVINO_REPO: ${{ github.workspace }}/openvino | ||
INSTALL_DIR: ${{ github.workspace }}/install | ||
INSTALL_TEST_DIR: ${{ github.workspace }}/install/tests | ||
INSTALL_WHEELS_DIR: ${{ github.workspace }}/install/wheels | ||
LAYER_TESTS_INSTALL_DIR: ${{ github.workspace }}/install/tests/layer_tests | ||
steps: | ||
- name: Download OpenVINO artifacts (tarballs) | ||
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 | ||
with: | ||
pattern: openvino_[tests]* | ||
path: ${{ env.INSTALL_DIR }} | ||
merge-multiple: true | ||
|
||
- name: Download OpenVINO artifacts (wheels) | ||
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8 | ||
with: | ||
pattern: openvino_[wheels]* | ||
path: ${{ env.INSTALL_WHEELS_DIR }} | ||
merge-multiple: true | ||
|
||
# Needed as ${{ github.workspace }} is not working correctly when using Docker | ||
- name: Setup Variables | ||
if: runner.os != 'Windows' | ||
run: | | ||
echo "OPENVINO_REPO=$GITHUB_WORKSPACE/openvino" >> "$GITHUB_ENV" | ||
echo "INSTALL_DIR=$GITHUB_WORKSPACE/install" >> "$GITHUB_ENV" | ||
echo "INSTALL_TEST_DIR=$GITHUB_WORKSPACE/install/tests" >> "$GITHUB_ENV" | ||
echo "INSTALL_WHEELS_DIR=$GITHUB_WORKSPACE/install/wheels" >> "$GITHUB_ENV" | ||
echo "LAYER_TESTS_INSTALL_DIR=$GITHUB_WORKSPACE/install/tests/layer_tests" >> "$GITHUB_ENV" | ||
- name: Install OpenVINO dependencies (mac) | ||
if: runner.os == 'macOS' | ||
run: brew install pigz | ||
|
||
- name: Extract OpenVINO packages (Linux, macOS) | ||
if: runner.os != 'Windows' | ||
run: | | ||
pigz -dc openvino_tests.tar.gz | tar -xf - -C ${INSTALL_DIR} | ||
working-directory: ${{ env.INSTALL_DIR }} | ||
|
||
- name: Extract OpenVINO artifacts (Windows) | ||
if: runner.os == 'Windows' | ||
run: | | ||
Expand-Archive openvino_tests.zip -DestinationPath ${{ env.INSTALL_DIR }} | ||
working-directory: ${{ env.INSTALL_DIR }} | ||
|
||
- name: Fetch setup_python and install wheels actions | ||
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | ||
timeout-minutes: 15 | ||
with: | ||
sparse-checkout: | | ||
.github/actions/setup_python/action.yml | ||
.github/actions/install_ov_wheels/action.yml | ||
sparse-checkout-cone-mode: false | ||
path: 'openvino' | ||
|
||
- name: Setup Python ${{ inputs.python-version }} | ||
uses: ./openvino/.github/actions/setup_python | ||
with: | ||
version: ${{ inputs.python-version }} | ||
pip-cache-path: ${{ runner.os == 'Linux' && env.PIP_CACHE_PATH_LINUX || env.PIP_CACHE_PATH_WIN }} | ||
should-setup-pip-paths: ${{ runner.os != 'macOS' }} | ||
self-hosted-runner: ${{ runner.os != 'macOS' }} | ||
|
||
- name: Install OpenVINO Python wheels | ||
uses: ./openvino/.github/actions/install_ov_wheels | ||
with: | ||
wheels-dir-path: ${{ env.INSTALL_WHEELS_DIR }} | ||
wheels-to-install: 'openvino' | ||
|
||
- name: Install JAX Layer tests dependencies | ||
run: | | ||
# jax test requirements | ||
python3 -m pip install -r ${{ env.INSTALL_TEST_DIR }}/requirements_jax | ||
- name: JAX Layer Tests | ||
if: ${{ fromJSON(inputs.affected-components).JAX_FE.test && runner.arch != 'ARM64' }} # Ticket: 126287, 142196 | ||
run: python3 -m pytest ${{ env.LAYER_TESTS_INSTALL_DIR }}/jax_tests ${PARALLEL} -m precommit_jax_fe --junitxml=${{ env.INSTALL_TEST_DIR }}/TEST-jax.xml | ||
env: | ||
TEST_DEVICE: CPU | ||
TEST_PRECISION: FP16 | ||
JAX_TRACE_MODE: JAXPR | ||
PARALLEL: ${{ runner.os == 'Windows' && ' ' || '-n logical'}} | ||
|
||
- name: Upload Test Results | ||
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3 | ||
if: ${{ !cancelled() }} | ||
with: | ||
name: test-results-python-jax-layers | ||
path: | | ||
${{ env.INSTALL_TEST_DIR }}/TEST*.html | ||
${{ env.INSTALL_TEST_DIR }}/TEST*.xml | ||
if-no-files-found: 'warn' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
numpy==1.26.4; python_version < "3.12" or platform_system == "Darwin" and platform_machine == "x86_64" | ||
numpy==2.2.1; python_version >= "3.12" and (platform_system != "Darwin" or platform_machine != "x86_64") | ||
pytest==7.0.1 | ||
pytest-xdist[psutil]==3.6.1 | ||
pytest-html==4.1.1 | ||
jax==0.4.38; (platform_system != "Darwin" or platform_machine != "x86_64") and python_version > "3.9" | ||
# tensorflow 2.16.2 depends on ml-dtypes~=0.3.1 and jax 0.4.35 depends on ml-dtypes>=0.4.0 | ||
jax==0.4.33; (platform_system == "Darwin" and platform_machine == "x86_64") and python_version > "3.9" | ||
jax==0.4.30; python_version <= "3.9" | ||
flax==0.10.2 | ||
transformers==4.47.1 | ||
defusedxml | ||
pillow |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters