Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 22 additions & 2 deletions .github/workflows/ubuntu_22.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ on:
description: 'Target branch for the build; taken from event context by default'
type: string
required: false
pytorch-models-nightly:
description: 'Run nightly PyTorch model hub tests'
type: boolean
default: false
pull_request:
types:
- opened
Expand Down Expand Up @@ -45,6 +49,7 @@ jobs:
changed_components: "${{ steps.smart_ci.outputs.changed_components }}"
skip_workflow: "${{ steps.smart_ci.outputs.skip_workflow }}"
use_latest_onednn: "${{ steps.onednn_day.outputs.use_latest_onednn }}"
pytorch_models_nightly: "${{ steps.pytorch_models_nightly.outputs.changed }}"
steps:
- name: checkout action
uses: ababushk/checkout@dd591a6a2ac25618db4eda86e7e0d938f88cf01b # cherry_pick_retries
Expand Down Expand Up @@ -82,6 +87,19 @@ jobs:
echo "use_latest_onednn=false" >> "$GITHUB_OUTPUT"
fi

- name: Check if nightly PyTorch model tests are changed
id: pytorch_models_nightly
if: ${{ github.event_name == 'pull_request' }}
shell: bash
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PR_NUMBER: ${{ github.event.number }}
run: |
files=$(gh api --paginate "repos/${GITHUB_REPOSITORY}/pulls/${PR_NUMBER}/files" --jq '.[].filename')
if grep -qE '^(tests/model_hub_tests/(pytorch|models_hub_common)/|\.github/workflows/job_pytorch_models_tests\.yml$)' <<< "$files"; then
echo "changed=true" >> "$GITHUB_OUTPUT"
fi

Docker:
needs: Smart_CI
runs-on: aks-linux-4-cores-16gb-docker-build
Expand Down Expand Up @@ -469,7 +487,8 @@ jobs:

PyTorch_Models_Tests_Nightly_Scope1:
name: PyTorch Models Nightly Scope1 tests
if: ${{ github.event_name == 'schedule' }}
if: ${{ github.event_name == 'schedule' || inputs.pytorch-models-nightly ||
needs.smart_ci.outputs.pytorch_models_nightly == 'true' }}
needs: [ Docker, Build, Smart_CI, Openvino_tokenizers ]
uses: ./.github/workflows/job_pytorch_models_tests.yml
with:
Expand All @@ -479,7 +498,8 @@ jobs:

PyTorch_Models_Tests_Nightly_Scope2:
name: PyTorch Models Nightly Scope2 tests
if: ${{ github.event_name == 'schedule' }}
if: ${{ github.event_name == 'schedule' || inputs.pytorch-models-nightly ||
needs.smart_ci.outputs.pytorch_models_nightly == 'true' }}
needs: [ Docker, Build, Smart_CI, Openvino_tokenizers ]
uses: ./.github/workflows/job_pytorch_models_tests.yml
with:
Expand Down
Loading