Borrar filtros
Borrar filtros

How to interpret Neural Network output if it is NaN?

2 visualizaciones (últimos 30 días)
Parul Singh
Parul Singh el 21 de Abr. de 2017
Respondida: Greg Heath el 23 de Abr. de 2017
Code to classify output into 3 classes- 0,1 and 2 (indicating no fault, line fault and irradiance fault). Output shows NaN and -0.00
Code:
% code
filename= 'new_3classes_Modif_NEURAL_NET_INPUT.xlsx';
S= xlsread (filename, 'B3:B106');
T= xlsread (filename, 'C3:C106');
V= xlsread (filename, 'D3:D106');
I= xlsread (filename, 'E3:E106');
P= xlsread (filename, 'G3:F106');
O= xlsread (filename, 'H3:G106');
C = [S T V I P];
x= transpose (C);
t = O.';
net = cascadeforwardnet(10);
net = configure(net,x,t);
y1 = net(x);
net = train(net,x,t);
y2 = net(x);
plotconfusion (t,y2);
end

Respuestas (1)

Greg Heath
Greg Heath el 23 de Abr. de 2017
For classification into mutually exclusive classes, the target columns should be [0,1] unit vectors. For examples, search the NEWSGROUP and ANSWERS using:
greg patternnet
and
greg patternnet tutorial
Hope this helps.
Thank you for formally accepting my answer
Greg

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by