I am studying about mammogram image to detect tumor and classify it.
I have 100x88 input and 100x2 target .
targets are :
0 0 for normal
1 0 for benign
1 1 for malign situation.
my network codes generated by matlab is below
My question is I need [1;1] situation for output .
For that my binary ouput both of bigger than 0,5 when round it to 1.
but my binary output gives totally 1. Never bigger than 0.5 both of . so doesn't exceed 1 totally.
For example 0.7 and 0.3 or 0.65 and 0.35 or 0,92 and 0,08 ....
when I round these numbers always give 1 0 result not 1 1 result.,
it should be bigger than 0.5 both of . For example like 0.6 and 0.7...
I don't know reason why it gives totatly 1 binary outputs.
Codes are below.
trainFcn = 'trainscg';
hiddenLayerSize = 5;
net = patternnet(hiddenLayerSize, trainFcn);
net.divideParam.trainRatio = 70/100;
net.divideParam.valRatio = 15/100;
net.divideParam.testRatio = 15/100;
[net,tr] = train(net,x,t);
y = net(x);
e = gsubtract(t,y);
performance = perform(net,t,y)
tind = vec2ind(t);
yind = vec2ind(y);
percentErrors = sum(tind ~= yind)/numel(tind);
outputs = (sim(net,a))
outputss = round(sim(net,a))