转载请注明出处!
转载请注明出处!
转载请注明出处!

项目代码链接:https://github.com/pengtougu/Push-Streaming.git

已经两三点了,太困了,直接github上的readme复制过来,周末有点无聊,做了一个推拉流的demo,共四个功能:
①图片推理
②视频推理和保存
③摄像头本地推理(不加保存了,有点费内存)
④移动端(树莓派,或其他开发板)调用摄像头并对流帧进行推理,通过flask推流到局域网,局域网下的其他设备拉流并显示在web页面上

代码基本不用改,down下来即可运行,已在window&mac&linux三种平台上测试过,代码通用。推拉流那个,请保证在同个局域网下!!!

目前只做了yolo-fastest的demo,对nanodet感兴趣,后续会持续更新!

项目代码链接:https://github.com/pengtougu/Push-Streaming.git

Push-Streaming

Hi, this repository documents the process of pushing streams on some ultra-lightweight nets. The general steps are that opencv calls the board(like Raspberry Pi)'s camera, transmits the detected live video to an ultra-lightweight network like yolo-fastest, nanodet, ghostnet, and then talks about pushing the processed video frames to the web using the flask lightweight framework, which basically guarantees real-time performance.

在这里插入图片描述

Requirements

Please install the following packages first

  • Linux & MacOS & window
  • python>= 3.6.0
  • opencv-python>= 4.2.X
  • flask>= 1.0.0

inference

EquipmentComputing backendSystemFrameworkRun time
Raspberrypi 3B4xCortex-A53Linux(arm64)dnn89ms
IntelCore i5-4210window10(x64)dnn67ms

Demo

First of all, I have tested this demo in window, mac and linux environments and it works in all of them.

拉下来的同学先看下文件全不全:

在这里插入图片描述

  • Inference images

python yolov3_fastest.py --image dog.jpg

  • Inference video

python yolov3_fastest.py --video test.mp4

  • Inference webcam

python yolov3_fastest.py --fourcc 0

  • Push-Streaming

python app.py
请确保你的树莓派已经安装好摄像头的驱动了,并且板子和本地机连的是同个WiFi
请确保你的树莓派已经安装好摄像头的驱动了,并且板子和本地机连的是同个WiFi
请确保你的树莓派已经安装好摄像头的驱动了,并且板子和本地机连的是同个WiFi

Please note! Be sure to be on the same LAN!

Demo Effects

Thanks

备注

一年没写博客了,这一年真的遇到了超级多大佬,还是感叹要学的东西实在是太多了

在这里插入图片描述

Logo

更多推荐