RK3588安装rknn-toolkit-lite2 一、下载rknn-toolkit2包:
sudo git clone https://gitclone.com/github.com/airockchip/rknn-toolkit2
二、安装
进入到所在包的位置,然后解压:
unzip rknn-toolkit2-master.zip
进入rknn-toolkit-lite2所在路径:
cd rknn-toolkit2-master/rknn-toolkit-lite2/packages/
安装对应的版本:
pip install rknn_toolkit_lite2-2.0.0b0-cp38-cp38-linux_aarch64.whl
(注:这里的架构是aarch64,所以安装rknn-toolkit-lite2,如果是其他的架构选择安装rknn-toolkit2)
三、测试
cd rknn-toolkit2-master/rknn-toolkit-lite2/examples/resnet18/
python test.py
报错,安装cv2
pip install opencv-python -i https://mirrors.aliyun.com/pypi/simple/
再运行:
python test.py
再次报错:/usr/lib/librknnrt.so: undefined symbol: rknn_set_core_mask
此时更新rknn_server和librknnrt.so
cd rknn-toolkit2-master/rknpu2/runtime/Linux/
sudo cp librknn_api/aarch64/librknnrt.so /usr/lib
sudo cp -r rknn_server /aarch64/usr/bin/. /usr/bin
再次 运行上述的test.py
python test.py
成功!!!
标签:rknn,lite2,toolkit2,aarch64,toolkit,安装 From: https://www.cnblogs.com/6S6B/p/18348830