image thumbnail

Fast GMM and Fisher Vectors

by

 

27 Sep 2012 (Updated )

Fast GMM (diagonal covariances only) with Kmeans initialization and Fisher Vectors

gen_weight(patch_size , nbin)
function weight    = gen_weight(patch_size , nbin)

if(nargin < 1)
    patch_size = 9;
end
if(nargin < 2)
    nbin       = 4;
end

r             = patch_size/2;
cx            = r - 0.5;
sample_res    = patch_size/ nbin;
weight        = abs((1:patch_size) - cx)/sample_res;
weight        = (1 - weight) .* (weight <= 1);

Contact us