10 lines
193 B
Mathematica
10 lines
193 B
Mathematica
|
function [er, bad] = cnntest(net, x, y)
|
||
|
% feedforward
|
||
|
net = cnnff(net, x);
|
||
|
[~, h] = max(net.o);
|
||
|
[~, a] = max(y);
|
||
|
bad = find(h ~= a);
|
||
|
|
||
|
er = numel(bad) / size(y, 2);
|
||
|
end
|