未验证 提交 f38c896a 编写于 作者: A Advait Jain 提交者: GitHub

Only perform a build for the vision_p6 PR presubmit checks (do not run the tests) (#405)

* Add option to only do a build for the vision_p6.

BUG=http://b/196459172

* Only build for Vision P6 as part of presubmit checks.

* make running the tests optional.

* fix whitespace.

* Address review comments.
上级 b929bdf9
......@@ -55,22 +55,37 @@ jobs:
echo ${{ secrets.TFLM_BOT_PACKAGE_READ_TOKEN }} | docker login ghcr.io -u tflm-bot --password-stdin
docker run --rm -v `pwd`:/opt/tflite-micro ghcr.io/tflm-bot/xtensa:0.1 /opt/tflite-micro/tensorflow/lite/micro/tools/ci_build/test_xtensa_hifi5.sh
vision_p6_presubmit:
runs-on: ubuntu-latest
if: |
github.event_name == 'workflow_dispatch' ||
(github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'ci:run'))
name: Vision P6 Build (presubmit)
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.sha }}
- run: |
echo ${{ secrets.TFLM_BOT_PACKAGE_READ_TOKEN }} | docker login ghcr.io -u tflm-bot --password-stdin
docker run --rm -v `pwd`:/opt/tflite-micro ghcr.io/tflm-bot/xtensa:0.1 /opt/tflite-micro/tensorflow/lite/micro/tools/ci_build/test_xtensa_vision_p6.sh
vision_p6_unit_tests:
runs-on: ubuntu-latest
if: |
github.event_name == 'workflow_dispatch' ||
(github.event_name == 'pull_request_target' && contains(github.event.pull_request.labels.*.name, 'ci:run')) ||
(github.event_name == 'schedule' && github.repository == 'tensorflow/tflite-micro')
name: Vision P6 Unit Tests (presubmit)
name: Vision P6 Unit Tests (nightly)
steps:
- uses: actions/checkout@v2
with:
ref: ${{ github.event.pull_request.head.sha }}
- run: |
echo ${{ secrets.TFLM_BOT_PACKAGE_READ_TOKEN }} | docker login ghcr.io -u tflm-bot --password-stdin
docker run --rm -v `pwd`:/opt/tflite-micro ghcr.io/tflm-bot/xtensa:0.1 /opt/tflite-micro/tensorflow/lite/micro/tools/ci_build/test_xtensa_vision_p6.sh
docker run --rm -v `pwd`:/opt/tflite-micro ghcr.io/tflm-bot/xtensa:0.1 /opt/tflite-micro/tensorflow/lite/micro/tools/ci_build/test_xtensa_vision_p6.sh RUN_TESTS
hifi_3z_unit_tests:
runs-on: ubuntu-latest
......
......@@ -28,9 +28,22 @@ readable_run make -f tensorflow/lite/micro/tools/make/Makefile clean
# TODO(b/143904317): downloading first to allow for parallel builds.
readable_run make -f tensorflow/lite/micro/tools/make/Makefile third_party_downloads
readable_run make -f tensorflow/lite/micro/tools/make/Makefile \
TARGET=xtensa \
TARGET_ARCH=vision_p6 \
OPTIMIZED_KERNEL_DIR=xtensa \
XTENSA_CORE=P6_200528 \
test -j$(nproc)
# Since we currently do not have optimized kernel implemetations for vision_p6,
# running the tests (in particular person_detection_int8) takes a very long
# time. So, we have changed the default for this script to only perform a build
# and added an option to run all the tests when that is feasible.
if [[ ${1} == "RUN_TESTS" ]]; then
readable_run make -f tensorflow/lite/micro/tools/make/Makefile \
TARGET=xtensa \
TARGET_ARCH=vision_p6 \
OPTIMIZED_KERNEL_DIR=xtensa \
XTENSA_CORE=P6_200528 \
test -j$(nproc)
else
readable_run make -f tensorflow/lite/micro/tools/make/Makefile \
TARGET=xtensa \
TARGET_ARCH=vision_p6 \
OPTIMIZED_KERNEL_DIR=xtensa \
XTENSA_CORE=P6_200528 \
build -j$(nproc)
fi
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册