-
Notifications
You must be signed in to change notification settings - Fork 36
/
run_results.m
53 lines (49 loc) · 1.96 KB
/
run_results.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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
% run all settings and calculate from scratch
%
% Copyright 2011-2014 Ulf Blanke, Swiss Federal Institute of Technology (ETH) Zurich, Switzerland
% Copyright 2011-2014 Andreas Bulling, Max Planck Institute for Informatics, Germany
%
% --------------------------------------------------------------------
% This file is part of the ActRecTut Matlab toolbox.
%
% ActRecTut is free software: you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation, either version 3 of the License, or
% (at your option) any later version.
%
% ActRecTut is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
% GNU General Public License for more details.
%
% You should have received a copy of the GNU General Public License
% along with HARPS. If not, see <http://www.gnu.org/licenses/>.
% --------------------------------------------------------------------
clear
settings % get output path
% run_results
% iterate through experiments, plot, and output relevant result
P_EX = [SETTINGS.PATH_OUTPUT '/experiments/'];
p_experiments = dir(P_EX)';
for exp = p_experiments
e = [P_EX exp.name];
if ~isdir(e) ||strcmp(exp.name(1),'.') ==1%strcmp(exp.name,'.') ==1 || strcmp(exp.name,'..')==1
continue;
end
params = dir(e)';
for param = params
p = [e '/' param.name];
if isdir(p)
continue;
end
s = strrep(param.name,'.','_'); % make safe
result.(['value_' s]) = [];
file = load(p,'-mat'); % saver to wrap with file(struct)
result.(['value_' s]).confusion = file.confusion;
result.(['value_' s]).metrics = file.metrics;
result.(['value_' s]).scoreEval = file.scoreEval;
end
figure;title(exp.name,'Interpreter', 'none');
plotEvaluationResults(result, file.SETTINGS, 'ROC');
clear result;
end