Repository navigation
[Espressif] Lower Fused Quant linear to ESP-NN #1541
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: Test ESP32 Emulators | |
| on: | |
| push: | |
| branches: | |
| - main | |
| - release/* | |
| pull_request: | |
| paths: | |
| - backends/espressif/** | |
| - examples/espressif/** | |
| # Vendored into the ESP-IDF component, or setting its version. | |
| - runtime/** | |
| - kernels/portable/** | |
| - kernels/quantized/** | |
| - kernels/prim_ops/** | |
| - schema/** | |
| - extension/data_loader/buffer_data_loader.h | |
| - extension/flat_tensor/serialize/** | |
| - codegen/** | |
| - backends/cadence/aot/** | |
| - backends/cadence/generic/** | |
| - third-party/flatbuffers | |
| - shim_et/xplat/executorch/build/build_variables.bzl | |
| - version.txt | |
| # Read for the torch the component's VERSION and README name. | |
| - install_requirements.py | |
| - install_utils.py | |
| # Exported by the consumer test. | |
| - examples/models/mlperf_tiny/** | |
| - devtools/bundled_program/** | |
| - tools/cmake/preset/esp_baremetal.cmake | |
| - CMakePresets.json | |
| - .ci/scripts/test_espressif.sh | |
| - .ci/scripts/test_espressif_host.sh | |
| - .ci/scripts/test_espressif_idf_component.sh | |
| - .ci/scripts/test_espressif_idf_consumer.sh | |
| - .ci/scripts/esp_idf_mirror.py | |
| - .github/workflows/test-espressif.yml | |
| schedule: | |
| - cron: '0 4 * * 1' | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref_name }}-${{ github.ref_type == 'branch' && github.sha }}-${{ github.event_name == 'workflow_dispatch' }}-${{ github.event_name == 'schedule' }} | |
| cancel-in-progress: true | |
| jobs: | |
| docker-image: | |
| name: Resolve CI docker image | |
| uses: ./.github/workflows/_docker-image.yml | |
| test-emulator: | |
| name: ${{ matrix.name }} (${{ matrix.kernels }}) | |
| needs: docker-image | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| # The ANSI C kernels are the same on every chip, so they run on one. | |
| include: | |
| - { target: esp32s3, name: ESP32-S3, kernels: optimized } | |
| - { target: esp32s3, name: ESP32-S3, kernels: ansi } | |
| - { target: esp32p4, name: ESP32-P4, kernels: optimized } | |
| - { target: esp32s31, name: ESP32-S31, kernels: optimized } | |
| uses: pytorch/test-infra/.github/workflows/linux_job_v3.yml@main | |
| permissions: | |
| id-token: write | |
| contents: read | |
| with: | |
| runner: mt-l-x86iavx512-8-64 | |
| docker-image: ${{ needs.docker-image.outputs.docker-registry }}/ci-image:executorch-ubuntu-22.04-clang12-${{ needs.docker-image.outputs.ci-docker-hash }} | |
| submodules: recursive | |
| ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }} | |
| timeout: 45 | |
| upload-artifact: test-report-${{ matrix.target }}-${{ matrix.kernels }} | |
| script: | | |
| set -euo pipefail | |
| CONDA_ENV=$(conda env list --json | jq -r '.envs | .[-1]') | |
| conda activate "${CONDA_ENV}" | |
| source .ci/scripts/utils.sh | |
| install_executorch --use-pt-pinned-commit --minimal | |
| ESPRESSIF_TARGET="${{ matrix.target }}" ESPRESSIF_NN_KERNELS="${{ matrix.kernels }}" \ | |
| bash .ci/scripts/test_espressif.sh | |
| test-host: | |
| name: ESP-NN delegate on the host | |
| needs: docker-image | |
| uses: pytorch/test-infra/.github/workflows/linux_job_v3.yml@main | |
| permissions: | |
| id-token: write | |
| contents: read | |
| with: | |
| runner: mt-l-x86iavx512-8-64 | |
| docker-image: ${{ needs.docker-image.outputs.docker-registry }}/ci-image:executorch-ubuntu-22.04-clang12-${{ needs.docker-image.outputs.ci-docker-hash }} | |
| submodules: recursive | |
| ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }} | |
| timeout: 45 | |
| script: | | |
| set -euo pipefail | |
| CONDA_ENV=$(conda env list --json | jq -r '.envs | .[-1]') | |
| conda activate "${CONDA_ENV}" | |
| source .ci/scripts/utils.sh | |
| install_executorch --use-pt-pinned-commit --minimal | |
| bash .ci/scripts/test_espressif_host.sh | |
| test-idf-component: | |
| name: ESP-IDF component | |
| needs: docker-image | |
| uses: pytorch/test-infra/.github/workflows/linux_job_v3.yml@main | |
| permissions: | |
| id-token: write | |
| contents: read | |
| with: | |
| runner: mt-l-x86iavx512-8-64 | |
| docker-image: ${{ needs.docker-image.outputs.docker-registry }}/ci-image:executorch-ubuntu-22.04-clang12-${{ needs.docker-image.outputs.ci-docker-hash }} | |
| submodules: recursive | |
| ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }} | |
| timeout: 45 | |
| upload-artifact: test-report-esp-idf-component | |
| script: | | |
| set -euo pipefail | |
| CONDA_ENV=$(conda env list --json | jq -r '.envs | .[-1]') | |
| conda activate "${CONDA_ENV}" | |
| source .ci/scripts/utils.sh | |
| install_executorch --use-pt-pinned-commit --minimal | |
| bash .ci/scripts/test_espressif_idf_component.sh | |
| test-idf-consumer: | |
| name: ESP-IDF component consumer (${{ matrix.idf-version }}) | |
| needs: docker-image | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| idf-version: [v6.1, v6.0.1] | |
| uses: pytorch/test-infra/.github/workflows/linux_job_v3.yml@main | |
| permissions: | |
| id-token: write | |
| contents: read | |
| with: | |
| runner: mt-l-x86iavx512-8-64 | |
| docker-image: ${{ needs.docker-image.outputs.docker-registry }}/ci-image:executorch-ubuntu-22.04-clang12-${{ needs.docker-image.outputs.ci-docker-hash }} | |
| submodules: recursive | |
| ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }} | |
| timeout: 45 | |
| upload-artifact: test-report-esp-idf-consumer-${{ matrix.idf-version }} | |
| script: | | |
| set -euo pipefail | |
| CONDA_ENV=$(conda env list --json | jq -r '.envs | .[-1]') | |
| conda activate "${CONDA_ENV}" | |
| source .ci/scripts/utils.sh | |
| install_executorch --use-pt-pinned-commit --minimal | |
| ESPRESSIF_IDF_VERSION="${{ matrix.idf-version }}" bash .ci/scripts/test_espressif_idf_consumer.sh |