|  | 
|  | 1 | +name: Build and test Windows wheels | 
|  | 2 | + | 
|  | 3 | +on: | 
|  | 4 | +  pull_request: | 
|  | 5 | +  push: | 
|  | 6 | +    branches: | 
|  | 7 | +      - main | 
|  | 8 | +      - nightly | 
|  | 9 | +      - release/* | 
|  | 10 | +    tags: | 
|  | 11 | +        # NOTE: Binary build pipelines should only get triggered on release candidate builds | 
|  | 12 | +        # Release candidate tags look like: v1.11.0-rc1 | 
|  | 13 | +        - v[0-9]+.[0-9]+.[0-9]+-rc[0-9]+ | 
|  | 14 | +  workflow_dispatch: | 
|  | 15 | + | 
|  | 16 | +jobs: | 
|  | 17 | +  generate-matrix: | 
|  | 18 | +    uses: pytorch/test-infra/.github/workflows/generate_binary_build_matrix.yml@main | 
|  | 19 | +    with: | 
|  | 20 | +      package-type: wheel | 
|  | 21 | +      os: windows | 
|  | 22 | +      test-infra-repository: pytorch/test-infra | 
|  | 23 | +      test-infra-ref: main | 
|  | 24 | +      with-rocm: false | 
|  | 25 | +      with-cpu: false | 
|  | 26 | + | 
|  | 27 | +  build: | 
|  | 28 | +    needs: generate-matrix | 
|  | 29 | +    permissions: | 
|  | 30 | +      id-token: write | 
|  | 31 | +      contents: read | 
|  | 32 | +    strategy: | 
|  | 33 | +      fail-fast: false | 
|  | 34 | +      matrix: | 
|  | 35 | +        include: | 
|  | 36 | +          - repository: pytorch/tensorrt | 
|  | 37 | +            pre-script: packaging/pre_build_script_windows.sh | 
|  | 38 | +            smoke-test-script: packaging/smoke_test_windows.py | 
|  | 39 | +            package-name: torch_tensorrt | 
|  | 40 | +    name: Build torch-tensorrt whl package | 
|  | 41 | +    uses: pytorch/test-infra/.github/workflows/build_wheels_windows.yml@main | 
|  | 42 | +    with: | 
|  | 43 | +      repository: ${{ matrix.repository }} | 
|  | 44 | +      ref: "" | 
|  | 45 | +      test-infra-repository: pytorch/test-infra | 
|  | 46 | +      test-infra-ref: main | 
|  | 47 | +      build-matrix: ${{ needs.generate-matrix.outputs.matrix }} | 
|  | 48 | +      pre-script: ${{ matrix.pre-script }} | 
|  | 49 | +      smoke-test-script: ${{ matrix.smoke-test-script }} | 
|  | 50 | +      package-name: ${{ matrix.package-name }} | 
|  | 51 | +      trigger-event: ${{ github.event_name }} | 
|  | 52 | + | 
|  | 53 | +  tests-py-dynamo-converters: | 
|  | 54 | +    name: Test dynamo converters [Python] | 
|  | 55 | +    needs: [generate-matrix, build] | 
|  | 56 | +    strategy: | 
|  | 57 | +      fail-fast: false | 
|  | 58 | +      matrix: | 
|  | 59 | +        include: | 
|  | 60 | +          - repository: pytorch/tensorrt | 
|  | 61 | +            package-name: torch_tensorrt | 
|  | 62 | +    uses: ./.github/workflows/windows-test.yml | 
|  | 63 | +    with: | 
|  | 64 | +      job-name: tests-py-dynamo-converters | 
|  | 65 | +      repository: "pytorch/tensorrt" | 
|  | 66 | +      ref: "" | 
|  | 67 | +      test-infra-repository: pytorch/test-infra | 
|  | 68 | +      test-infra-ref: main | 
|  | 69 | +      build-matrix: ${{ needs.generate-matrix.outputs.matrix }} | 
|  | 70 | +      pre-script: packaging/driver_upgrade.bat | 
|  | 71 | +      script: | | 
|  | 72 | +        export USE_HOST_DEPS=1 | 
|  | 73 | +        pushd . | 
|  | 74 | +        cd tests/py/dynamo | 
|  | 75 | +        ${CONDA_RUN} python -m pip install --pre pytest-xdist timm transformers parameterized expecttest==0.1.6 --use-deprecated=legacy-resolver | 
|  | 76 | +        ${CONDA_RUN} python -m pytest --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_converters_test_results.xml -n 10 conversion/ | 
|  | 77 | +        popd | 
|  | 78 | +
 | 
|  | 79 | +  tests-py-dynamo-fe: | 
|  | 80 | +    name: Test dynamo frontend [Python] | 
|  | 81 | +    needs: [generate-matrix, build] | 
|  | 82 | +    strategy: | 
|  | 83 | +      fail-fast: false | 
|  | 84 | +      matrix: | 
|  | 85 | +        include: | 
|  | 86 | +          - repository: pytorch/tensorrt | 
|  | 87 | +            package-name: torch_tensorrt | 
|  | 88 | +    uses: ./.github/workflows/windows-test.yml | 
|  | 89 | +    with: | 
|  | 90 | +      job-name: tests-py-dynamo-fe | 
|  | 91 | +      repository: "pytorch/tensorrt" | 
|  | 92 | +      ref: "" | 
|  | 93 | +      test-infra-repository: pytorch/test-infra | 
|  | 94 | +      test-infra-ref: main | 
|  | 95 | +      build-matrix: ${{ needs.generate-matrix.outputs.matrix }} | 
|  | 96 | +      pre-script: packaging/driver_upgrade.bat | 
|  | 97 | +      script: | | 
|  | 98 | +        export USE_HOST_DEPS=1 | 
|  | 99 | +        pushd . | 
|  | 100 | +        cd tests/py/dynamo | 
|  | 101 | +        ${CONDA_RUN} python -m pip install --pre pytest-xdist timm transformers parameterized expecttest==0.1.6 --use-deprecated=legacy-resolver | 
|  | 102 | +        ${CONDA_RUN} python -m pytest --junitxml=${RUNNER_TEST_RESULTS_DIR}/dynamo_fe_test_results.xml --ir dynamo models/test_models_export.py | 
|  | 103 | +        ${CONDA_RUN} python -m pytest --junitxml=${RUNNER_TEST_RESULTS_DIR}/dyn_models_export.xml --ir dynamo models/test_dyn_models.py | 
|  | 104 | +        popd | 
|  | 105 | +
 | 
|  | 106 | +  tests-py-torch-compile-be: | 
|  | 107 | +    name: Test torch compile backend [Python] | 
|  | 108 | +    needs: [generate-matrix, build] | 
|  | 109 | +    strategy: | 
|  | 110 | +      fail-fast: false | 
|  | 111 | +      matrix: | 
|  | 112 | +        include: | 
|  | 113 | +          - repository: pytorch/tensorrt | 
|  | 114 | +            package-name: torch_tensorrt | 
|  | 115 | +    uses: ./.github/workflows/windows-test.yml | 
|  | 116 | +    with: | 
|  | 117 | +      job-name: tests-py-torch-compile-be | 
|  | 118 | +      repository: ${{ matrix.repository }} | 
|  | 119 | +      ref: "" | 
|  | 120 | +      test-infra-repository: pytorch/test-infra | 
|  | 121 | +      test-infra-ref: main | 
|  | 122 | +      pre-script: packaging/driver_upgrade.bat | 
|  | 123 | +      build-matrix: ${{ needs.generate-matrix.outputs.matrix }} | 
|  | 124 | +      script: | | 
|  | 125 | +        export USE_HOST_DEPS=1 | 
|  | 126 | +        pushd . | 
|  | 127 | +        cd tests/py/dynamo | 
|  | 128 | +        ${CONDA_RUN} python -m pip install --pre pytest-xdist timm transformers parameterized expecttest==0.1.6 --use-deprecated=legacy-resolver | 
|  | 129 | +        ${CONDA_RUN} python -m pytest -n 10 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_compile_be_test_results.xml backend/ | 
|  | 130 | +        ${CONDA_RUN} python -m pytest -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/torch_comple_be_e2e_test_results.xml --ir torch_compile models/test_models.py | 
|  | 131 | +        popd | 
|  | 132 | +
 | 
|  | 133 | +  tests-py-dynamo-core: | 
|  | 134 | +    name: Test dynamo core [Python] | 
|  | 135 | +    needs: [generate-matrix, build] | 
|  | 136 | +    strategy: | 
|  | 137 | +      fail-fast: false | 
|  | 138 | +      matrix: | 
|  | 139 | +        include: | 
|  | 140 | +          - repository: pytorch/tensorrt | 
|  | 141 | +            package-name: torch_tensorrt | 
|  | 142 | +    uses: ./.github/workflows/windows-test.yml | 
|  | 143 | +    with: | 
|  | 144 | +      job-name: tests-py-dynamo-core | 
|  | 145 | +      repository: "pytorch/tensorrt" | 
|  | 146 | +      ref: "" | 
|  | 147 | +      test-infra-repository: pytorch/test-infra | 
|  | 148 | +      test-infra-ref: main | 
|  | 149 | +      build-matrix: ${{ needs.generate-matrix.outputs.matrix }} | 
|  | 150 | +      pre-script: packaging/driver_upgrade.bat | 
|  | 151 | +      script: | | 
|  | 152 | +        export USE_HOST_DEPS=1 | 
|  | 153 | +        pushd . | 
|  | 154 | +        cd tests/py/dynamo | 
|  | 155 | +        ${CONDA_RUN} python -m pip install --pre pytest-xdist timm transformers parameterized expecttest==0.1.6 --use-deprecated=legacy-resolver | 
|  | 156 | +        ${CONDA_RUN} python -m pytest -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_runtime_test_results.xml runtime/ | 
|  | 157 | +        ${CONDA_RUN} python -m pytest -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_partitioning_test_results.xml partitioning/ | 
|  | 158 | +        ${CONDA_RUN} python -m pytest -n 4 --junitxml=${RUNNER_TEST_RESULTS_DIR}/tests_py_dynamo_core_lowering_test_results.xml lowering/ | 
|  | 159 | +        popd | 
0 commit comments