How to improve blob detection rate?
Hello,
I want to detect Retinal Microaneurysm from a retina fundus image.
So far I used the SimpleBlobDetector
with customized parameters:
#include <opencv2/opencv.hpp>
using namespace cv;
using namespace std;
// Image matrices
Mat src, dst;
// Blob detector parameters
SimpleBlobDetector::Params params;
int main(int argc, char **argv) {
src = imread(argv[1], IMREAD_GRAYSCALE);
params.minThreshold = 0.4;
params.filterByArea = true;
params.minArea = 14;
params.maxArea = 10000;
params.filterByConvexity = true;
params.minConvexity = 0.8;
// Coordinate array
vector<KeyPoint> keypoints;
SimpleBlobDetector::create(params)
->detect(src, keypoints);
drawKeypoints(src, keypoints, dst, Scalar(0, 255, 0), DrawMatchesFlags::DRAW_RICH_KEYPOINTS);
imwrite(argv[2], dst);
return 0;
}
The result is:
It is not bad to start with but unfortunately the there are a lot (especially bigger) points which are not detected at all.
As was not able to achieve improvements by optimizing SimpleBlobDetector::Params
I would like to know what I can do else to improve detection rate.
Best Bodo
You can try out k-means segmentation. Here are few links,
http://www.pyimagesearch.com/2014/05/...
http://www.bogotobogo.com/python/Open...
http://stackoverflow.com/questions/20...
https://github.com/Itseez/opencv/blob...
applying also some pre-processing filters, morphological operations in order to acute the contours of the blobs would help as well.