资源简介
基于论文ACCURATE EYE CENTRE LOCALISATION BY MEANS OF GRADIENTS的matlab实现,或者说是eyelike的matlab版
代码片段和文件信息
function c = MeanOfWeightedSquaredDotProducts(MWcmn)
[RC~] = size(M);
sum = 0;
for i = 1:R
for j = 1:C
if M(ij1)~=0
if i==m && j==n % (ij) = (mn) dp = 0;
sum = sum + 0;
else
d = ([M(ij2)M(ij3)] - [M(mn2)M(mn3)])/norm(([M(ij2)M(ij3)] - [M(mn2)M(mn3)])); %vector d
g = [M(ij4)M(ij5)]/norm([M(ij4)M(ij5)]); % vector g
dp = d*g‘; % calculate dot Products
% make nagetive dp equate to 0
if dp<0
dp = 0;
end
sum = sum + Wc(ij)*(dp^2);
end
else
% ignore smooth area
sum = sum + 0;
end
end
end
c = sum/numel(M(::1));
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 30123 2018-07-25 16:43 meansOfGriadientTofindeyeCenter\man.jpg
文件 817 2019-03-06 20:08 meansOfGriadientTofindeyeCenter\MeanOfWeightedSquaredDotProducts.asv
文件 823 2019-03-06 20:08 meansOfGriadientTofindeyeCenter\MeanOfWeightedSquaredDotProducts.m
文件 1198 2019-03-06 15:18 meansOfGriadientTofindeyeCenter\meansOfGriadientTofindeyeCenter.asv
文件 1484 2019-03-06 20:20 meansOfGriadientTofindeyeCenter\meansOfGriadientTofindeyeCenter.m
目录 0 2019-03-06 20:42 meansOfGriadientTofindeyeCenter
----------- --------- ---------- ----- ----
34445 6
评论
共有 条评论