# Vein extraction from this image

I have this image:

What methods should I use to extract the veins from this image. Thank you.

• Have you tried anything? Jan 6, 2016 at 16:14

I would like to direct you to 3 references:

C. Steger: “Extracting Curvilinear Structures: A Differential Geometric Approach”. In B. Buxton, R. Cipolla, eds., “Fourth European Conference on Computer Vision”, Lecture Notes in Computer Science, Volume 1064, Springer Verlag, pp. 630-641, 1996.

C. Steger: “Extraction of Curved Lines from Images”. In “13th International Conference on Pattern Recognition”, Volume II, pp. 251-255, 1996.

C. Steger: “An Unbiased Detector of Curvilinear Structures”. IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998.

In these works, Steger develops a subpixel curvilinear structure extraction algorithm, which is found to work very well for such images. I have also run the algorithm on your images and here you go:

Lines visualized on original image

Lines only

I set the line thickness to 2 for better visualization, normal contours are at sub-pixel level.

• Do you have any implementation references for Steger's method? Jul 11, 2021 at 6:40
• Not that hard to implement actually. But MVTec's Halcon library should have an implementation of it. Though this is an expensive software. A partial open-source version (although suboptimal) is implemented here: github.com/songyuncen/EdgesSubPix. Note that this is just an edge detector, but uses similar ideas. Jul 12, 2021 at 5:09

For dealing with images like this in the past, I have always had good luck using the "Vesselness" filter designed by Frangi et al. It utilizes the eigenvectors of the Hessian to determine the probability of a given pixel belonging to a vessel. The code is available on the MATLAB File Exchange and using the default parameters I was able to get the following result.

img = imread('image.jpg');
img = 1 - (img(:,:,1) ./ max(max(img(:,:,1))));
f = FrangiFilter2D(img);


I would use a Gabor filter or a difference of gaussians.