Neural Network is giving incorrect results after 99.4 % training , Why?
Mostrar comentarios más antiguos
Hello Everyone,
I'm developing an automatic Urdu Speech Recognizer. I've taken 28 samples(7 males, 7 females ,2 recordings from each). After applying filters (Spectral subtraction, Silence Removal), DTW algorithm i calculated 42 MFCC features and then applied K mean algorithm on it.
Now i input the obtained vector to neural network as below :
e=0.2; % initialize error value
net=newff(minmax(input),Tar,[2 5],{'tansig','logsig'},'traingdx');
% 2 is number of hidden layer neurons and 5 is number of output layer neuron as i have to classify 5 words. Tar is Target
net.divideParam.trainRatio = 0.7; % ANN will take 70% data for training and 30% for testing
net.divideParam.testRatio = 0.3;
net.trainParam.epochs = 1160; % Maximum epochs
net.trainParam.goal =mean(var(Tar')')/100;
while e>= 0.0260
[net,T] = train(net,input,Tar);
test = sim(net,input)
temp=round(test)
e=Tar-test;
disp('error');
e=mse(e)
end
Now The confusion matrix give me 99.3% result, but when i test the data on the same samples it give me wrong answers.What should i do to get write results and why it is giving incorrect results even after 99.3% of training?
Respuesta aceptada
Más respuestas (1)
Greg Heath
el 31 de En. de 2012
0 votos
e=0.2; % initialize error value
UNNECCESARY
net=newff(minmax(input),Tar,[2 5],{'tansig','logsig'},'traingdx');
INVALID.
SEE THE DOCUMENTATION... WHAT VERSION TOOLBOX DO YOU HAVE?
SIZE(INPUT) = ?
SIZE(OUTPUT) = ?
NUMBER OF UNKNOWN WEIGHTS?
NUMBER OF TRAINING EQUATIONS?
% 2 is number of hidden layer neurons and 5 is number of output layer neuron as i have to classify 5 words. Tar is Target
YOU HAVE 14 PEOPLE SAYING 2 WORDS EACH. YOU HAVE TO CLASSIFY 5 WORDS. HOW DOES THAT BEAKDOWN?
TAR = ? ..... PLEASE CUT AND PASTE
net.divideParam.trainRatio = 0.7; % ANN will take 70% data for training and 30% for testing net.divideParam.testRatio = 0.3; net.trainParam.epochs = 1160; % Maximum epochs
WHY 1160?
net.trainParam.goal =mean(var(Tar')')/100;
while e>= 0.0260
WHY DO YOU THINK YOU NEED A WHILE STATEMENT ??
[net,T] = train(net,input,Tar);
WHY CALCULATE T AND NOT USE IT LATER?
HELP TRAIN
DOC TRAIN
test = sim(net,input)
NO. YOU HAVE NOT SEPARATED TRAIN AND TEST DATA
temp=round(test)
NO. YOU HAVE NOT IDENTIFIED THE MAXIMUM OUPUT THAT YIELDS THE CLASSIFICATION
e=Tar-test; disp('error'); e=mse(e) end
Now The confusion matrix give me 99.3% result, but when i test the data on the same samples it give me wrong answers.What should i do to get write(RIGHT) results and why it is giving incorrect results even after 99.3% of training?
IGNORE YOUR RESULTS. START OVER WITH THE CORRECT NETWORK CREATION INPUT PARAMETERS. SEPARATE YOUR TRAIN AND TEST CALCULATIONS
SINCE YOU ARE DESIGNING A CLASSIFIER TO IDENTIFY 5 WORDS, THE ONLY IMPORTANT MEASURE IS THE CLASSIFICATION ERROR RATE.
HOPE THIS HELPS.
GREG
1 comentario
Ali
el 31 de En. de 2012
Categorías
Más información sobre Deep Learning Toolbox en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!