I have made an CBIR system in MATLAB and have used similarity measurement as euclidean distance. Using this for each query image I retrieve top 20 images.
I have used WANG Dataset for testing my system.
It contains 10 classes(like African people, Buses, Roses etc.) each containing 100 images.(1000 images in total).
My Method:
1. I am using Correlogram, Co-occurence Matrix(CCM) and Difference between Pixel Scan Pattern(DBPSP) for constructing my vector(64+196+28=288 dimensions respectively).
- Each of the 1000 db image I have its vector constructed beforehand.
- Now a query image comes and I construct it's vector too(228 dimensions again).
- I use Euclidean Distance for similarity and sort db image vectors in descending order of their euclid distance.
Top 20 results are shown.
In those 20 I can have TP or FP.
For a single query image I can easily calculate Precision and Recall and plot PR-curve using this link.
How can I do the same for whole class?
My Approach: For each image belonging to class A find top 20 images and it's respective TP(true positives) and FP (False Positive).
TP FP
Image1 17 3
Image2 15 5
...
...
Image100 10 10
Total 1500 500
Precision of Class A =1500/(2000) = .75 (Is it right??)
Recall of Class A ---> Stuck ??
PR-Curve ----> Stuck ?? Some links said I need a classifier for that and some not... I am really confused.