How to extract Vein Pattern from these images in Opencv?

1.2k Views Asked by At

I want to extract the vein patterns from the attached images. I am trying to code a Vein pattern recognition system. I tried the Canny Edge Detector for getting the edges of the veins but somehow they are not very clear. Any improvisations or other techniques would be greatly appreciated. For information, I am trying to write a C++ Code in OpenCV on Ubuntu.

ROI
ROI
Source
Source
Canny
Canny

2

There are 2 best solutions below

1
On

You should try some thresholding methods. There are some that are adaptive and region based. You could also try using some other kernels other than the standard Canny kernels. How you proceed is heavily dependent on how you want to use the output and what the other images look like in comparison.

1
On

I doubt that simple thresholding or edge detection methods will work reliably - I expect that you will have to tune them individually to each image. With respect to thresholding you will definitely have to look at adaptive methods.

You could try to apply a band-pass filter tuned for the frequency band of the veins to get a more normalised image, i.e. an image where the gray level of "vein" and "background" is more similar over the image. This could make subsequent thresholding steps more reliable.

I think an industry-strength solution would have to use something more sophisticated than simple image processing tools.