Roc curve for image segmentation

Hello !
I have been trying to draw ROC curve for my segmented image ...
I have Ground truth image and my segmented image ...
Now i want to draw ROC curve ,,i have gone through many threads but i couldnot understand the basic theme of TRue positive,false positive,false negative and true negative.... ..
I have Dice similarity coefficient of say 5 images
0.94 0.77 0.85 0.89 0.93
and ground truth images
Is there any code or suggestion on how to calculate different rates and draw ROC ???
What i read on google,most of the threads says that ROC curve required a classifier ..but in my case there is no classifier ..so what to do ?
Also how to calcualte the pixels which are not a part of the background or object ???

2 Comments

Please attach your ground truth segmentation image and your "test" image segmentation. Where they match is a true positive or true negative, and where they don't match is a false positive or false negative. And how many classes do you have? Just two - foreground and background - or do you have more?

Sign in to comment.

Answers (1)

Thorsten
Thorsten on 29 Aug 2016
Edited: Thorsten on 31 Aug 2016
For a ROC curve you need a binary ground truth and a continuous-valued segmented images; this image is usually the output of an operator or classifier that you've run on the original image. Then you threshold the continuos-valued output image of the classifier at various values, compute true-positive and false-positives for each threshold, and finally plot tp against fp, starting with the highest threshold.
If you have a binary ground truth and a binary segmented image, you cannot compute an ROC.

4 Comments

Ok i got that point
I have binary ground truth image and binary segmented image ..Can u please suggest some other method that can be used as equivalent to ROC ????
Also i wanna know if it possible to use my similarity measure (which are overlapping scores like 98.3 ,89.7 etc ) as a continous level and set my threshold to 70 ... if overlapping score is less than 70 than it would be 0 otherwise 1 ...
would it be acceptable?
As I said, you cannot use ROC if both images are binary.
Hi Thorsten, I want to generate precision recall curve. I have binary ground truth and continuous valued segmented image. Please guide me how can I do this. Can you help me get the code please? Here is my question: https://www.mathworks.com/matlabcentral/answers/316327-evaluate-the-quality-of-image-using-region-based-precision-and-recall

Sign in to comment.

Asked:

on 29 Aug 2016

Commented:

on 11 Apr 2017

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!