开发者

Using skewness and kurtosis functions in image matching

开发者 https://www.devze.com 2023-02-11 09:44 出处:网络
I am using the skewness and kurtosis functionsfor image color Histogram in image retrieval system as a statisticalcolor features then using these features to compare between two images to retrieve the

I am using the skewness and kurtosis functions for image color Histogram in image retrieval system as a statistical color features then using these features to compare between two images to retrieve the similarity images....but I get 'NaN' value in some results which is causes an error in image retrieval process:

S=double(imread('im.jpg');
         R=S(:,:,1)/64;      R1=floor(R);  
         G=S(:,:,2)/64;      G1=floor(G);
         B=S(:,:,3)/64;      B1=floor(B);
 [rr cc c]=size(R1); 
         ImageHist = zeros(4,4,4);
              for row = 1 :rr
                      for col = 1:cc
                 开发者_如何学编程           ImageHist(R1(row,col)+1, G1(row,col)+1,B1(row,col)+1 )= ImageHist(R1(row,col)+1, G1(row,col)+1,B1(row,col)+1)+1;                   
                     end
              end

             ImageHist = ImageHist/(rr*cc);

then I compute the Kurtosis as:

QKurColHis = kurtosis(ImageHist);

I make the same thing to second function (skewness)

It is suitable to use this function to the color histogram to extract color feature? then using it in image retrieval?

if it is OK, how can I correct this Error, how can I remove the NaN values from my mat.file?

I want to use these function as image features in matching between color images... any one please could help me to solve this problem?


I don't know how the builtin kurtosis function is working but it might be that you have to supply it a vector instead of 3D matrix as an input

kurtosis(ImageHist(:))

Apart from the NaN problem, kurtosis and skewness give you some info about statistical distribution of the data in ImageHist so they could be treated as some image features. But how good will they perform in image matching is hard to say.

0

精彩评论

暂无评论...
验证码 换一张
取 消