# YoloV5 NPU

## YoloV5 for RK3566/68/88 NPU (Rock 5, Orange Pi 5, Radxa Zero 3). <br/>
[](https://opensource.org/licenses/BSD-3-Clause)<br/><br/>
Paper: https://towardsdatascience.com/yolo-v5-is-here-b668ce2a4908<br/><br/>
Special made for the NPU, see [Q-engineering deep learning examples](https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html)
------------
## Model performance benchmark (FPS)
All models, with C++ examples can be found on the SD images.<br><br>
 [Rock 5 with **Ubuntu 22.04**, OpenCV, ncnn and **NPU**](https://github.com/Qengineering/Rock-5-Ubuntu-22-image)<br><br>
 [Radxa Zero 3 with **Ubuntu 22.04**, OpenCV, ncnn and **NPU**](https://github.com/Qengineering/Radxa-Zero-3-NPU-Ubuntu22)<br><br>
All models are quantized to **int8**, unless otherwise noted.<br>
| demo | model_name | RK3588 | RK3566/68 |
| ---------------- | ---------------------------- | :-----: | :--------: |
| yolov5 | yolov5s_relu | 50.0 | 14.8 |
| | yolov5n | 58.8 | 19.5 |
| | yolov5s | 37.7 | 11.7 |
| | yolov5m | 16.2 | 5.7 |
| yolov6 | yolov6n | 63.0 | 18.0 |
| | yolov6s | 29.5 | 8.1 |
| | yolov6m | 15.4 | 4.5 |
| yolov7 | yolov7-tiny | 53.4 | 16.1 |
| | yolov7 | 9.4 | 3.4 |
| yolov8 | yolov8n | 53.1 | 18.2 |
| | yolov8s | 28.5 | 8.9 |
| | yolov8m | 12.1 | 4.4 |
| yolov10 | yolov10n | 35.1 | 12.5 |
| | yolov8s | 23.4 | 7.3 |
| | yolov8m | 9.7 | 3.4 |
| | yolov8x | 5.1 | 1.8 |
| yolox | yolox_s | 30.0 | 10.0 |
| | yolox_m | 12.9 | 4.8 |
| ppyoloe | ppyoloe_s | 28.8 | 9.2 |
| | ppyoloe_m | 13.1 | 5.04 |
| yolov5_seg | yolov5n-seg | 9.4 | 1.04 |
| | yolov5s-seg | 7.8 | 0.87 |
| | yolov5m-seg | 6.1 | 0.71 |
| yolov8_seg | yolov8n-seg | 8.9 | 0.91 |
| | yolov8s-seg | 7.3 | 0.87 |
| | yolov8m-seg | 4.5 | 0.7 |
| ppseg | ppseg_lite_1024x512 | 27.5 | 2.4 |
| RetinaFace | RetinaFace_mobile320<sup>1</sup> | 243.6 | 88.5 |
| | RetinaFace_resnet50_320<sup>1</sup> | 43.4 | 11.8 |
| PPOCR-Det | ppocrv4_det<sup>2</sup> | 31.5 | 15.1 |
| PPOCR-Rec | ppocrv4_rec<sup>3</sup> | 35.7 | 17.3 |
<sup>1</sup> Input size 320x320<br>
<sup>2</sup> Input size 480x480<br>
<sup>3</sup> Input size 48x320, FP16<br>
* Due to the pixel-wise filling and drawing, segmentation models are relatively slow
------------
## Dependencies.
To run the application, you have to:
- OpenCV 64-bit installed.
- Optional: Code::Blocks. (```$ sudo apt-get install codeblocks```)
### Installing the dependencies.
Start with the usual
```
$ sudo apt-get update
$ sudo apt-get upgrade
$ sudo apt-get install cmake wget curl
```
#### OpenCV
Follow the Raspberry Pi 4 [guide](https://qengineering.eu/install-opencv-on-raspberry-64-os.html).<br>
#### RKNPU2
```
$ git clone https://github.com/airockchip/rknn-toolkit2.git
```
We only use a few files.
```
rknn-toolkit2-master
│
└── rknpu2
│
└── runtime
│
└── Linux
│
└── librknn_api
├── aarch64
│ └── librknnrt.so
└── include
├── rknn_api.h
├── rknn_custom_op.h
└── rknn_matmul_api.h
$ cd ~/rknn-toolkit2-master/rknpu2/runtime/Linux/librknn_api/aarch64
$ sudo cp ./librknnrt.so /usr/local/lib
$ cd ~/rknn-toolkit2-master/rknpu2/runtime/Linux/librknn_api/include
$ sudo cp ./rknn_* /usr/local/include
```
Save 2 GB of disk space by removing the toolkit. We do not need it anymore.
```
$ cd ~
$ sudo rm -rf ./rknn-toolkit2-master
```
------------
## Installing the app.
To extract and run the network in Code::Blocks <br/>
```
$ mkdir *MyDir* <br/>
$ cd *MyDir* <br/>
$ git clone https://github.com/Qengineering/YoloV5-NPU.git <br/>
```
------------
## Running the app.
You can use **Code::Blocks**.
- Load the project file *.cbp in Code::Blocks.
- Select _Release_, not Debug.
- Compile and run with F9.
- You can alter command line arguments with _Project -> Set programs arguments..._
Or use **Cmake**.
```
$ cd *MyDir*
$ mkdir build
$ cd build
$ cmake ..
$ make -j4
```
Make sure you use the model fitting your system.<br><br>
More info or if you want to connect a camera to the app, follow the instructions at [Hands-On](https://qengineering.eu/deep-learning-examples-on-raspberry-32-64-os.html#HandsOn).<br/><br/>

------------
[](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=CPZTM5BB3FCYL)
没有合适的资源?快使用搜索试试~ 我知道了~
温馨提示
YoloV5网络处理器YoloV5 适用于 RK3566/68/88 NPU(Rock 5、Orange Pi 5、Radxa Zero 3)。论文https://towardsdatascience.com/yolo-v5-is-here-b668ce2a4908 专为 NPU 制作,请参阅Q 工程深度学习示例模型性能基准(FPS)所有模型以及 C++ 示例均可在 SD 图像上找到。Rock 5 搭载Ubuntu 22.04、OpenCV、ncnn 和NPU Radxa Zero 3 搭载Ubuntu 22.04、OpenCV、ncnn 和NPU除非另有说明, 所有模型均量化为int8 。演示 模型名称 RK3588 RK3566/68yolov5 yolov5s_relu 50.0 14.8 yolov5n 58.8 19.5 yolov5s 37.7 11.7 yolov5m 16.2 5.7yolov6 yolov6n 63.0 18.0 yolov6s 29.5 8.1 yolov6m 15.4 4.5yolov7
资源推荐
资源详情
资源评论





















收起资源包目录





























共 23 条
- 1
资源评论


赵闪闪168
- 粉丝: 1745
上传资源 快速赚钱
我的内容管理 展开
我的资源 快来上传第一个资源
我的收益
登录查看自己的收益我的积分 登录查看自己的积分
我的C币 登录后查看C币余额
我的收藏
我的下载
下载帮助


最新资源
- Android Course Work-移动应用开发资源
- python教案.pdf
- 网络技术及应用课件电子教案课件整套教学课件.pptx
- 本科毕业论文:LDPC码的编译码算法研究.pdf
- 网络营销教案完整版讲义.doc
- 史丰收速算法是以史丰收教授的名字命名的.pdf
- 数学教案-小数的连除、除加、除减混合运算和简便算法.docx
- 泸州市十郎区块链同城网人事管理系统.doc
- 项目管理理论的重大科技模式研究.doc
- 自动化生产实习心得体会.docx
- 银行软件测试面试题目.docx
- 学校网络规划投标书.doc
- 网络课程设计标准市公开课一等奖百校联赛优质课金奖名师赛课获奖课件.ppt
- 陕西省项目管理师报考条件.docx
- 使用正版软件自查报告.docx
- 武汉大学网络营销().pptx
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈



安全验证
文档复制为VIP权益,开通VIP直接复制
