Skip to content
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

RK3568 RK3588在android11下进行paddleocr推理应用,paddlelite编译找不到合适tim-vx sdk版本和驱动 #10433

Open
equalman opened this issue Jan 13, 2024 · 7 comments

Comments

@equalman
Copy link

如题在进行RK3568的paddleocr推理应用, 计划使用fastdeploy框架加快应用, android下需要编译paddlelite, 然后paddlelite不支持android下的rknpu后端, 在普通linux下才可以编译rknpu
对比lite/tools下的build_android.sh和build_linux.sh发现确实android下不支持RKNPU, 所以如下命令会报错
./lite/tools/build_android.sh --arch=armv8 --toolchain=clang --android_stl=c++_shared --with_extra=ON --with_cv=ON --with_rockchip_npu=ON --rockchip_npu_sdk_root=/home/rknn-toolkit2-1.6.0/rknpu2/runtime/Android/librknn_api full_publish

参考过的文档如下:
https://www.paddlepaddle.org.cn/inference/demo_guides/rockchip_npu.html PaddleLite使用瑞芯微NPU预测部署
https://www.paddlepaddle.org.cn/lite/develop/demo_guides/verisilicon_timvx.html (瑞芯微/晶晨/恩智浦) 芯原 TIM-VX
https://github.com/PaddlePaddle/FastDeploy/blob/develop/docs/cn/build_and_install/android.md Android部署库编译

如此paddlelite支持瑞芯微npu只能通过tim-vx sdk的方式, 但是上面第二个链接里没有RK3568等的编译指令, 只有RK1808最接近
$ ./lite/tools/build_linux.sh --with_extra=ON --with_log=ON --with_nnadapter=ON --nnadapter_with_verisilicon_timvx=ON --nnadapter_verisilicon_timvx_src_git_tag=main --nnadapter_verisilicon_timvx_viv_sdk_url=http://paddlelite-demo.bj.bcebos.com/devices/verisilicon/sdk/viv_sdk_linux_arm64_6_4_6_5_generic.tgz full_publish
命令里的nnadapter_verisilicon_timvx_viv_sdk_url值是否适用于RK3568,RK3588, 对应的驱动和依赖库在哪里呢
1)Paddle Lite 版本:v2.13-rc
   2)Host 环境:docker pull paddlepaddle/paddle-lite:2.0.0_beta ubuntu16.04
   3)运行设备环境:RK3568 RK3588 android11 开发板厂家 迅为
   4)预测后端信息:fastdeploy + paddlelite + TIM-VX

第二个链接里提到rockchip的驱动版本是6.4.6.5,这适应我的这芯片吗?
可以给出适合RK3568 RK3588芯片的tim-vx sdk及驱动和依赖库吗?
https://github.com/VeriSilicon/TIM-VX 这里没有找到驱动和sdk

@equalman
Copy link
Author

补充点开发板adb shell命令结果
rk3568_r:/ $ getprop ro.build.version.release
11
rk3568_r:/ $ getprop ro.build.version.sdk
30
rk3568_r:/ $ uname -a
Linux localhost 4.19.193 #11 SMP PREEMPT Tue Aug 1 09:31:10 PDT 2023 aarch64

@engineer1109
Copy link
Contributor

要芯源的NPU才行

@equalman
Copy link
Author

要芯源的NPU才行

不是芯原npu的话无法用芯原sdk, android下也不支持rknpu后端, 那这两个芯片android下就不能用paddlelite了, 得改ppocr的推理接口为rknpu做支持了吧

@equalman
Copy link
Author

要芯源的NPU才行
教程里的RK1808那类是明确芯原NPU的, 新出的RK3568, 3588是瑞芯微自研的是吧? 也没有哪个地方能暗示这个信息

@engineer1109
Copy link
Contributor

用RKNN,没必要PaddleLite

@equalman
Copy link
Author

用RKNN,没必要PaddleLite

好的 感谢指点

@hong19860320
Copy link
Collaborator

RK3588、RK3566 的 NPU 是瑞芯微自己的 IP,不是芯原的,PaddleLite 不支持。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants