⚡️FastDeploy是一款全场景、易用灵活、极致高效的AI推理部署工具, 支持云边端部署。提供超过 160+ Text,Vision, Speech和跨模态模型开箱即用的部署体验,并实现端到端的推理性能优化。包括 物体检测、字符识别(OCR)、人脸、人像扣图、多目标跟踪系统、NLP、Stable Diffusion文图生成、TTS 等几十种任务场景,满足开发者多场景、多硬件、多平台的产业部署需求。
conda activate ok3588
sudo apt-get install libxslt1-dev zlib1g zlib1g-dev libglib2.0-0 libsm6 libgl1-mesa-glx libprotobuf-dev gcc g++
git clone https://github.com/PaddlePaddle/FastDeploy.git
cd FastDeploy
如果您使用的是develop分支输入以下命令
git checkout develop
mkdir build && cd build
cmake … -DENABLE_ORT_BACKEND=OFF
-DENABLE_RKNPU2_BACKEND=ON
-DENABLE_VISION=ON
-DRKNN2_TARGET_SOC=RK3588
-DCMAKE_INSTALL_PREFIX=${PWD}/fastdeploy-0.0.0
make -j2
make install
FastDeploy提供了一键配置环境变量的脚本,在运行程序前,你需要执行以下命令
source fastdeploy-0.0.0/fastdeploy_init.sh
cd FastDeploy/examples/vision/detection/rkyolo/cpp
CMakeLists.txt文件的第7行进行了修改,如下
include(/home/forlinx/FastDeploy/build/fastdeploy-0.0.0/FastDeploy.cmake)
mkdir build && cd build
cmake … -DENABLE_ORT_BACKEND=OFF
-DENABLE_RKNPU2_BACKEND=ON
-DENABLE_VISION=ON
-DRKNN2_TARGET_SOC=RK3588
make -j8
wget https://gitee.com/paddlepaddle/PaddleDetection/raw/release/2.4/demo/000000014439.jpg
wget https://bj.bcebos.com/paddlehub/fastdeploy/rknpu2/yolov7-tiny.zip
unzip yolov7-tiny.zip
./infer_rkyolov7 yolov7-tiny/yolov7-tiny_tk2_RK3588_i8.rknn 000000014439.jpg