So I was browsing in the OpenCV documentation and I find a nice sample that uses opencv_dnn module for image classification by using GoogLeNet trained network from Caffe model zoo.
So I give it a try, and get a decent .Net 5 Winforms App running at ~30 FPS.
The model was trained with 1000 classes, and once you get the main focus on the camera it work great with objects like a machine, mug, bottle, etc. There is a nice amount of code here, and because the DNN analysis is performed in a separated thread, I need to update the label details using PInvoke functions.
Super fun ! and check the references for the model and support files download location.
More posts in my blog ElBruno.com.
- OpenCVSharp, https://github.com/shimat/opencvsharp
- Wikipedia, Canny Edge Detector
- OpenCV, Canny tutorial
- OpenCV, FAST tutorial
- Wikipedia, FAST
- OpenCV, Perform face detection using Haar Cascades
- OpenCV, Load Caffe framework models
- Caffe Model Zoo
Net 5 and OpenCV
- 13 lines to display a 🎦 camera feed with OpenCV and Net5
- Detecting edges on the 🎦 camera feed with Canny algorithm, OpenCV and Net5
- Detecting corners on the 🎦 camera feed with FAST algorithm, OpenCV and Net 5
- Display the 🎦 camera feed in a WinForm using OpenCV and Net5
- Face Detection using Face Cascades on the 🎦 camera feed using OpenCV and Net 5
- Face Detection using DNN on the 🎦 camera feed using OpenCV and Net 5
- Face Detection, DNN vs Haar Cascades on the 🎦 camera feed using OpenCV and Net 5
- Age and Gender estimation on the 🎦 camera feed using OpenCV and Net 5
- Caffe Model Zoo (GoogleNet) detection from the 🎦 camera feed using OpenCV and Net5
- Pose detection from the 🎦 camera feed using OpenCV and Net5
- Packaging a WinForm OpenCV and Net5 App in a one-self contained file
- Display a video file 🎥 in Winform using OpenCV and Net5
- Open a video file 🎥 and save each frame as a PNG 🖼 file to a folder 📂
- (Coming Soon) QR Codes detection on the 🎦 camera feed using OpenCV and Net 5