Attachment 'U04_eval_results.m'
Download 1 function U04_eval_results
2
3 load results.mat;
4
5 % banana
6 load ../../../datasets/U04/U04_banana-ytest.dat;
7 fprintf('banana:\n');
8 l = loss01(U04_banana_ytest, sign(result.krr.banana_predicted_labels));
9 fprintf(' krr: %f\n', l);
10
11 % diabetis
12 load ../../../datasets/U04/U04_diabetis-ytest.dat;
13 fprintf('diabetis:\n');
14 l = loss01(U04_diabetis_ytest, sign(result.krr.diabetis_predicted_labels));
15 fprintf(' krr: %f\n', l);
16
17 % flare-solar
18 load ../../../datasets/U04/U04_flare-solar-ytest.dat;
19 fprintf('flare-solar:\n');
20 l = loss01(U04_flare_solar_ytest, sign(result.krr.flare_solar_predicted_labels));
21 fprintf(' krr: %f\n', l);
22
23 % image
24 load ../../../datasets/U04/U04_image-ytest.dat;
25 fprintf('image:\n');
26 l = loss01(U04_image_ytest, sign(result.krr.image_predicted_labels));
27 fprintf(' krr: %f\n', l);
28
29 % ringnorm
30 load ../../../datasets/U04/U04_ringnorm-ytest.dat;
31 fprintf('ringnorm:\n');
32 l = loss01(U04_ringnorm_ytest, sign(result.krr.ringnorm_predicted_labels));
33 fprintf(' krr: %f\n', l);
34
35 function l = loss01(y1, y2)
36 l = sum(y1 ~= y2)/length(y1);
Attached Files
To refer to attachments on a page, use attachment:filename, as shown below in the list of files. Do NOT use the URL of the [get] link, since this is subject to change and can break easily.You are not allowed to attach a file to this page.