-
Notifications
You must be signed in to change notification settings - Fork 537
Fix tutorial for Qualcomm AI Engine Direct Backend #2956
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -115,6 +115,10 @@ Python APIs on x64 are required to compile models to Qualcomm AI Engine Direct b | |
|
||
```bash | ||
cd $EXECUTORCH_ROOT | ||
# Workaround for fbs files in exir/_serialize | ||
cp schema/program.fbs exir/_serialize/program.fbs | ||
cp schema/scalar_type.fbs exir/_serialize/scalar_type.fbs | ||
|
||
mkdir build_x86_64 | ||
cd build_x86_64 | ||
cmake .. -DEXECUTORCH_BUILD_QNN=ON -DQNN_SDK_ROOT=${QNN_SDK_ROOT} | ||
|
@@ -138,8 +142,8 @@ mkdir build_android | |
cd build_android | ||
# build executorch & qnn_executorch_backend | ||
cmake .. \ | ||
-DBUCK2=buck2 \ | ||
-DCMAKE_INSTALL_PREFIX=$PWD \ | ||
-DEXECUTORCH_BUILD_SDK=ON \ | ||
-DEXECUTORCH_BUILD_QNN=ON \ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Possibly need something like CMAKE_INSTALL_PREFIX if we don't want to require root priviledge. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. never mind! I saw There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this issue good now? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Yes, it's good now. |
||
-DQNN_SDK_ROOT=$QNN_SDK_ROOT \ | ||
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake \ | ||
|
@@ -220,6 +224,7 @@ So, we can run `qnn_executor_runner` like | |
```bash | ||
adb push ./deeplab_v3/dlv3_qnn.pte ${DEVICE_DIR} | ||
adb push ${EXECUTORCH_ROOT}/build_android/examples/qualcomm/qnn_executor_runner ${DEVICE_DIR} | ||
adb push ${EXECUTORCH_ROOT}/build_android/lib/libqnn_executorch_backend.so ${DEVICE_DIR} | ||
adb shell "cd ${DEVICE_DIR} \ | ||
&& export LD_LIBRARY_PATH=${DEVICE_DIR} \ | ||
&& export ADSP_LIBRARY_PATH=${DEVICE_DIR} \ | ||
|
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.
how do we link it with prim ops lib?
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.
In
executorch/examples/qualcomm/CMakeLists.txt
Lines 102 to 108 in 687425d
For other users, add executorch explicitly to binary helps
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.
TLDR is for users who use
qnn_executorch_backend
as a dependency, it should also haveexecutorch
as a dependency now.