Skip to content

kwencel/VesselsClassifier

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

38 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Blood vessel for retinal images using KNN classifier

(We used images from HRF database)

Instructions

First clone the repository:

git clone https://github.com/kwencel/VesselsClassifier.git

Next go to the root directory and run:

./gradlew fatJar

This will produce a jar with all dependencies.

Run the program with example images:

java -jar ./build/libs/VesselsClassifier-all-1.0-SNAPSHOT.jar ./Examples/training/ ./Examples/test/images/01_dr.JPG

This may take a while depending on your CPU. Results will be written to ./Examples/test/results

Manual segmentation

Input image Manualy labeled image

To achive same result without time-consuming manual segmentation we used our custom implementation of k Nearest Neighbours Classifier.

Preprocessing

First we extract green channel from input image as it has the highest contrast between the blood vessels and the retinal background. Next we equalize the histogram of the channel.

Classifier

Model was trained using 300 random balanced samples. We used 7 features -- Hu moments for 11 x 11 surrounding of each pixel. 11 neighbours proved to yield the best result.

Results

For 15 test inputs we achived average accuracy of 87,7%

About

A blood vessel KNN classifier for retinal images

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages