-
Notifications
You must be signed in to change notification settings - Fork 5
/
main.m
36 lines (34 loc) · 835 Bytes
/
main.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
clc; clear all; close all; warning off;
%%
restoredefaultpath;
addpath(genpath(fullfile('.','libs')));
%%
srcDir = './input';
file = '832053.jpg';
%%
[~,name,~] = fileparts(file);
img = imread([srcDir '/' file]);
img = imresize(img,0.25);
disp(['Processing : ' name]);
tic;
[SymOcLgHSV,voteMap] = symBilOurCentLogGaborHSV(img);
toc;
%%
Num = 5;
MarkerEdgeColors=hsv(Num);
str = {};
mkSize = 10;
lnWidth = 2;
figure;
imshow(img); hold on;
for j=1:min(Num,size(SymOcLgHSV,1))
X = [SymOcLgHSV(j,1) SymOcLgHSV(j,3)];
Y = [SymOcLgHSV(j,2) SymOcLgHSV(j,4)];
plot(X,Y, '-s','Color',MarkerEdgeColors(j,:),...
'MarkerSize',mkSize,'LineWidth',lnWidth);
str{j} = [num2str(j) ' - ' num2str(SymOcLgHSV(j,5))];
end
legend(str,'Location','BestOutside');
hold off;
%%
figure,imagesc(voteMap); colormap('jet'); axis off;