-
Notifications
You must be signed in to change notification settings - Fork 636
Add stories ci for qnn #4662
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add stories ci for qnn #4662
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/4662
Note: Links to docs will display an error until the docs builds have been completed. ❌ 1 New FailureAs of commit 5174d8f with merge base 99e1ae1 ( NEW FAILURE - The following job has failed:
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
@cccclai has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
As a note, this pr just test fp, and quantized version need to be added later |
@cccclai has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
COPY --chown=ci-user:ci-user ./qualcomm /opt/qualcomm | ||
# Set up QNN SDK if needed | ||
RUN if [ -n "${QNN_SDK}" ]; then git config --global user.email "ossci@example.com"; git config --global user.name "OSS CI"; fi | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ARG QNN_SDK
COPY --chown=ci-user:ci-user ./scripts/setup-qnn-deps.sh setup-qnn-deps.sh
# Set up QNN SDK if needed
RUN if [ -n "${QNN_SDK}" ]; then ./setup-qnn-deps.sh; fi
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ARG QNN_SDK
COPY --chown=ci-user:ci-user ./scripts/setup-qnn-deps.sh setup-qnn-deps.sh
RUN mkdir /opt/qualcomm; chown ci-user:ci-user /opt/qualcomm
RUN if [ -n "${QNN_SDK}" ]; then ./setup-qnn-deps.sh; fi
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ARG QNN_SDK
COPY --chown=ci-user:ci-user ./scripts/setup-qnn-deps.sh setup-qnn-deps.sh
RUN if [ -n "${QNN_SDK}" ]; then mkdir /opt/qualcomm; chown ci-user:ci-user /opt/qualcomm; ./setup-qnn-deps.sh; fi
|
||
install_qnn() { | ||
echo "Start installing qnn." | ||
QNN_INSTALLATION_DIR=/tmp/qnn |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe /opt instead of /tmp ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah will address it in next diff
@@ -37,6 +37,10 @@ case "${IMAGE_NAME}" in | |||
ARM_SDK=yes | |||
CLANG_VERSION=12 | |||
;; | |||
executorch-ubuntu-22.04-qnn-sdk) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not adding qnn sdk by extending the executorch-ubuntu-22.04-clang12-android
image below? QNN backend would require ndk and cross-compilation, making it a good fit to the android image
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is not android, it's x86
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cccclai Thanks for adding the QNN deps to the docker image! We'er thinking of doing the same work for benchmarking infra.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it's more intuitive to make it part of the existing executorch-ubuntu-22.04-clang12-android
docker image, otherwise have to switch to load different dockers to build QNN runtime and android app
no this is x86, not android |
I see. So this work enables running QNN with the emulator on x86_64, the android build is not covered in this PR correct? |
That's correct. The reusable part is the docker image with QNN SDK set up. |
Thanks for the clarification. BTW, IIUC that's not reusable because we will have to set up the QNN SDK for the android docker as this is for Linux x86. The wrapper script |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
unblocking after clarification
Oh we want a separate docker like |
If I understand @cccclai 's comment correctly, |
Oh I guess @cccclai means the CI is for linux x86. The docker is pulling in QNN SDK so it can be used for everything which requires QNN SDK (including Android) |
I understand that part, and @kirklandsign what's your actionable suggestion? Like expending |
I see. I would say we can keep two docker images for now. Just in case -qnn-sdk and -android diverged further next. A quick patch for -android is in https://github.com/pytorch/executorch/pull/4662/files#diff-e6d9e0419b8aac6f9b7664fe9d2398da07ab195b26f0dce338e13968511daba5R46, add |
@@ -25,9 +25,9 @@ usage() { | |||
[ "$1" = -h ] && usage | |||
|
|||
BUILD_X86_64="true" | |||
CMAKE_X86_64="cmake-out" | |||
CMAKE_X86_64="build-x86" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chiwwang I rename it to the similar name as before, because the ci job will clean up cmake-out
for every run. We can make build.sh
takes configurable name as next step and change the default name to cmake-out
and cmake-out-android
@cccclai has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
As title, add stories end to end ci for qnn. See the success job in https://github.com/pytorch/executorch/actions/runs/10347877541/job/28638999876