我们的目标是无法运行 Matlab 的嵌入式系统上的 Linux。
我们有计算机视觉 Matlab 脚本原型(prototype),并希望将此功能(Vision.blobAnalysis)移植到嵌入式。
两种选择:使用 Matlab CODER 将 Matlab 计算机视觉功能移植到嵌入式,或在嵌入式系统上使用 openCV 重现功能。
最佳答案
尝试一个简单的 Blob 检测器:
using namespace cv;
// Read image
Mat im = imread( "blob.jpg", IMREAD_GRAYSCALE );
// Set up the detector with default parameters.
SimpleBlobDetector detector;
// Detect blobs.
std::vector<KeyPoint> keypoints;
detector.detect( im, keypoints);
// Draw detected blobs as red circles.
// DrawMatchesFlags::DRAW_RICH_KEYPOINTS flag ensures the size of the circle corresponds to the size of blob
Mat im_with_keypoints;
drawKeypoints( im, keypoints, im_with_keypoints, Scalar(0,0,255), DrawMatchesFlags::DRAW_RICH_KEYPOINTS );
// Show blobs
imshow("keypoints", im_with_keypoints );
waitKey(0);
关于matlab - OpenCV 中是否有与 Matlab Vision.blobAnalysis() 功能相同的函数?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32097839/