- 博客(65)
- 资源 (5)
- 收藏
- 关注
原创 OpenCVSharp 笑脸检测
利用Harra Cascade分类器进行人脸检测和进一步进行笑脸检测,采用训练好的分类模型,在OpenCVSharp里变得非常简单,两三条语句就搞定了:CascadeClassifier face_cascade = new CascadeClassifier(facemodelfile); //创建一个人脸分类器face_cascade .DetectMultiScale(image); //检测人脸CascadeClassifier smile_cascade = new Cas...
2021-08-04 21:00:38
1066
原创 OpenCVSharp中的目标跟踪
众所周知,OpenCV提供了8种目标跟踪算法,它们是:BOOSTING MIL KCF TLD MEADIANFLOW GOTURN MOSSE CSRT而OpenCVSharp(4.5x)中,实现了常用的四种:MIL、KCF、GOTURN、CSRT。具体而言,它们是在OpenCVSharp.Tracking命名空间下的 TrackerCSRT, TrackGOTURN, TrackerKCF, TrackerMIL等类。这些跟踪器用法几乎是一模一样的,基本上是先用 Cre...
2021-08-03 14:48:32
2093
原创 OpenCVSharp 使用 Yolo V3 模型进行视频目标检测和分类
首先下载Yolo训练好的模型:https://pjreddie.com/media/files/yolov3.weights共3个文件:yolov3.cfg,yolov3.weights,coco.namesusing System.Collections.Generic;using System.IO;using System.Linq;using OpenCvSharp;using OpenCvSharp.Dnn;namespace OpenCvSharpYolo3{ ...
2021-07-30 17:15:56
2351
5
原创 C# PictureBox 显示视频的问题
C#用OpenCVSharp开发视频处理应用,通常用 PictureBox循环显示图片(视频帧)来显示视频。比如:VideoCapture capture = new VideoCapture(0);Mat image = new Mat();while (true){ capture.Read(image); if(image.Empty()) break; pictureBox1.Image = image.ToBitmap();...
2021-07-28 17:39:22
3164
1
原创 OpenCVSharp 背景消除
用OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV官方教程链接:OpenCV: How to Use Background Subtraction Methodsusing System;using OpenCvSharp; using System.Linq;using System.Text;using System.Threading.Tasks;namespace ConsoleApp1{ class tutorial61:IT...
2021-07-23 17:08:25
1592
1
原创 OpenCVSharp 图像拼接
用 OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV官方教程链接:OpenCV: High level stitching API (Stitcher class)using OpenCvSharp;using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;namespace Cons...
2021-07-23 14:21:19
2298
2
原创 OpenCVSharp 生成 HDR 图片
用OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV官方教程链接:OpenCV: High Dynamic Range Imaging测试图片可以从这里下载:github.comusing System;using OpenCvSharp;using System.Linq;using System.Text;using System.Threading.Tasks;using System.Collections.Generic;namesp...
2021-07-23 11:16:08
735
1
原创 OpenCVSharp 相机棋盘格校正
用OpenCVSharp 4.5跑一遍 OpenCV官方教程。原OpenCV 官方教程链接:OpenCV: Camera calibration With OpenCV这个教程的程序源码比较复杂,这里简化一下以集中精力在核心的校正部分:只限于用棋盘格图片校正,本来就少量几个参数直接写进程序里,免去xml文件读写的麻烦。using System;using OpenCvSharp;using System.Linq;using System.Text;using System...
2021-07-22 21:37:42
2968
4
原创 OpenCVSharp DNN - 使用Caffe框架模型
用OpenCVSharp(4.5)跑一遍OpenCV官方教程。原OpenCV官方教程链接:OpenCV: Load Caffe framework modelsusing System;using OpenCvSharp;using System.Linq;using System.Text;using System.Threading.Tasks;using OpenCvSharp.Dnn;using System.IO;namespace ConsoleApp1...
2021-07-20 10:52:28
1665
1
原创 OpenCVSharp 4.5 相机位移之单应性矩阵
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Basic concepts of the homography explained with code(Demo3)using System;using System.Collections.Generic;using OpenCvSharp;namespace ConsoleApp1{ class tutorial56 : ITutorial { ...
2021-07-19 21:29:38
1206
1
原创 OpenCVSharp 4.5 单应性矩阵 - 全景照片拼接
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:似乎网站宕机了using System;using OpenCvSharp;using System.Linq;using System.Text;using System.Threading.Tasks;namespace ConsoleApp1{ class tutorial55 : ITutorial { private void basicPan...
2021-07-19 16:22:44
504
1
原创 OpenCVSharp 4.5 单应性矩阵 - 透视校正
用 OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV官方教程链接:挂啦(2021-7-19)using System;using OpenCvSharp;using System.Linq;using System.Text;using System.Threading.Tasks;namespace ConsoleApp1{ class tutorial54 : ITutorial { enum Pattern { ...
2021-07-19 14:11:24
806
原创 OpenCVSharp 4.5 单应性矩阵(Homography)估计相机姿态
用OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV 官方 教程链接:(今天链接失效了?)Demo 1using System;using System.Collections.Generic;using OpenCvSharp;namespace ConsoleApp1{ class tutorial52 : ITutorial { enum Pattern { CHESSBOARD, CIRCLES_GRID, ASYM...
2021-07-18 21:47:44
904
原创 OpenCVSharp 4.5 AKAZE、ORB 平面追踪
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: AKAZE and ORB planar trackingusing System;using System.Collections.Generic;using OpenCvSharp;namespace ConsoleApp1{ class tutorial51 : ITutorial { public void Run() { ...
2021-07-17 21:53:43
825
原创 OpenCVSharp 4.5 AKAZE 特征匹配
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: AKAZE local features matchingusing System;using System.Collections.Generic;using OpenCvSharp;using OpenCvSharp.XFeatures2D;namespace ConsoleApp1{ class tutorial50:ITutorial { ...
2021-07-16 21:17:40
610
原创 OpenCVSharp 4.5 定位已知物体(Features2D+Homography)
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Features2D + Homography to find a known object核心函数:cv::findHomography cv::perspectiveTransformusing System;using OpenCvSharp;using System.Collections.Generic;using System.Linq;using Sys...
2021-07-16 21:13:56
1900
原创 OpenCVSharp 4.5 特征匹配
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Feature Description核心要点:使用 DescriptorExtractor接口方法找到关键点的特征向量 使用 xfeatures2d::SURF::compute to进行计算 使用 DescriptorMatcher来匹配特征向量 使用 drawMatches 画出匹配点using System;using OpenCvSharp;using...
2021-07-16 10:12:11
1597
原创 OpenCVSharp 4.5 特征检测
用OpenCVSharp 4.5跑一遍OpenCV官方教程。原OpenCV 官方教程链接:OpenCV: Feature Detection核心函数:cv::FeatureDetector cv::xfeatures2d::SURF cv::xfeatures2d::SURF::detect cv::drawKeypointsusing System;using OpenCvSharp;using OpenCvSharp.XFeatures2D;namespace C...
2021-07-15 11:06:57
546
原创 OpenCVSharp 4.5 在子像素中检测角点
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Detecting corners location in subpixels核心函数:cv::cornerSubPixusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial46 : ITutorial { static Mat src, src_gray = ...
2021-07-15 10:52:37
380
原创 OpenCVSharp 4.5 角点检测-自己的检测函数
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Creating your own corner detector核心函数:cv::cornerEigenValsAndVecs,cv::cornerMinEigenValusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial45 : ITutorial { st...
2021-07-14 09:58:25
459
原创 OpenCVSharp 4.5 Shi-Tomasi 角点检测
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Shi-Tomasi corner detector核心函数:cv::goodFeaturesToTrackusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial44 : ITutorial { static Mat src = new Mat(), src_g...
2021-07-13 17:41:17
430
原创 OpenCVSharp 4.5 Harris角点检测
用 OpenCVSharp4.5跑一遍OpenCV官方教程。原OpenCV 官方教程链接:OpenCV: Harris corner detector核心函数:cv::cornerHarrisusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial43 : ITutorial { static int thresh = 200; static ...
2021-07-13 14:47:50
967
原创 OpenCVSharp 4.5 PCA 主成分分析
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV 官方教程链接:Introduction to Principal Component Analysis (PCA)核心函数:PCAusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial42 : ITutorial { public void Run() { ...
2021-07-13 14:27:22
452
原创 OpenCVSharp 4.5 非线性分布数据支持向量机
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:Support Vector Machines for Non-Linearly Separable Datausing System;using OpenCvSharp;using OpenCvSharp.ML;namespace ConsoleApp1{ class tutorial41 : ITutorial { public void Run() ...
2021-07-12 13:44:30
274
原创 OpenCVSharp 4.5 SVM支持向量机简介
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Introduction to Support Vector Machines核心函数:OpenCVSharp.ml.svm.Train() OpenCVSharp.ml.svm.Predict()using System;using OpenCvSharp;using OpenCvSharp.ML;namespace ConsoleApp1{ class tuto...
2021-07-11 21:38:12
722
原创 OpenCVSharp 4.5 人脸检测 - Cascade 分类器
用OpenCVSharp 4.5跑一遍 OpenCV 官方教程。原OpenCV官方教程链接:OpenCV: Cascade Classifier核心函数:CascadeClassifier CascadeClassifier::load CascadeClassifier::detectMultiScaleusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial39 : ITutoria...
2021-07-11 11:16:50
1093
原创 OpenCVSharp 4.5 光流
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Optical Flow核心函数:cv.calcOpticalFlowPyrLK()、cv.calcOpticalFlowFarneback()using System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial38 : ITutorial { public void Run()..
2021-07-10 21:08:32
535
原创 OpenCVSharp 4.5 视频目标追踪 - meanshift算法
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Meanshift and Camshift核心函数:meanShiftusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial37 : ITutorial { public void Run() { string filenam...
2021-07-08 15:31:01
676
原创 OpenCVSharp 4.5 生成视频
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Creating a video with OpenCVusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial35 : ITutorial { public void Run() { string inputVideofile = @"I:..
2021-07-07 13:06:12
521
原创 OpenCVSharp 4.5 视频相似性分析
用 OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Video Input with OpenCV and similarity measurementusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial34 : ITutorial { public void Run() { int ps..
2021-07-06 21:10:59
330
原创 OpenCVSharp 4.5 去除周期性噪声
用OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Periodic Noise Removing Filter原作者有意埋了坑,完全照抄是不行的.......using System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial33 : ITutorial { public void Run() { ...
2021-07-06 13:43:56
729
原创 OpenCVSharp 4.5 图像分割(各向异性、梯度结构张量)
用OpenCVSharp 4.5跑一遍OpenCV官方教程原OpenCV官方教程链接:OpenCV: Anisotropic image segmentation by a gradient structure tensorusing OpenCvSharp;using System;namespace ConsoleApp1{ class tutorial32 : ITutorial { public void Run() {...
2021-07-05 11:57:38
831
原创 OpenCVSharp 4.5 去除运动模糊
用OpenCVSharp 4.5跑一遍 OpenCV官方教程原官方教程链接:OpenCV: Motion Deblur Filter注:下面的程序运行是没问题的,遗憾的是我并没有找到一组合适的参数来重现原教程的效果,原OpenCV (c++)程序也是如此。(这种问题似乎很常见)using OpenCvSharp;using System;namespace ConsoleApp1{ class tutorial31 : ITutorial { ..
2021-07-05 10:28:29
1384
原创 OpenCVSharp 4.5 去离焦模糊
用OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Out-of-focus Deblur Filterusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial30 : ITutorial { public void Run() { int R = 6 ; //计算PSF参数:R(半径)...
2021-07-04 09:26:27
762
1
原创 OpenCVSharp 4.5 图像分割(距离变换和分水岭算法)
用OpenCVSharp 4.5跑一遍 OpenCV 官方教程原OpenCV官方教程链接:OpenCV: Image Segmentation with Distance Transform and Watershed Algorithm核心函数:cv::filter2D distanceTransform watershedusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial29...
2021-07-03 14:46:53
1462
原创 OpenCVSharp 4.5 点多边形
用OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Point Polygon Test核心函数:pointPolygonTestusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial28 : ITutorial { public void Run() { int r = 100; .
2021-07-03 12:09:59
441
原创 OpenCVSharp 4.5 图像矩
用OpenCVSharp 4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Image Moments核心函数:moments contourArea arcLengthusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial27 : ITutorial { static Mat src_gray = new Mat(); static..
2021-07-01 14:00:49
408
原创 OpenCVSharp 4.5 轮廓边框(旋转矩形和椭圆)
用OpenCVSharp4.5跑一遍OpenCV官方教程原官方教程链接:OpenCV: Creating Bounding rotated boxes and ellipses for contours核心函数:minAreaRect,fitEllipseusing System;using OpenCvSharp;namespace ConsoleApp1{ class tutorial26 : ITutorial { static Mat src_.
2021-07-01 13:35:44
1836
stm32CubeIDE 1.8 自动补全插件
2021-11-29
OpenCVSharpTrackingObject.rar
2021-08-03
Google开源GPS轨迹记录软件 MyTracks源码
2012-05-24
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人