I am Rimpi,
I need a help regarding training and testing of neural network in my own GUI application.
I generate 2 push button in GUI one for training and another for testing.
I Colleted 20 people signature images , 5 different copies of each individual that is total 100 signature images. i did pre- processing and feature extraction from each image. and i generate 20 targets for neural network training.
the dimension of input file is 7x100 and target filedimension is 20*100. after that i trained the neural network by tainlm.
but in gui during testing I want input a new test image and I extracted the 7 features of input image and save it in newinput.mat and having dimensions of 7x1. now i want to compaire newinput.mat features with all 100 images which is generated during training . if it match with 1 to 5 image that means it belong to 1st person , if it match with 6 to 10 that means it belong to 2nd person and so on upto 100 images. but the error during testing is dimension of input and targets are different.
please help me to solve it.
No products are associated with this question.
Your targets should be columns of the 20-dimensional unit matrix. The row index of the "1" is the true class index. The relationship between the target matrices and corresponding class indices is
target = ind2vec(truclassindex) truclassinddex = vec2ind(target)
Outputs, classifications and errors are given by
output = net(input); assignedclass = vec2ind(output) Errors = assignedclass~-truclassindex)
Hope this helps.
Thank you for formally accepting my answer
Play games and win prizes!Learn more