资源简介
基于低秩表示的运动分割与人脸聚类的matlab代码
代码片段和文件信息
function [acc] = compacc(idxgnd)
%inputs:
% idx -- the clustering results
% gnd -- the groudtruth clustering results
%outputs:
% acc -- segmentation accuracy (or classification accuracy)
str = ‘“compacc.m“ is to approximate the segmentation accuracy. It is not definitely accurate. Please use “missclassGroups.m“ if your subspace number is not very large ‘;
warning(str);
if size(idx2)>1
idx = idx‘;
end
if size(gnd2)>1
gnd = gnd‘;
end
uids = unique(idx);
idx = idx;
for i=1:length(uids)
uid = uids(i);
inds = abs(idx-uid)<0.1;
vids = gnd(inds);
uvids = unique(vids);
vf = 0;
for j=1:length(uvids)
vfj = sum(abs(vids-uvids(j))<0.1);
if vfj>vf;
vid = uvids(j);
vf = vfj;
end
end
idx(inds) = vid
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2011-08-28 11:25 code2\
文件 846 2013-04-21 06:27 code2\compacc.m
文件 154 2010-09-05 17:25 code2\loadmatfile.m
文件 2050 2011-07-28 19:07 code2\lrra.m
文件 814 2013-04-21 06:53 code2\lrr_face_seg.m
文件 1852 2011-08-14 18:25 code2\lrr_motion_seg.m
文件 1179 2010-10-13 19:28 code2\missclassGroups.m
文件 98 2011-08-14 18:24 code2\solve_lrr.m
文件 2270616 2010-09-06 22:10 code2\yaleb10.mat
评论
共有 条评论