how can find altered pixels

1 view (last 30 days)
Hi Dears I have two images the first is the original while the second is the watermarked image. I altered some pixels in the watermarked image , then I extracted the watermark from the altered image and compared with the original wateremark using MSE , I couldnt find the exact altered pixels, also I want a way to calculate the values of False positive (FP), false negative (FN) and average of detection rate . with many thanks

Accepted Answer

Walter Roberson
Walter Roberson on 31 Aug 2015
Edited: Walter Roberson on 31 Aug 2015
idx = find(OriginalImage ~= WaterMarkedImage);
[coords{1:ndims(OriginalImage)}] = ind2sub(size(OriginalImage), idx);
row_col_plane_idx = cell2mat(coords);
Now row_col_plane_idx(K,1) is a row number of a mismatch, row_col_plane_idx(K,2) is the corresponding column, row_col_plane_idx(K,3) is the corresponding color plane (R, G, B)
  3 Comments
Walter Roberson
Walter Roberson on 31 Aug 2015
I made a small correction, ndims instead of ndim
qasim mohammed
qasim mohammed on 31 Aug 2015
okay, it run , many thanks

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!