On-demand / test_wheel #942
This file contains hidden or 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
name: Nightly-OnDemand Tests | |
on: | |
schedule: | |
# GMT+8 21:00 every workday | |
- cron: '10 13 * * 0-4' # build from source | |
- cron: '30 13 * * 0-4' # nightly wheel | |
# GMT+8 00:00 Saturday | |
- cron: '10 16 * * 5' # build from source | |
- cron: '30 16 * * 5' # nightly wheel | |
workflow_dispatch: | |
inputs: | |
pytorch: | |
type: string | |
default: 'main' | |
description: Pytorch main by default, or 'commit/branch', or 'repo@commit/repo@branch' | |
torch_xpu_ops: | |
type: string | |
default: 'main' | |
description: Torch-xpu-ops main by default, 'commit/branch', or 'repo@commit/repo@branch', or 'pinned' for pytorch pin | |
triton: | |
type: string | |
default: 'pinned' | |
description: Triton pinned by pytorch by default, or 'commit/branch', or 'repo@commit/repo@branch' | |
oneapi: | |
type: string | |
default: 'installed' | |
description: Installed oneAPI DLE on host by default, fill offline.sh url if needed | |
ut: | |
type: string | |
default: '' | |
description: UT scope. `ut_regression,ut_transformers,ut_extended,ut_op,ut_profiling,ut_torch,xpu_dev1,xpu_distributed,microbench,windows`. Delimiter is comma | |
suite: | |
type: string | |
default: '' | |
description: Dynamo benchmarks test suite. `huggingface,timm_models,torchbench,pt2e`. Delimiter is comma | |
dt: | |
type: string | |
default: '' | |
description: Data precision of the test. `float32,bfloat16,float16,amp_bf16,amp_fp16`. Delimiter is comma | |
mode: | |
type: string | |
default: '' | |
description: Test mode. `inference,training`. Delimiter is comma | |
scenario: | |
type: string | |
default: '' | |
description: Test scenario. `accuracy,performance`. Delimiter is comma | |
model: | |
type: string | |
default: '' | |
description: Model. Will only run this one mode if set | |
permissions: read-all | |
run-name: ${{ (contains(github.event.schedule, '13') && 'Nightly') || (contains(github.event.schedule, '16') && 'Weekly') || 'On-demand' }} / ${{ (contains(github.event.schedule, '10') && 'Source Code') || (contains(github.event.schedule, '30') && 'CD Wheel') || inputs.pytorch }} | |
jobs: | |
Conditions-Filter: | |
name: conditions-filter | |
if: ${{ github.repository_owner == 'intel' }} | |
runs-on: ubuntu-latest | |
timeout-minutes: 3 | |
outputs: | |
test_type: ${{ steps.inputs-check.outputs.test_type }} | |
pytorch: ${{ steps.inputs-check.outputs.pytorch }} | |
torch_xpu_ops: ${{ steps.inputs-check.outputs.torch_xpu_ops }} | |
steps: | |
- name: Inputs check | |
id: inputs-check | |
run: | | |
if [ "${{ github.event_name }}" == "schedule" ];then | |
if [ "${{ github.event.schedule }}" == "10 13 * * 0-4" ];then | |
test_type="build-nightly" | |
pytorch="main" | |
torch_xpu_ops="main" | |
elif [ "${{ github.event.schedule }}" == "30 13 * * 0-4" ];then | |
test_type="wheel-nightly" | |
pytorch="nightly_wheel" | |
torch_xpu_ops="pinned" | |
elif [ "${{ github.event.schedule }}" == "10 16 * * 5" ];then | |
test_type="build-weekly" | |
pytorch="main" | |
torch_xpu_ops="main" | |
elif [ "${{ github.event.schedule }}" == "30 16 * * 5" ];then | |
test_type="wheel-weekly" | |
pytorch="nightly_wheel" | |
torch_xpu_ops="pinned" | |
else | |
test_type="unknown" | |
pytorch="main" | |
torch_xpu_ops="main" | |
fi | |
else | |
if [[ "${{ inputs.pytorch }}" == *"_wheel" ]];then | |
test_type="wheel-ondemand" | |
pytorch="${{ inputs.pytorch }}" | |
torch_xpu_ops="${{ inputs.torch_xpu_ops }}" | |
else | |
test_type="build-ondemand" | |
pytorch="${{ inputs.pytorch }}" | |
torch_xpu_ops="${{ inputs.torch_xpu_ops }}" | |
fi | |
fi | |
echo "test_type=${test_type}" >> ${GITHUB_OUTPUT} | |
echo "pytorch=${pytorch}" >> ${GITHUB_OUTPUT} | |
echo "torch_xpu_ops=${torch_xpu_ops}" >> ${GITHUB_OUTPUT} | |
Linux-Nightly-Ondemand-Build: | |
needs: [Conditions-Filter] | |
name: linux-build | |
secrets: inherit | |
uses: ./.github/workflows/_linux_build.yml | |
with: | |
runner: pvc_rolling | |
test_type: ${{ needs.Conditions-Filter.outputs.test_type }} | |
pytorch: ${{ needs.Conditions-Filter.outputs.pytorch }} | |
torch_xpu_ops: ${{ needs.Conditions-Filter.outputs.torch_xpu_ops }} | |
triton: ${{ github.event_name == 'schedule' && 'pinned' || inputs.triton }} | |
oneapi: ${{ github.event_name == 'schedule' && 'installed' || inputs.oneapi }} | |
python: ${{ github.event_name == 'schedule' && '3.10' || '3.10' }} | |
Linux-Nightly-Ondemand-UT-Tests: | |
if: ${{ github.event_name == 'schedule' || contains(inputs.ut, 'ut_') || contains(inputs.ut, 'xpu_') }} | |
name: linux-ut | |
needs: [Conditions-Filter, Linux-Nightly-Ondemand-Build] | |
uses: ./.github/workflows/_linux_ut.yml | |
with: | |
runner: pvc_rolling | |
test_type: ${{ needs.Conditions-Filter.outputs.test_type }} | |
pytorch: ${{ needs.Conditions-Filter.outputs.pytorch }} | |
torch_xpu_ops: ${{ needs.Conditions-Filter.outputs.torch_xpu_ops }} | |
oneapi: ${{ github.event_name == 'schedule' && 'installed' || inputs.oneapi }} | |
python: ${{ github.event_name == 'schedule' && '3.10' || '3.10' }} | |
ut: ${{ github.event_name == 'schedule' && 'ut_regression,xpu_dev1,ut_transformers,ut_extended,ut_op' || inputs.ut }} | |
Linux-Nightly-Ondemand-E2E-Tests: | |
if: ${{ github.event_name == 'schedule' || contains(inputs.suite, 'e') }} | |
name: linux-e2e | |
permissions: write-all | |
needs: [Conditions-Filter, Linux-Nightly-Ondemand-Build] | |
uses: ./.github/workflows/_linux_e2e.yml | |
with: | |
runner: ${{ contains(inputs.scenario, 'performance') && 'PVC-03004' || 'pvc_rolling' }} | |
test_type: ${{ needs.Conditions-Filter.outputs.test_type }} | |
pytorch: ${{ needs.Conditions-Filter.outputs.pytorch }} | |
oneapi: ${{ github.event_name == 'schedule' && 'installed' || inputs.oneapi }} | |
python: ${{ github.event_name == 'schedule' && '3.10' || '3.10' }} | |
suite: ${{ github.event_name == 'schedule' && 'huggingface' || inputs.suite }} | |
dt: ${{ github.event_name == 'schedule' && 'float32' || inputs.dt }} | |
mode: ${{ github.event_name == 'schedule' && 'inference' || inputs.mode }} | |
scenario: ${{ github.event_name == 'schedule' && 'accuracy' || inputs.scenario }} | |
model: ${{ github.event_name == 'schedule' && '' || inputs.model }} |